Help with DIY Aduboy

Perhaps a photo of your setup and a log of the error messages would help someone spot what the issue might be?

Just to check, did you remember to set the board to Arduino Uno when you uploaded the ArduinoISP program to your Uno? (And likewise set it to Pro Micro for uploading to the Pro Mirco.)

And did you remember to set it again to the target board (which I think is a Pro Micro in your case?) before burning the bootloader?

Also, are you using the three status lights (‘heartbeat’, ‘error’ and ‘programming’)?

1 Like

I’ll see what I can do, but I might have found the issue.


No but I might give those a go, I doubt it’ll prove useful though.

As for my hunt for the issue, I have a backup of the gerber files and schematic from the file I sent to JLCPCB so I’ll have a look through. The MISO and MOSI pins are connected to the ‘W25Q128’ so perhaps that might be reporting something. That unfortunately doesn’t change anything, but I have the chip removed now so I can put it away. A look at the PCB traces and solder connections doesn’t show any bridging effects.

The fuse bits are set to 0 even on a working pro micro so I can rule that out. But their size is 1 compared to the typical 0 I’m getting.

Changing ArduinoIDE to 1.6.13 doesn’t help either.

Connecting the battery to the device (the Arduboy I’m trying to program) and connecting a USB to the port doesn’t give any connection notification. Surely that would work?

Running ‘Burn Bootloader’ without anything connected still gives the same error as having the target connected so something might not be powered.

I may have found the culprit. I switched the ISP programmer to an Arduino Nano and burning the bootloader to a working pro micro to eliminate the possibility that it was the Uno. I believe a GND pin may be shorting since it makes a disconnect sound when connecting the GND wire of the Arduboy. The L LED (built-in LED) also turns off [SUDDEN DRAMATIC LAPTOP SHUT DOWN AND BLUE SCREEN] well… it seems my computer didn’t like it and shut down, so something is doing something bad on my DIY Arduboy.

1 Like

My Thought Process is as Follows:

  1. Tried burning bootloader on both DIY and working pro micro with an Uno, no success on both (Might have been that the Reset was connected to the Unos reset instead of D10)
  2. DIY Arduboy won’t burn bootloader, might be the Uno, I’ll try an Arduino Nano
  3. I burned the bootloader to the working pro micro with the Nano (Connecting RST to D10 on it)
  4. I tried connecting the DIY Arduboy to the Nano (I believe my computer blue screened before this when I was using the Uno)
  5. built-in LED turns off when I connect the GND pin
  6. I tested every other pin to see if it turned on the built-in LED when disconnected, only the GND pin
  7. My computer suddenly shuts down (Though my battery settings may have put in hibernation because my laptop was at 18% when I last checked)

GND should always be the first pin to connect. If not it may cause your reset or even cause damage.


I’ll keep that in mind, but I’m still unsure of what to try next with it. I’ll try connecting it again and see if turns off the LED again. Otherwise I’ll desolder it, clean up the PCB (or try another one), clean off a spare ATMega and try it out again.

A clear detailed photo of your board like @Pharap suggested may reveal something.

as for the atmega32u4 it could set to require an external clock. In that case you need to apply an external clock to pin XTAL1.


Here’s a photo of the board with soldered components (though the resolution and clarity might not be the best so I’ll take a new one tomorrow of both a soldered one and non-soldered one):

The backside contains all the ICSP points, which I’ve soldered some regular wires to. I might do a short circuit test with my multimeter on the wires to make sure they’re actually connected.

I’m not entirely sure what you want me to do, but should I try and upload that sketch attached to the message? I read through completely and I’ll try out connecting a wire to XTAL1 to Pin 9, though how will I actually put the sketch on there? Also how do I go about burning the fuse settings? (Even if that doesn’t work it’d be good to eliminate the possible cause)

If need be I could create a special board to solder the chips to and program them. Something similar to one of these:

