I've been using Indigo for years, but mostly as a remote control. I'm finally getting into the automation part of home automation an I feel like I'm tapping into parts if Indigo that I'm less familiar with and I'm questioning my approach.
Here's the situation:
I've got a ir remote control fan that has a single ir code to toggle power. I want to automate the turning on and off of this fan based on occupancy. These are the pieces I have all setup to do the heavy lifting:
Cynical Cache plugin with a Global Cache Flex to send ir commands - works perfectly
Z-Wave plug that I can poll power usage to check if the fan is ON - works great
fingscan plugin + mother plugin with mother motion cookie to determine occupancy - totally reliable Sen.se Mother is my fav new HA toy!
So, hardware wise I think I'm good to go, it's the Indigo logic I could use help with.
My 1st attempt:
because the ir command is a power toggle, I decided that the easiest way to do this was use the ir code to turn the fan ON and use the z-wave plug to turn it OFF by simply cutting power to the fan, then turn the plug back on. This causes the fan to go back to it's default settings. It takes about 6 button presses to get the fan back to the state I want it in. If I use the ir code to turn it off, it stays in the desired state.
I've started down my 2nd attempt with out the brute force power OFF, but I thought I'd check here to find out what the pros would do It seems like a simple problem, but my solution feels more complicated then it needs to be. So I'd love to hear peoples suggestions on how they would do it.
thanks,
Spencer