Relays and Touch-Panel
-
Hi,
I´m using a Touchpanel with 16 Buttons for controlling different lights in my basement/man-cave.
It is this one: http://www.aliexpress.com/item/New-16-Way-Channel-Capacitive-Touch-Switch-Digital-Touch-Sensor-Module-PCB-Board-TTP229-Electronic-Components/32343209711.htmlEach Button switch one Relay - this is working so far - but now i want to integrate the relays also with mysensors,
so that i can see the Status, and switch the Relais also with the controller (domotiz).
My current working code is here: https://github.com/Delranon/cave-control/blob/master/cave_control/cave_control.inoI´ve seen the RelayActuator Example but these are always with a hardware button, but i get the button as a variable from the TouchPanel-Library and
switch the relays like this:if (key == 5) //Button pushed { if (Relais5State == 0) // Relais is currently off { digitalWrite(Relais5, LOW); //turn Relais onAnd now i´m looking how to send to the controller that relay 1 is turned on and that i can it also turn off via the controller interface...
Any help or tips would be awesome!
Thanks Del
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login