(Though I could isolate the atmega to a section of PCB to prevent any heat transfer to other components, a reflow oven is something I really want to get but can’t unfortunately for a few months).

Also notice how the solder joints bridge outwards whereas on mine they’re completely hidden, which is why I’ll modify my design to move the pads outwards a bit. I’m also using a different style of oscillator too, hopefully that doesn’t change anything.

A rough idea but surely basic contact with some pads (maybe with a bit of solder to keep it from being level on the PCB) could work to make an electrical connection? Though they may need a bit of pressure and alignment to keep it connected and inline. I’d be very interested in attempting something like that. It removes the risk of overheating or breaking the component and would be quick to program the chips.

You upload the sketch to a pro micro which you then use to supply the 8MHz clock to your board. You use your Uno or nano as ISP programmer.

Burn the bootloader through the Arduino IDE it will also burn the correct fuse settings.

The default “clock source” fuse settings for the ATmega32U4 is for an external low power crystal oscillator. If the ATmega32U4 is “factory fresh” it should work with (and need) a crystal attached.

You may want to consider changing your board to use the TQFP44 package for the ATmega32U4 instead of the QFN44 package you’re currently using. The pins are quite a bit larger and farther apart, thus easier to solder.

@Ashteroide, here’s how I would proceed with trying to get your board working:
I’m assuming you don’t have an oscilloscope but have a multimeter that can measure voltage and resistance.

Assuming you have removed the W25Q128 flash chip, the level shifter for the ICSP isn’t required. I would leave it out and directly attach your ICSP (Nano) to your board. This will mean ICSP programming power and signals will be 5V.

For all the 32U4 pins, probe them directly using a sewing needle or something similar that allows you to probe the actual pin, not a trace on the board that the pin should be connected to.

Before connecting the ICSP to the board:

  1. Use the multimeter to measure the resistance between VCC and GND on the board to make sure they’re not shorted.
  2. Make sure all the VCC pins of the 32U4 are connected to the point on the board that you are wiring the ICSP VCC (5V) to. Do the same for 32U4 GND pins to the ICSP GND connection.
  3. Make sure there are no shorts between any of the ICSP board connection points (VCC, GND, RESET, SCK, MOSI, MISO).
  4. Make sure the 32U4 RESET pin (13) is connected to the point on the board that you are wiring the ICSP RESET signal to. The same goes for 32U4 SCK (9), MOSI (10) and MISO (11).

If everything above is OK:

  1. Connect only the VCC and GND wires from the ICSP to the board. Just to be safe, make sure GND and VCC still aren’t shorted.
  2. Power up the ICSP and make sure all the actual 32U4 VCC pins are at 5V using an actual 32U4 GND pin for GND.
  3. Power down the ICSP and connect all the other ICSP wires (RESET, SCK, MOSI, MISO).

To further confirm that all the ICSP signals are properly wired to the 32U4:

  1. Program the sketch included at the end of this reply into the Arduino you’re using as an ICSP. This sketch will toggle (only) one of the ICSP signals on for 4 seconds then off for 4 seconds, repeatedly.
  2. With the unchanged sketch loaded, power up the ICSP with it attached to your board. The “pin 13” LED on the ICSP should be toggling on for 4 seconds then off for 4 seconds.
  3. Use the multimeter to measure the voltage between a GND pin on the 32U4 and the 32U4 SCK pin (9). It should toggle between 5V for 4 seconds then 0V for 4 seconds, matching the LED on the ICSP.
  4. Measure voltage between a 32U4 GND and each of the other ICSP signal pins (RESET, MOSI, MISO). They should all remain at 0V while SCK is toggling.
  5. Modify the sketch (by commenting and uncommenting lines 5-8) to toggle the MISO pin and upload it to the ICSP. The LED won’t toggle, so use the multimeter to make sure the MISO pin on the ICSP is toggling between 0V and 5V.
  6. Check that 32U4 MISO (11) is toggling and all other 32U4 ICSP signals are at 0V on the 32U4, as was done above for SCK.
  7. Do the same sketch change and voltage tests for the MOSI and RESET pins.

