Benwin wrote:Is it possible to add AirFoil speakers to the Alexa-Hue Bridge so we can turn them on and off and set the volume using the "Alexa set <Bedroom Speakers> to 75%" command?
jay (support) wrote:It would be possible, but only if there were a virtual dimmer device which could then map brightness onto volume. I don't recall there being a 3rd party plugin that could do something like that.
bkmar1192 wrote:I am using the Meta Device plugin to control my AirFoil speakers. I have set them up as meta dimmer devices. I can turn them on/off and say "Alexa, set main speaker to 70%".
Works like a charm!
Sent from my iPhone using Tapatalk
theVolume = int(indigo.devices[**ID of Meta Device**].states['brightnessLevel'])+1
airfoilPlugin = indigo.server.getPlugin("com.perceptiveautomation.indigoplugin.airfoilpro")
if airfoilPlugin.isEnabled():
try:
result = airfoilPlugin.executeAction('setVolume', deviceId=**ID of Airfoil Speaker**, props={'volume': theVolume}, waitUntilDone=True)
except Exception, e:
print "Exception occurred: %s" % unicode(e)
indigo.dimmer.setBrightness(**ID of Meta Device**, value=20)
theVolume = int(indigo.devices[**ID of the Meta Device**].states['brightnessLevel'])+1
airfoilPlugin = indigo.server.getPlugin("com.perceptiveautomation.indigoplugin.airfoilpro")
if airfoilPlugin.isEnabled():
try:
result2 = airfoilPlugin.executeAction("connect", deviceId=**ID of Speaker**, waitUntilDone=True) # ID of Speaker device
result = airfoilPlugin.executeAction('setVolume', deviceId=**ID of Speaker**, props={'volume': theVolume}, waitUntilDone=True)
except Exception, e:
print "Exception occurred: %s" % unicode(e)
airfoilPlugin = indigo.server.getPlugin("com.perceptiveautomation.indigoplugin.airfoilpro")
if airfoilPlugin.isEnabled():
try:
result = airfoilPlugin.executeAction("disconnect", deviceId=**ID of Speaker**, waitUntilDone=True) # ID of Speaker device
except Exception, e:
print "Exception occurred: %s" % unicode(e)
Users browsing this forum: No registered users and 1 guest