I have Ignition Version 8.1.3 running on Raspberry Pi under latest Linux
I have developed a Python script that runs on the Ignition Gateway machine. It has been tested and runs correctly from both the IDE and command line.
I now want run it from Ignition, eg a button press or tag event.
I have tried both system.util.execute and subprocess methods, in both Gateway Message events and tag change scripts, and cannot coax either of them to work.
Using subprocess.Popen([ sys.executable, “home/pi/myDirectory/doIt.py” ])
This throws a “No such file or directory” error
Using system.util.execute([ ‘python /home/pi/Nest/.py’ ])
This does not throw an error, but the Python script does not execute
Can someone help with:
a. Which method is preferable?
b. For the recommended method, what is the process command format?
Thanks in advance