For completeness I will note that Windows is completely different. The
plain exit status (1 for typical command failures) appears in the
os.system result rather than a wait-encoded value. And, incidentally, an
MSVC program which calls abort() will return an exit status of 3. A
process that terminat
On Fri, Jun 12, 2015, at 09:54, Ian Kelly wrote:
> Exit code 0 traditionally means success. The exit status is two bytes,
> with
> the low-order byte normally containing the exit code and the high-order
> byte containing the signal that caused the program to exit.
That's backwards. The signal (or
On Jun 12, 2015 7:54 AM, "Ian Kelly" wrote:
>
> On Jun 12, 2015 7:21 AM, "Grawburg" wrote:
> >
> > I have a piece of code written for a Raspberry Pi with no explanation
for two of the lines -- and I can't find an explanation I understand.
> >
> > Here are the lines:
> > if os.system('modprobe --f
On 2015-06-12, Ben Finney wrote:
> There is no standardisation of exit status values between different
> programs. The best one can say is “exit status 0 means success”.
> Anything further is specific to particular programs and is not
> universal.
>
> You'll need to see the documentation for ‘mod
On Jun 12, 2015 7:21 AM, "Grawburg" wrote:
>
> I have a piece of code written for a Raspberry Pi with no explanation for
two of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1
Grawburg wrote:
> I have a piece of code written for a Raspberry Pi with no explanation for
> two of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') == 256:
>
>
>
On 2015-06-12, Grawburg wrote:
> I have a piece of code written for a Raspberry Pi with no explanation for two
> of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') ==
Grawburg writes:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') == 256:
>
> I know what the 'modprobe...' is, it's the 0 and the 256 I don't get.
> Where do these numbers come from?
They are integer literals, they come from the source code.
The st
I have a piece of code written for a Raspberry Pi with no explanation for two
of the lines -- and I can't find an explanation I understand.
Here are the lines:
if os.system('modprobe --first-time -q w1_gpio') ==0
if os.system('modprobe -q w1_gpio') == 256:
I know what the 'modprobe...' is, it
Blubaugh, David A. wrote:
> Thank You!!
>
> I am still new to Python!!
>
> David Blubaugh
As you've already noticed, plenty of folks here on the list are ready
help you out with issues the crop up as you learn python. So keep on
asking questions as you need assistance.
In the future, please
Blubaugh, David A. wrote:
To All,
I have been attempting to execute the following program within the
Python environment:
Myprogram.exe, which means this is an executable file!!
I would usually execute this program (with the appropriate arguments) by
going to following directory within MS-DOS
Yes,
I new it was a directory issue. I am new to Python.
Thank You
David Blubaugh
-Original Message-
From: Martin Walsh [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 1:42 PM
To: python-list@python.org
Subject: Re: OS.SYSTEM ERROR !!!
Blubaugh, David A. wrote:
>
Thank You!!
I am still new to Python!!
David Blubaugh
-Original Message-
From: Christian Heimes [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 2:08 PM
To: python-list@python.org
Subject: Re: OS.SYSTEM ERROR !!!
Blubaugh, David A. wrote:
> To All,
>
>
[EMAIL PROTECTED] wrote:
I would add the following line right before your call to os.system:
os.chdir(r'C:\myprogramfolder\run')
I wouldn't. os.chdir() tends to introduce all sorts of trouble. It's a
quick n'dirty hack for a small script but no solution for a large
program or library.
Chri
Blubaugh, David A. wrote:
> To All,
>
> I have been attempting to execute the following program within the
> Python environment:
>
> However, when I would try to execute the following lines of source code
> within a python script file:
>
> import os
>
> os.system(r"C:\myprogramfolder\run\Mypr
Blubaugh, David A. wrote:
To All,
I have been attempting to execute the following program within the
Python environment:
Myprogram.exe, which means this is an executable file!!
I would usually execute this program (with the appropriate arguments) by
going to following directory within MS-DOS
On Sep 30, 1:21 pm, "Blubaugh, David A." <[EMAIL PROTECTED]> wrote:
> I would usually execute this program (with the appropriate arguments) by
> going to following directory within MS-DOS (Windows XP):
>
> C:\myprogramfolder\run> Myprogram.exe 1 1 acc 0
[snip]
> import os
>
> os.system(r"C:\myprogr
Blubaugh, David A. wrote:
> To All,
>
>
> I have been attempting to execute the following program within the
> Python environment:
>
> Myprogram.exe, which means this is an executable file!!
>
> I would usually execute this program (with the appropriate arguments) by
> going to following direc
To All,
I have been attempting to execute the following program within the
Python environment:
Myprogram.exe, which means this is an executable file!!
I would usually execute this program (with the appropriate arguments) by
going to following directory within MS-DOS (Windows XP):
C:\myprogram
19 matches
Mail list logo