What causes Bootloader Failure?

Hello

I have been modifying arducopter code (2.9 and 3+) for awhile now and just recently ran into issue with the bootloader on several apm 2.5 boards. I use linux for development so I use command "make upload" to upload the hex files. On all three boards it makes it 99% the way finished on verfying hex before it bricks and stops. This causes bootloader issue on next power which makes me have to use avr programmer to upload the bootloader again. I'm just trying to figure out what causes bootloader issue..is it an error in the code or is just bad luck. Another weird issue is that once I fix the bootloader issue I can't use "make upload" command again even with standard vanilla code due to stk_error issue but I can upload firmware via mission planner. Any help/tips would be great!

Thanks

Steve

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

Join diydrones

Email me when people reply –

Replies

  • This is the error I get after putting the bootloader back on and after I did a standard firmware through mission planner.

    /apm_plane/apm3/ardupilot/ArduPlane$ make upload
    HAL_BOARD=HAL_BOARD_APM2 TOOLCHAIN=AVR EXTRAFLAGS=-DGIT_VERSION="3c57e771"
    building /tmp/ArduPlane.build/ArduPlane.cpp
    %% ArduPlane.cpp
    /usr/bin/avrdude -c stk500v2 -p atmega2560 -P /dev/ttyACM0 -b115200 -U flash:w:/tmp/ArduPlane.build/ArduPlane.hex:i

    avrdude: AVR device initialized and ready to accept instructions

    Reading | ################################################## | 100% 0.01s

    avrdude: Device signature = 0x1e9801
    avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed
    To disable this feature, specify the -D option.
    avrdude: erasing chip
    avrdude: stk500v2_command(): command failed

    avrdude done. Thank you.

    make: *** [upload] Error 255

    I can't use mission planner to upload custom firmware because that isn't option on Linux apm planner yet...I will try on windows machine once I get to one...but I'd love to figure out what causes this.

This reply was deleted.

Activity

Neville Rodrigues liked Neville Rodrigues's profile
Jun 30
Santiago Perez liked Santiago Perez's profile
Jun 21
More…