ON-OFF-ON Switch

Support for Arduino in combination with Air Manager and Air Player

Moderators: russ, Ralph

Post Reply
Message
Author
klm651
Posts: 1
Joined: Sat Oct 09, 2021 7:58 am

ON-OFF-ON Switch

#1 Post by klm651 »

Hello everyone !
I slowly lean into the programming of an overhead created with arduinos and air manager. I'm stuck on my ON-OFF-ON switches right now because I can't find the most concise way to program them in my script.
I have for example two pins (D9 and D10) which correspond to the high and low positions. The intermediate position being connected only to the mass. What is the most concise method of handling an order by position? I started out on a 2-position switch and a 1-position switch, but that seems to make the code quite chatty and conflicting.
Or test something with digital-input but I can't manage to do a single function for all my switch.
Ideas ?

Thanks in advance !

User avatar
Ralph
Posts: 7878
Joined: Tue Oct 27, 2015 7:02 pm
Location: De Steeg
Contact:

Re: ON-OFF-ON Switch

#2 Post by Ralph »

Has already been discussed a few times here on the forums. If you search then you'll find the explanation.

User avatar
BradyBrother100
Posts: 54
Joined: Tue Oct 13, 2020 4:21 pm
Location: United States MDT

Re: ON-OFF-ON Switch

#3 Post by BradyBrother100 »

Hi,

In AM 4.1, there will be support for that in the form of hw_input_add.

https://siminnovations.com/forums/viewt ... 436#p35437

Post Reply