-
Notifications
You must be signed in to change notification settings - Fork 297
Output button removal for relay use #125
Comments
Sorry, can you rephrase that? Am I understanding you correctly that you
want a single button that will toggle between the two states "pin x on, pin
y off" and "pin x off, pin y on"?
|
No problem. Im not good speaker in english. So i want one button and after
|
Ah, that’s simpler than I thought. That would be called a toggle. Yes, you could modify However, there’s a reason for the current design: The state of the GPIO pin may have changed in the mean time (e.g., if another program changes it). I’m not even sure whether they’re initialized to “off” at when Heimcontrol starts – I think they just stay in whatever state they’re in. But again to be clear: This might lead to a situation where only the “On” button is shown even though the device is already on; clicking it at that point would have no effect (but would bring the system back into a consistent state). If this is not a problem, or you’re brave enough to try it anyway, do this:
(The result may not look pretty; I’ll leave those improvements to you.) |
Thank you very much. I'll try these modifications after my work.
|
Worked like a charm Tom. Looks really good .Now i only have to make button blank (no 'on' and 'off' ) |
Tom, However I have several other devices that require the on/off function so I wouldn't want it for them all. Thanks, |
Sorry for the late reply, I’ve been a bit busy. @scrobel: There isn’t any built-in way to do this, but you can modify the Jade template I refered to earlier to achieve whatever cosmetic changes you desire. (See Jade website, in the end it’s just HTML.) @Pete54321: Again there's no built-in way to do this, but you could customize the Jade template. In this case, you’d need some conditional that applies only to that tri-state switch. (Something like Off the top of my head, it could look something like this:
Let me know if you need more details, but it might take a while for me to answer. |
I wanted to ask is there any option to remove one button from output tab and reprogram button that left for alternately switching GPIO pins (i want to alternately turn on and off relays from GPIO pins using only one web-based button ) Thanks for your time in advance.
The text was updated successfully, but these errors were encountered: