An idea - adapt Cynical Caché Plugin for Arduino

Posted on
Sun Jun 12, 2016 9:06 pm
srkinard offline
Posts: 320
Joined: Apr 10, 2016
Location: Austin, Texas

An idea - adapt Cynical Caché Plugin for Arduino

Maybe join forces with Karl and his Arduino plugin to bridge the CIR transmit and receive functions in the Cynical Caché Plugin to utilize the Arduino + Wifi/Ethernet combo.

For a little less than $50 in parts we could build an interface supporting numerous emitters & receivers. Technically you could use the serial pins on the Arduino for Serial interfaces and other pins to control relays, so you could replace up to a GC-100-12 maybe.

Karl's Arduino sketch creates a simple web interface on the Arduino, so it might could be adapted to talk with a modified form of your plugin direct...or maybe extend the Cynical plugin to speak to devices created by Karl's?

It would be great because I already have 3x Arduino UNO + Ethernet units with IR receivers and transmitters that I could deploy to take control of my 3 home theater setups with no more additional purchases.

I just thought I'd toss the idea out there and see if there was any interest. The iTach is nice...but $91...if I'm going to spend I'd prefer to get more Fibaro RGBW units and some fan-speed controllers.

Hopefully at least consider it...

Thanks!
Ross

Posted on
Sun Jun 12, 2016 10:27 pm
kw123 offline
User avatar
Posts: 8382
Joined: May 12, 2013
Location: Dallas, TX

Re: An idea - adapt Cynical Caché Plugin for Arduino

the arduino plugin has a py interface. You can set an S pin

then in doMyStuff do the things you need to do to send an IR signal according to the S pins set



Code: Select all
plug = indigo.server.getPlugin("com.karlwachs.arduino")
if not plug.isEnabled(): return   #### ARDUINO must be enabled, otherwise nothing here works
plug.executeAction("setPins",
   props={
   "device" :"1780896723" # or device name
   ,"pin": "S1" 
   ,"CMD": "analogWrite"
   ,"aValue":"987"
   ,"sendORset":"setOnly"
   }
)
plug.executeAction("setPins",
   props={
   "device" :"1780896723" # or device name
   ,"pin": "S0" 
   ,"CMD": "analogWrite"
   ,"aValue":"123"
   ,"sendORset":"setOnly"
   }
)

plug.executeAction("sendPins",
   props={
   "device" :"MyDeviceName" # or device id
   ,"pinsToBeSend": "s0,s1"  #
   }


in
doMyStuff{
if (s1 !=""){ do whatever for IR with s1 value; s1=""}
if (s0 !=""){ do whatever for IR; with s0 value; s0=""}
}

that would send 987 to S1 and 123 to s0 in one transmission and in do mystic

Karl

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 4 guests