I'm struggling with how to code this in python. I've tried the following:
- Code: Select all
airfoilPlugin = indigo.server.getPlugin("com.perceptiveautomation.indigoplugin.airfoilpro")
if airfoilPlugin.isEnabled():
try:
result = airfoilPlugin.executeAction("connect", deviceId=SPEAKERID, waitUntilDone=True)
indigo.server.speak("text to speak", waitUntilDone=True)
result = airfoilPlugin.executeAction("disconnect", deviceId= SPEAKERID, waitUntilDone=True)
except Exception, e:
print "Exception occurred: %s" % unicode(e)
However the above code only seems to connect to the speaker, then disconnect. I do not hear any announcement. I'm sure I'm missing something basic here...