Hi guys, we are having some problems uploading firmware with Arduino to APM 1280 board when the size of the sketch is more than 122880 bytes (0x1E000).

I understand that bootloader starts at 0x1F000, so the maximum sketch size is 126976 bytes as Arduino shows.

What can be wrong? Tested on different boards and different computers. Arduino 0022 version.

Example:

Compiling:

Binary sketch size: 122904 bytes (of a 126976 byte maximum)

Uploading:

avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x1e000
         0xe1 != 0xff
avrdude: verification error; content mismatch

Thank you!!

 

Views: 1029

Reply to This

Replies to This Discussion

when your uploading do you have servos/ecs attached?
Nothing connected. Tried with USB only and external supply too. Less than 122880 bytes goes perfect, more than that gives the error.

I've uploaded sketches a few hundred bytes shy to a 1280 without problems. Older versions of AC2 were 125k.

 

Jason do you have any of the older versions with 125k? If so, please post the zip to give a try, I'm not sure if it is code related, I can't upload over 0x1E000.

 

I just added some lines to APM code to go over 122880 bytes, can you try to compile and upload this code?

Thank you

Attachments:

I would really appreciate it if someone could try to upload the sketch and post the results.

Thanks!

I tried to upload to Arduino Mega board with success, then I just found the problem, my APM boards came with fuses set wrong.

Boot flash start is wrong, preventing to write from 0x1E000 to 0x1EFFF.

Comparing to Arduino Mega fuses the brown out detection is wrong too.

I've set the fuses in APM board and now it's working.

Who know how many APM boards are out there with wrong fuses?

Take a look at BODLEVEL and BOOTSZ.

My APM boards fuses:

Arduino Mega fuses:

Where did you get the APM boards from?

From DIYDrones Store.

Right fuses should be as shown from Arduino Mega board?

Gotcha. Thanks for the heads up. We're checking with QA to see what might have happened. We've had no other reports of this, so hopefully it's an isolated incident.

Maybe it happened with a batch because I got several boards with same condition. Never noticed using sketches of less than 122880 bytes.

I will look for the date of purchase if it helps.

The fuses settings from Arduino Mega are fine for APM? I'm not sure what the settings should be in right condition.

 

Date of purchase would be super helpful. The brown-out setting should be 2.7v as you say. We had a small batch with bad fuse settings last year, but there shouldn't have been any since then.

RSS

Social Networking

Contests

Season Two of the Trust Time Trial (T3) Contest has now begun. The fourth round is an accuracy round for multicopters, which requires contestants to fly a cube. The deadline is April 14th.

A list of all T3 contests is here

Groups

Advertisement

© 2013   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service