If all the above looks OK you should be able to burn a sketch or bootloader into the 32U4 using the ArduinoISP sketch in the ICSP. Otherwise, likely either the crystal circuit has wiring problems (miswired, opens, shorts) or the 32U4, crystal, or one of the 22pF capacitors is damaged. There’s also the possibility, as @Mr.Blinky said, that the 32U4 has its fuses set for an external clock instead of a crystal.

//  Pin toggle for ICSP connection testing
//  Turns a pin on for 4 seconds, then off for 4 seconds, repeatedly.

// Uncomment one of these and comment out the other 3 to select a pin to test
#define TEST_PIN 13 /* ICSP SCK. The LED will toggle only for this one */
//#define TEST_PIN 12 /* ICSP MISO */
//#define TEST_PIN 11 /* ICSP MOSI */
//#define TEST_PIN 10 /* ICSP RESET */

#define TOGGLE_TIME 4000 /* 4000ms = 4 seconds */

void setup() {
  // Set all ICSP pins as low outputs
  pinMode(13, OUTPUT);
  digitalWrite(13, LOW);
  pinMode(12, OUTPUT);
  digitalWrite(12, LOW);
  pinMode(11, OUTPUT);
  digitalWrite(11, LOW);
  pinMode(10, OUTPUT);
  digitalWrite(10, LOW);

void loop() {
  digitalWrite(TEST_PIN, HIGH);
  digitalWrite(TEST_PIN, LOW);
1 Like

I understand the 8Mhz clock now, I use a separate pro micro. I’ll give it a go and if it doesn’t work I’ll try out MLXXXp’s methods.

The pro micros I was given would’ve been cheap clones with the Arduino Leonardo bootloader installed.

I have looked into those before, but I found that the chip is really big and would take up a lot of PCB space. I can try moving the pins outwards (I’d even be willing to make a test PCB about how far out they are, even adjusting the width of the pads).

Correct, is that a tool I should add to my arsenal of electrical tools?

I’ll get to it today, I’ve been busy for the past 2 days so I haven’t had time to sit down for a while.

Unlikely since the pro micros were desoldered and all the components were put in the same bag. But you never know, it might be the case.

So the ATmega32U4 that you put on your board came from a working Pro Micro? If that’s the case, its bootloader would be compatible with your board and you shouldn’t have to burn a new one. You should be able to connect the USB port to a PC, connect the battery, switch it on and upload a sketch using the Arduino IDE (with the board type set as Pro Micro).

If you can’t then you have a bad component(s), incorrect wiring, or shorts or opens.

Again, if the 32U4 came from a working Pro Micro, then the fuses will be set for using a crystal as the clock generator. You shouldn’t need an external clock.

If you think the 32U4 is set to use a crystal, it might not be a good idea to feed the chip an external clock.

It depends how far you want go with electronics and whether that justifies the cost. If you had a capable one, you could probably use it to see if your crystal circuit is oscillating properly and thus generating the required clock for the processor. That would rule out one of the biggest possible problems.

Well it will fit on a board the size of a Pro Micro and it appears you have a fair amount of space around the 32U4 on your board.

Unforunately, no success on that part. I still got the Device signature = 0x000000 error

It measured 0 ohms when connected to power, and 0.874kOhms when not connected to power. That is when I probed the ICSP pads on the Arduboy. A search suggests that there should be a resistance difference when it’s not short circuited.

I measured 4.2v across the Nano, working Pro Micro, and Arduboy.

RESET seems to be very odd, I GND it directly from the ATMega and I’ve connected a wire to the RESET on the Nano but shorting them doesn’t make the Nano Reset. I was able to illuminate the RX, TX, and Red (but it might’ve needed to been green) LEDs when I probed the ATMega directly and connected it to GND.

I’ve just tested and something very strange is happening. I can probe the Red LED pin on the ATMega and it still lights, even using 1 probe for some reason (I’m using a sewing needle too). It might be a bit of scratched PCB GNDing it though. If it wasn’t, what could it mean?

I’ll try this and see what I can find.

SCK/CLK - I was unable to probe the ATMega directly but using the ICSP Pads on the Arduboy I can measure 4.2v. no readings on other pins
MISO - Same as CLK.
MOSI - Same as CLK.
RESET - Same as CLK.

The only next solution I can think of is desoldering the ATMega, finding another one and soldering it on.

Doing a resistance check on all the ICSP connections to GND when not powered shows:
CLK - 18 MOhms
MISO - 18 MOhms
MOSI - 18 MOhms
VCC - 0.846 kOhms
RESET - 10.8 kOhms

A bit of internet browsing does suggest I might have a bad oscillator, even the error message says Oscillator: Off so perhaps I should replace that first.

You should never measure resistance when a circuit is powered up.

What voltage do you get between the Nano’s GND and VCC (5V) pins when connected to USB but not connected to your board? It should be 5V. If it drops to 4.2V when you connect the Nano to your board then something is wrong. It should remain close to 5V.

If you’re measuring resistance between 32U4 pins and GND, I never asked you to do that (except GND on the board to the 32U4 GND pins). Any LEDs that are lighting when probing for resistance are probably being powered by the current that the meter uses to measure resistance. Again, you should never measure resistance (ohms) when the circuit is powered up.

The first thing to figure out is why you’re only getting 4.2V instead of 5V (+/- 2.5%). It’s no use doing anything else until that is solved.

1 Like

I have the basic understanding of electricity but never knew about this, so I’ll avoid doing it again. I wouldn’t be surprised if I managed to fry something important doing that.

It sits at 4.65v.

I did have the Nano left on for a lengthy amount of time with a previous project that drew a fair amount of current but less than what its rated for. But I don’t know if that would change anything. If I need to I could solder the bare minimum (That would be the MCU, crystal, and 2 22pF capacitors, correct?) to a spare PCB with another set of pro micro parts.

If that’s without being connected to your board, then either the PC is providing less than 5V on its USB port or you have a high resistance USB cable. Can you try a different cable and/or a different PC USB port or use a USB charging supply/adapter?

1 Like

I tried a pro micro and connecting it to a USB charging supply and I still got 4.65v. I did however try a usb power supply for breadboards (they usually have a usb port and a 9v jack port which changeable voltages) and I was able to get 5v out of that connected to my laptop.

4.65V is OK but it has to be solid. If it drops to 4.2V on both the ICSP and your board when the board is connected, it indicates that your board is drawing heavy current. If the ISCP remains at 4.65V when the board is at 4.2V either the board is drawing heavy current or the VCC and/or GND wires connecting them have a high resistance.

1 Like

It’s no longer showing a large drop, I measured it connected to a pro micro (sitting at 4.65v) and got the same voltage. I think my best bet is to try and solder up another one with bare minimum and see if that changes anything, if not then it might be the PCB. If it is the PCB then I’ll change up the design (there was some previous changes needed anyway), order them, wait a bit (I don’t mind since I have another working Arduboy, just not an FX one), and try it again. I’ll definitely move those pads outwards a lot since that would provide a better look at the connection.

1 Like

@MLXXXp So the bare minimum for one is 2x 22pF capacitors, the oscillator, and MCU? Currently I’m just tweaking my PCB design (Do note that I use Auto Route on EasyEDA so the routing is questionable, I might spend the time to route it myself so it’s neater and better)


If you’re updating the board, I would add at least one decoupling capacitor for the 32U4. Also, move the crystal and 22pF capacitors closer to the XTAL1 and XTAL2 pins to make the traces as short as possible.

1 Like