Arducopter Lights and Leds



I was wondering if it is possible to have the onboard lights  behavior copied to some led’s connected somewhere in available outputs , for tows ho have a closed body’s for they cuadcopters .



And where are the navigational lights connected in the current release ( witch port or output pins ) ?, I know this is a momentarily fix and well be moved in the future .


Thanks

--------------------------------------------------------------- EDIT -------------------------------------------------------------------

I have found the code for the onbord leds in the Arducopter_alpha_RC1 file


  pinMode(LED_Yellow,OUTPUT); //Yellow LED A  (PC1)
  pinMode(LED_Red,OUTPUT);    //Red LED B     (PC2)
  pinMode(LED_Green,OUTPUT);  //Green LED C   (PC0)


I want to use the behavior from Leds A and C

Witch are for GPS fix and OK BOOT .

 

Dose somebody know how can i tweak this code to use with 2 led’s connected somewhere in the available  ports on the APM ?

 

My knowledge in to C++ is 0 so i want to start with this and hopefully learn something :) , my programming langis PHP so I don’t think it`s going to be that hard .

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

Join diydrones

Email me when people reply –

Replies

  • Sebastian: I forgot to update the code :-/ Can I do it via xbee or does it need to be via USB? My xbee connection works fine with configurator but when I try to upload code I get this error in Arduino app.

    Binary sketch size: 53090 bytes (of a 126976 byte maximum)
    avrdude: stk500_getsync(): not in sync: resp=0x00
    avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51
  • How do I get the flashing white LED like here: https://www.youtube.com/watch?v=Ne00IgTtbGQ

    And should the white flashing be in the front or rear? Jani says in the video that RED is right but then says flashing is rear which doesn't jive with the video. VIdeo shows red on right and flashing on front or red on left and flashing in rear.
  • OK I uncommented #define isAM but have a ? on ArduUser.h

    Right now it's


    /*************************************************************/
    // AM Mode & Flight information

    /* AM PIN Definitions */
    /* Will be moved in future to AN extension ports */
    /* due need to have PWM pins free for sonars and servos */


    #define FR_LED 3 // Mega PE4 pin, OUT7
    #define RE_LED 2 // Mega PE5 pin, OUT6
    #define RI_LED 7 // Mega PH4 pin, OUT5
    #define LE_LED 8 // Mega PH5 pin, OUT4

    /*
    #define FR_LED AN12 // Mega PE4 pin, OUT7
    #define RE_LED AN14 // Mega PE5 pin, OUT6
    #define RI_LED AN10 // Mega PH4 pin, OUT5
    #define LE_LED AN8 // Mega PH5 pin, OUT4
    */


    Do I need to change anything or uncomment anything. I'm plugging the lights into OUT4-7
  • Jani, I just resent the message. I sent it to your jphelirc address so maybe it got missed. I sent now also to store@fahpah.com. I hope you can ship out this week. I would like it shipped directly to Brazil.
  • Thanks Sebastian! Some details of your post got lost in the holiday punch and anxiousness to do my first night flight ;)

    I was confused because the center pin is + also right? 5+ coming from my BEC is going there. I tried the LED there and of course was nice a bright but is also working on the top pin, though not as bring. I will need to get some stronger LED's because the ones I have I'm sure will not be that visible at night.

    Do I have to change something in the software to map the action of the green light (armed, stable, acro) to one of these output pins so the white LED blinks like in Jani's video?
  • I missed that (o_O)

    >>jani just put one single LED into every motor mount, directly connected to (RC-) OUT4-OUT7 (+ is the topmost pin and - is the lowermost pin)

    So I just connect + of the LED to middle pin and - to lower pin but what about the white light that flashes indicating stable or acro mode?
  • Well not finding a way to attach jpg but I'm referring to the triple row of pins on the APM 4-7. I'm sure that is where they should go but to exactly which pins? + of LED on middle pin and - of LED on top pin?
  • I will connect to OUT4-7 for now but wanted to be clear of where to connect. Is the connection to the OUTPUT 4-0 on the 3 row connector of the APM?

    I marked them in the drawing attached. Connect to which pins of the 3 row connector?
  • Jani I sent you an email about needing some blades urgent. I went through all but one of the ones you sent because of the lose motor connections. Are you shipping through the holidays?
  • What is the highest intensity LED I can use without harm to the circuit?
This reply was deleted.

Activity

DIY Robocars via Twitter
RT @chr1sa: Just a week to go before our next @DIYRobocars race at @circuitlaunch, complete with famous Brazilian BBQ. It's free, fun for k…
Saturday
DIY Robocars via Twitter
How to use the new @donkey_car graphical UI to edit driving data for better training https://www.youtube.com/watch?v=J5-zHNeNebQ
Nov 28
DIY Robocars via Twitter
RT @SmallpixelCar: Wrote a program to find the light positions at @circuitlaunch. Here is the hypothesis of the light locations updating ba…
Nov 26
DIY Robocars via Twitter
RT @SmallpixelCar: Broke my @HokuyoUsa Lidar today. Luckily the non-cone localization, based on @a1k0n LightSLAM idea, works. It will help…
Nov 25
DIY Robocars via Twitter
@gclue_akira CC @NVIDIAEmbedded
Nov 23
DIY Robocars via Twitter
RT @luxonis: OAK-D PoE Autonomous Vehicle (Courtesy of zonyl in our Discord: https://discord.gg/EPsZHkg9Nx) https://t.co/PNDewvJdrb
Nov 23
DIY Robocars via Twitter
RT @f1tenth: It is getting dark and rainy on the F1TENTH racetrack in the @LGSVLSimulator. Testing out the new flood lights for the racetra…
Nov 23
DIY Robocars via Twitter
RT @JoeSpeeds: Live Now! Alex of @IndyAChallenge winning @TU_Muenchen team talking about their racing strategy and open source @OpenRobotic…
Nov 20
DIY Robocars via Twitter
RT @DAVGtech: Live NOW! Alexander Wischnewski of Indy Autonomous Challenge winning TUM team talking racing @diyrobocars @Heavy02011 @Ottawa…
Nov 20
DIY Robocars via Twitter
Incredible training performance with Donkeycar https://www.youtube.com/watch?v=9yy7ASttw04
Nov 9
DIY Robocars via Twitter
RT @JoeSpeeds: Sat Nov 6 Virtual DonkeyCar (and other cars, too) Race. So bring any car? @diyrobocars @IndyAChallenge https://t.co/nZQTff5…
Oct 31
DIY Robocars via Twitter
RT @JoeSpeeds: @chr1sa awesomely scary to see in person as our $1M robot almost clipped the walls as it spun at 140mph. But it was also awe…
Oct 29
DIY Robocars via Twitter
RT @chr1sa: Hey, @a1k0n's amazing "localize by the ceiling lights" @diyrobocars made @hackaday! It's consistently been the fastest in our…
Oct 25
DIY Robocars via Twitter
RT @IMS: It’s only fitting that @BostonDynamics Spot is waving the green flag for today’s @IndyAChallenge! Watch LIVE 👉 https://t.co/NtKnO…
Oct 23
DIY Robocars via Twitter
RT @IndyAChallenge: Congratulations to @TU_Muenchen the winners of the historic @IndyAChallenge and $1M. The first autonomous racecar comp…
Oct 23
DIY Robocars via Twitter
RT @JoeSpeeds: 🏎@TU_Muenchen #ROS 2 @EclipseCyclone #DDS #Zenoh 137mph. Saturday 10am EDT @IndyAChallenge @Twitch http://indyautonomouschallenge.com/stream
Oct 23
More…