Arduino-based mode switch

FILE0080.jpg?width=750First, I used combinations of switches to select the mode of my APM. But IMHO, there is hardly anything more counter-intuitive and if things hit the fan, you can be sure to switch to the wrong mode out of pure hectic.

Next, I replaced a pot of my transmitter with a 6-position switch and variable resistors. That is already better, but to get to one mode, you likely have to switch through other modes. Also, without any markings, again, not very intuitive and it's impossible to see at one glance which mode you are in.

Finally, I hacked together a small board with 6 pushbuttons, 6 LEDs and an Arduino Pro Mini. The Arduino creates an 8-channel PPM stream of which channel 1 contains the data for the mode. The whole thing connects to the trainer port of my 9x. Additionally, I steal 5V from the display output of my FrSky module but theoretically, the Arduino could also be powered by the 3S transmitter LiPo. The program is pretty easy. Check the buttons and set the respective PPM value. The LEDs are not set by the buttons but by the actual value of PPM1 - just to be safe, in case e.g. the Arduino resets or something.

Here's the schematic:

APM_mode_switch_schem.png?width=750I'll attach design files for the PCB and the source code in the comments then.

E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones

Comments

  • I connect inside the Taranis. I sent a bunch of pictures in a reply to your3702051966?profile=original PM. Let me know if you don't get them. I'm going to try to put them here too. They will do more good here than on my "comment wall", whatever that is.

    The way this handles pictures is kind of clunky but.......


    3702052154?profile=original3702051815?profile=original3702051451?profile=original3702051788?profile=original

  • Holly smokes!! You've taken mods to a whole new level.

  • Don't know your details but I am running this code on a Taranis on ch 5.

  • I fixed the downloads. Should work now.

  • RobC  my comments to your page have been "moderated"?

  • I figured i will never need twelve switches and sliders but I sure need the APM buttons in handy spots. I use the buttons for flaps on a non-APM Bixler 2 and the buttons on my APM B2 and everything is internal. If anyone is interested in this I can take pictures of the inside. By the way, all the radios I've put together using the Arduino board have used the code from Stefan's original Arduino Mode project. It works flawlessly. Thanks again Stefan

  • I have put together a setup with my Taranis using the illuminated push buttons I used on my 9XR that works pretty good. I have a copy of the code too, or I could3702009539?profile=original upload it from one of my controllers.

  • With Taranis you can use 6 momentary pushbutton switches rather than the cumbersome 6-position rotary switch. You need to program 12 logical switches, 6 special functions, and a global variable. The pushbuttons don't light up as they are pushed, but that's no negative if you've got voice announce, flight mode on telemetry or OSD...

  • Cool!

This reply was deleted.