How to Reset Arduboy if it's Bricked

Here is a quick video showing how to reset the Arduboy into bootloader mode.

You’ll need to press the reset button while Arduboy is attempting to upload code. The video gives a few good pointers be sure to watch the whole thing if you’ve got a problem with your Arduboy!

[Updated with new video]

16 Likes

This worked for me, though I had to actually wait a few seconds (about 3-4) after hitting Reset before uploading.
When I started the upload immediately after Reset, nothing would happen.

Thanks much!

@bateske I think you need to add this to the post. I think some computers take a while to see the device pop back up on the USB bus… so if you reset it and then don’t wait long enough there is no USB device to flash.

1 Like

That was definitely it. I could tell my computer dropped the device, and waited for it to pop back up essentially.

Am I wrong, or does the update to the latest Arduino IDE mean that units will no longer lose track of their entry point, and will no longer suffer from “bricking”?

The AVR core now recognizes if a new bootloader is present and uses a safe RAM location to trigger programming (this is particularly important for large sketches, like the ones produced by our friends at Arduboy)

https://blog.arduino.cc/2016/05/10/ide-1-6-9-just-released-with-yun-shield-support-and-more/

I’m posting the source notes for reference on the actual change.

1 Like

I got that impression after reading the release notes yesterday, but didn’t investigate to confirm. The fact that they mention Arduboy in the IDE 1.6.9 release blog entry solidifies that this is the problem being addressed.

Of course, “bricking” (requiring using the reset button) will still be possible for other reasons, such as certain types of bugs in the sketch itself, but this fix in the IDE should prevent one of the most common and hard to solve problems.

1 Like

What do they mean by “new bootloader”? I remember seeing one bootloader with the requested change but we didn’t implement it because it seemed unlikley Arduino would make this change to their IDE based on the history.

So, I don’t think we actually support this out of the box? We can change for the pre-order units and we can upgrade repaired units too…

1 Like

According to the log entry for the commit, it looks like it means a

LUFA-derived bootloader released after 2014 (.apitable_signatures section must be placed at end of the flash)

Does that include the Leonardo bootloader that the Arduboy uses? (I haven’t looked into this.)

2 Likes

Looks like the bootloader bug may not be fully solved, or doesn’t work with the bootloader we’re using :frowning2:
http://community.arduboy.com/t/do-nuts-a-demo-showing-animated-backgrounds/675/4

Hi guys,
finally i got my Arduboy, but…
I try to reset it, several times, mood on and mood of, and nothing, doesn’t work.

First, when I turn on my Arduboy, the first image is the “Team A.R.G.” theme and not the arduboy one, is it normal?

Second, when i try to reset my Arduboy, no sound or yellow light near the red one.

Could you please help me? Trust me, I try to reset in different time my Arduboy.

At the end, is it possible a problem on my USB port on my Macbook Pro? Is it possible my macbook cannot recognize the Arduboy device?

Thanks for help me!

Hi all,

actually I think I have bricked my Arduboy. I am using platformio but it seems that it allows me to flash more that the allowed 28672 bytes (I do not have the log anymore but it was above 28700). Now my little Arduboy sometimes starts the software that I flashed and sometimes the yellow/green leds near the USB port start flashing wildly. I tried all the above suggestions also from the other “bricked” threads but nothing works. I even made it to make the board into bootloader mode and tried to flash manually with avrdude without resetting (1200bps dance) but as soon as the bootloader kicks in the leds start blinking wildly. The after some time avrdude stops with errors. The leds keep blinking even without the USB cable connected. Only power cycle helps.
Now I think I need to flash the bootloader again.
I opened the device and found the 6 pins of interest. Is there any procedure how to attach there and flash the bootloader? Anything that I keep in mind while trying this?

I have an AVR MKII ISP that I could use for flashing. It will need some MacGyver like skills attaching to the pins.

Any help is appreciated.

1 Like

Exactly the same thing happened to me.
Have no experience with arduino so i have no idea what and how you have to flash but i’m following this post.

This is normal for a factory flashed unit.

Is there a reason to reset the device? You should only need to reset it if the software upload fails, or there are some bugs with the software that reloads.

If you plug it into your PC or Macbook and the device is not recognized then you should try to use a different USB cable that has support for data transfer (preferably something that you’ve used to transfer files before). If using different cables does not work and you are still on the original software then please contact us via the store page and we can try to help you out directly.

Both Arduino and Codebender will prevent you from trying to flash a file that is too large, I have no idea if this is baked into AVRdude and I’m not familiar enough with Platformio to make any suggestions there. I didn’t think it was technically possible to overwrite the bootloader memory space over USB (without some creative hacks to do it intentionally).

@veritazz if you could take a video and post it in a new thread of this behavior I think it would be helpful because I’ve not run into it before.

The pins required for re flashing have circles around them and are clearly labeled. You can use any online tutorial for flashing an arduino leonardo on the arduboy.

NOTE: We are currently using the leonardo bootloader but will likely switch to something custom in the future.

It seems that we need to update the bootloader to take advantages to the changes in arduino that will eliminate the bug related to programs taking up too much RAM. Still trying to dig into that one fully.

@Botisaurus Were you using platformio also? Or is it a more general error, let us know some more details and feel free to open a separate support thread with a video or picture if you want.

If the fuses were set properly at the factory to protect the program area used by the bootloader, it should be near impossible to overwrite or otherwise corrupt it in any way, regardless of the size of the sketch you’re trying to write, or what software you’re using to write it.

@bateske, You may wish to check how the fuses are being set in the Arduboy and how they compare to a Leonardo. The Leonardo uses LOW:0xFF HIGH:0xD8 EXTENDED:0xCB LOCK:0x2F

For bootloader protection the important ones are the HIGH and LOCK fuses.

I like to use this fuse calculator for working with AVR fuse configurations.

Not sure the LOCK fuse was set :frowning: It should be the same as leonardo but I can only confirm the other bits. Maybe these occurrences with platformio means it’s not, and we’ve get something more that can be fixed in our next batch…

Jup i was using it.
I have already uploaded 2 videos on another thread. I can’t search for it right now since i’m on the phone.

###update:
this thread.

Thanks to all for the help. I finally brought it back to life by reflashing the bootloader using an AVR MKII ISP and some wooden clothespin. It was quite a ride as the connections where not very stable but I could hold it until the write was finished.
Here are two videos when it was still bricked:

This is a video (could be also a picture) where I tried to flash the bootloader via the Arduino IDE. You need to select the leonardo board and choose Tools->Burn Bootloader (before that select the programmer you have, do not forget to switch on your Arduboy). Use Arduino IDE 1.6.9.

I do not know if the lock fuse is set. How can I read it? Avrdude prints this:

avrdude: safemode: lfuse reads as FF
avrdude: safemode: hfuse reads as D8
avrdude: safemode: efuse reads as CB
avrdude: safemode: Fuses OK (H:CB, E:D8, L:FF)

4 Likes

Here is a closeup of the clothespins. A bit flimsy but after some tries it worked. :sweat_smile:

3 Likes

I’m only interested in one thing: TELL US MORE ABOUT YOUR GAME !!! :slight_smile:

Oh boy… good job.
Sadly too complicated for me since i have no necessary equipment nor the knowledge to do that. :frowning:
In addition to that my battery broke down (yeah i’m pretty talented) so i would need an replacement for that too and need to solder everything. :frowning: