The first step is to configure your UNO as a programmer, if you’ve done this already you can skip these steps and grab the board manager.
Open up arduino and the example sketch Arduino ISP
I’m getting an error while trying to burn boot loader with the modchip
does this mean ill have to remove the modchip?
avrdude: Version 6.3-20190619
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch
System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
Using Port : COM3
Using Programmer : stk500v1
Overriding Baud Rate : 19200
AVR Part : ATmega32U4
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 20 4 0 no 1024 4 0 9000 9000 0x00 0x00
flash 65 6 128 0 yes 32768 128 256 4500 4500 0x00 0x00
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 1 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500
Description : Atmel STK500 Version 1.x firmware
Hardware Version: 2
Firmware Version: 1.18
Topcard : Unknown
Vtarget : 0.0 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: AVR device initialized and ready to accept instructions
Error while burning bootloader.
Reading | ################################################## | 100% 0.02s
avrdude: Device signature = 0xff00ff
avrdude: Expected signature for ATmega32U4 is 1E 95 87
Double check chip, or use -F to override this check.
avrdude done. Thank you.
I tried again but had the arduboy turned on and got a different error message
avrdude: Version 6.3-20190619
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2014 Joerg Wunsch
System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
Using Port : COM3
Using Programmer : avr109
Overriding Baud Rate : 57600
AVR Part : ATmega32U4
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PA0
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 20 4 0 no 1024 4 0 9000 9000 0x00 0x00
flash 65 6 128 0 yes 32768 128 256 4500 4500 0x00 0x00
lfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
efuse 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
lock 0 0 0 0 no 1 0 0 9000 9000 0x00 0x00
calibration 0 0 0 0 no 1 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : butterfly
Description : Atmel AppNote AVR109 Boot Loader
Connecting to programmer: .
avrdude: butterfly_recv(): programmer is not responding
avrdude: butterfly_recv(): programmer is not responding
Found programmer: Id = ""; type = @
Software Version = �.v; Hardware Version = .
avrdude: butterfly_recv(): programmer is not responding
avrdude: error: buffered memory access not supported. Maybe it isn't
a butterfly/AVR109 but a AVR910 device?
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude: error: programmer did not respond to command: leave prog mode
avrdude: error: programmer did not respond to command: exit bootloader
avrdude done. Thank you.
the selected serial port
does not exist or your board is not connected
I’ve tried many other things but with no success, the errors all seem to have a problem with connecting to the programmer and that the programmer is not responding
Not anymore. you can upload the bootloader without problems.
In my earlier tests the flash chip did get upset during ISP-ing and it recovered fine after power cycling off and on again. But I do recommend to temporary connect a 10K pullup resistor to the SDA pad to prevent the flash chip from getting upset by the ISP data. If bad luck would strike a one time only bit in a certain register may get set with unwanted consequences)
(There’s no pullup on the mod chip cause the attiny normally takes care of that when it’s programmed with firmware)
Note
if the Modchip has been programmed already but contains faulty firmware the reset pad of the mod chip must be disconnected. otherwise the mod chip may try to flash the faulty bootloader right after ISPing with the UNO has completed.
The mod chip has a press reset for 2 seconds update feature (If that part was successfully flashed)
when ISP-ing the bootloader reset will be held low during the process. The Cathy bootloader flashes fast but if the ISP process takes longer than 2 seconds. the modchip 2 seconds update feature may kick in.
Thinking more about it may be better to ISP the modchip firmware (need to think about it more tomorrow, need sleep).
Sorry this may be a bit of a dumb question but what does this mean/what do I connect the other side of the resistor to? also is the arduboy supposed to be on or off while uploadihg the bootloaader?
I think I know why I’m getting the error code about the programmer not responding. I think it’s because I’m using a clone Uno r3 and I read on some other Arduino forums that some clone R3s don’t have the bootloader installed on the Atmel chip and you need a real R3 to flash the bootloader. So I’m probably gonna buy a USBasp
Would this one work? if not which one would/
Oh hm, I don’t think the bootloader that is on the UNO matters, all of the functions you are using it for are contained within the sketch.
I think either you’ll have to wait for instructions on how to bootload the modchip directly, or try removing the modchip and try these instructions again.
My suggestion is hold on for a day or two and we can come with instruction for how to fix this scenario.
@Bateske since you’ve also wired up VCC to 5V it’s also important to say:
Keep Arduboy power switch in the Off position !!!
If the modchip was programmed successfully there is no reason to upload the bootloader using an ISP. it would be much more convenient to use the FX activator to update the bootloader.
However in case the modchip was programmed unsuccesfully (verification failed) and one flashed the Arduboy’s bootloader anyway (no longer possible now) then things get a bit more complicated. If I have understood it correctly, this is the case with @TheBossinator
So:
We have an attiny with unexpected behaviour because of unsuccessful programming trying to update Arduboy’s bootloader and using the SPI bus.
We have Arduboy powering up with unexpected behaviour and possibly using the SPI bus for OLED display and / or flash chip if the Cathy3K bootloader was (partly) flashed.
We have the FX flash chip on the SPI bus.
We have the ISP programmer (Arduino Uno) using the SPI bus.
When connecting the ISP programmer to Arduboy and trying to program Arduboy, Arduboy will be hold in reset and will not send data to OLED and flash so that’s not a problem. But the attiny is still there trying to program Arduboy too and the flashchip is possibly listening in for receiving commands also (because of a floating chip select) so the ISP programmer won’t be able function properly.
We need to make sure that the attiny doesn’t try to program Arduboy and that the flash chip doesn’t listen in.
This can be done by putting both the attiny and Arduboy in reset, put them in program mode and issue a chip erase. (Both the Attiny and Arduboy will be erased) Once erased they won’t interfere with each other and the bootloader can be uploaded.
To make sure the flash chip doesn’t listen in. The flash chip select can be connected to one of the Unos GPIO pins cofigured as INPUT_PULLUP so it’s pulled high and the flash chip is disabled.
I’ll have a look at the Arduino as ISP sketch to add this.
here's how you should connect the Uno to Arduboy with mod chip (2 extra wires for SCL and SDA):
The moment you connect your Uno to USB or connect it to a power supply.
You keep Arduboy turned off for as long as your Uno is connected to USB or is connected to a power supply
The timing doesn’t have to be precise. When you have connected your Uno to USB or a power supply wait a few seconds or say out loud ‘Arduboy is awesome’ and press reset. wait another second and
burn the bootloader.