Get a device's on state from Python in an AppleScript?
Posted: Fri Jun 07, 2019 1:52 am
I'm clueless in Python and would prefer to stay with AppleScript for the simple tasks I do with Indigo.
How can I pass the on state of a device from Python to AppleScript? Something like:
How can I pass the on state of a device from Python to AppleScript? Something like:
- Code: Select all
set iphPath to "/Library/'Application Support/Perceptive Automation/" & ¬
(name of application id "INDC") & "'/IndigoPluginHost.app/Contents/MacOS/IndigoPluginHost"
set deviceOnState to do shell script iphPath & " -e 'dev = indigo.devices[112943280]; dev.onState'"