Scorch Posted December 3, 2020 Posted December 3, 2020 (edited) Hello all, I'm working on my first button box wish is planned to be Arduino Pro Micro controlled. This box will include some simple SPST switches that I understand how to setup for the Arduino. What I do not understand is there are five AHCP switches that I think are on/on/on. I have this switch from Digikey. I don't understand how to wire this switch such that I can use the on/on/on functionality and work it into my row/column matrix for the Pro Micro. This drawing shows pins 3 & 5 are jumped. I get that. Position 1 for example requires pins 2-3, 5-6 (all this information is on the drawing in the link). Would a kind soul please help me understand this so I can build it please? Thank you! Edited December 3, 2020 by Scorch Added missing link to drawing.
Raisuli Posted December 3, 2020 Posted December 3, 2020 A switch matrix with toggles probably isn't going to work well. Matrices are designed for momentary switches (think keypads or even keyboards on your computer), and even then it takes some work to tolerate multiple key presses; generally diodes to keep the current from reversing on you.
Nikolas_A Posted December 3, 2020 Posted December 3, 2020 5 hours ago, Scorch said: Hello all, I'm working on my first button box wish is planned to be Arduino Pro Micro controlled. This box will include some simple SPST switches that I understand how to setup for the Arduino. What I do not understand is there are five AHCP switches that I think are on/on/on. I have this switch from Digikey. I don't understand how to wire this switch such that I can use the on/on/on functionality and work it into my row/column matrix for the Pro Micro. This drawing shows pins 3 & 5 are jumped. I get that. Position 1 for example requires pins 2-3, 5-6 (all this information is on the drawing in the link). Would a kind soul please help me understand this so I can build it please? Thank you! Also, you can just use On-Off-On switches and emulate the middle position in the Arduino sketch (if neither input is On, send the command for the middle position) 4 hours ago, Raisuli said: A switch matrix with toggles probably isn't going to work well. Matrices are designed for momentary switches (think keypads or even keyboards on your computer), and even then it takes some work to tolerate multiple key presses; generally diodes to keep the current from reversing on you. With diodes toggles will be ok
Pantera93 Posted December 3, 2020 Posted December 3, 2020 I have a 36 element on-off-on switch matrix that works fine, no diodes involved, the only delay is due to the fact that, when switching from low to high, DCS animations stuck the virtual switch in the middle position (e.g. M2000 lights). So, don't go too fast and follow the cockpit. 57 minutes ago, Nikolas_A said: Also, you can just use On-Off-On switches and emulate the middle position in the Arduino sketch (if neither input is On, send the command for the middle position) I use this trick to make them work. I wired up an Arduino Leonardo, so my box is recognized as a controller, don't know how it will work with DCS BIOS. - "It's better to reign in hell than to serve in Heaven" Modules: A-4E-C Skyhawk, A-10C II Tank Killer, AJS37 Viggen, AV-8B Harrier, F-14B Tomcat, F-15C Eagle, F-16C Viper, F/A-18C Hornet, MIG-21 Fishbed, MIG-29, SU-27, SU-33 Maps: Caucasus, Nevada, Persian Gulf, Syria, Supercarrier Rig: i7 4790 / Nvidia GTX 1070 Strix / 16GB RAM DDR3 1600 MHz / 256 GB SSD / Windows 10 Setup: ThrustMaster TWCS Throttle, Titanwolf "Vulture" Stick, DelanClip PRO, Home-made universal Cockpit panel
Scorch Posted December 4, 2020 Author Posted December 4, 2020 Thanks all. I’ll back up and start small. Is it possible to have two of these switches along with a Pro Micro control the seat height adjustment and the opening and closing of the canopy? These DIY button boxes look so easy on YouTube. I’m overwhelmed at the moment. Thanks again all. We’ll come back to the ACHP panel after I do a few simpler things.
agrasyuk Posted December 4, 2020 Posted December 4, 2020 (edited) AHCP is actually a very simple project - it only has toggles. map the event of the releasing of bothth side to send the "off" position the switches in the link will work of course , in case you were looking for a momentary switch. the brackets in the (on)off(on) notation means the switch will spring back to middle position, vs on-off-on that will keep the position . I guess you now understand what (on)-off-on means then for cheap toggles I would check ebay or aliexpress before going to amazon. and no need to get the weather cap version good luck Edited December 4, 2020 by agrasyuk 1 Anton. My pit build thread . Simple and cheap UFC project
Scorch Posted December 5, 2020 Author Posted December 5, 2020 Thank you. Might you have any advise or link to a resource to help me layout the matrix itself? I find this to be confusing at this point. Thank!
agrasyuk Posted December 5, 2020 Posted December 5, 2020 It was already mentioned above that matrix will not work reliably for toggles. To connect more toggles buy a few more arduinos (the Nano from china are inexpensive at all). But for now you can start with the main 4 Arm switches. Anton. My pit build thread . Simple and cheap UFC project
Nikolas_A Posted December 5, 2020 Posted December 5, 2020 (edited) Α matrix will not work reliably for toggles without diodes. Edited February 19, 2021 by Nikolas_A
Recommended Posts