I would like to ask about how I can launch a luma oled script from a parent script. I have used:
import subprocess # to use subprocess
p = subprocess.Popen(['python', 'demo_oled_v01.py --display ssd1351 --width 128 --height 128 --interface spi --gpio-data-command 20'])
in my parent script but I got an error stating:
python: can't open file 'demo_oled_v01.py --display ssd1351 --width 128 --height 128 --interface spi --gpio-data-command 20': [Errno 2] No such file or directory
I suspect that adding the parameters --display ssd1351 --width 128 --height 128 --interface spi --gpio-data-command 20 after .py may be causing difficulty in launching the oled script. These parameters are otherwise essential for me to include for launching with bash commands on terminal. How can I use subprocess with the required luma library parameters to launch a SSD1351 based script?
I would like to ask about how I can launch a luma oled script from a parent script. I have used:
in my parent script but I got an error stating:
python: can't open file 'demo_oled_v01.py --display ssd1351 --width 128 --height 128 --interface spi --gpio-data-command 20': [Errno 2] No such file or directory
I suspect that adding the parameters
--display ssd1351 --width 128 --height 128 --interface spi --gpio-data-command 20
after.py
may be causing difficulty in launching the oled script. These parameters are otherwise essential for me to include for launching with bash commands on terminal. How can I use subprocess with the required luma library parameters to launch a SSD1351 based script?