1

From my last question, I've managed to connect my Atmega32u4 to my computer.

Now, when attempted to initialise the bootloader using avrdude, I get the following error message:

j4cob-antergos :: ~ » sudo avrdude -p m32u4 -P usb -c flip1
avrdude: Warning: USB bDeviceClass = 255 (expected 254)
avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e9587 (probably m32u4)
avrdude: Error: "lfuse" memory not accessible using FLIP
avrdude: Error: "lfuse" memory not accessible using FLIP

avrdude: Error: "lfuse" memory not accessible using FLIP
avrdude: Error: "lfuse" memory not accessible using FLIP
avrdude: Error: "lfuse" memory not accessible using FLIP
avrdude: Error: "lfuse" memory not accessible using FLIP
avrdude: safemode: Sorry, reading back fuses was unreliable. I have given up and exited programming mode

avrdude done.  Thank you.

Now, I'm very confused. If I want to simply get a memory dump, I would've that the fact that the "Reading" loading bar reached 100% means that the memory was read, no?

I'm also not sure what the fuses mean. Am I using the wrong programmer? I'm using flip1, as you can see in the command.

Any help is much appreciated, thanks!

(If the circuit schematic is relevant, it can be found in my previous question, to which I linked at the top of this one.)

Jacob Garby
  • 714
  • 9
  • 18
  • The error message indicates that the configuration fuses cannot be accessed by this method. That will be a problem if they are not already set in the states you require. It does appear that the flash memory can be read - have you examined the output file and determined if it is within range of expectation? If you write a program and read it back, does the readback contain the same information written (note that hex files can and typically do differ even when representing the same data unless they are created by the same tool) – Chris Stratton Mar 01 '19 at 16:46
  • Typically fuses can only be changed by an external programmer such as an ISP adapter (something you can temporarily make by loading software onto another similar device, Arduino, etc...) – Chris Stratton Mar 01 '19 at 16:48
  • What exactly are fuses? I assume they don't mean the component which breaks with too much current? – Jacob Garby Mar 01 '19 at 16:50
  • That's a subject it would be worthwhile for your to do some searching and reading on - ie "atmega fuses" should be your search term. – Chris Stratton Mar 01 '19 at 17:00
  • @ChrisStratton Hmm.. I think I have a brief understanding of them now. Any idea what's wrong with my fuses though? What do I have to change? – Jacob Garby Mar 01 '19 at 17:07
  • There is no information that *anything* is wrong with the fuses, because the tool you are using is saying that it lacks the capability to read them. Essentially, you can either guess/hope that they are appropriately set and see if that proves true in practice (not implausible given you are already talking to it over USB) or you can use a different tool, for example put the ArduinoISP sketch into an Uno and check them with that. If you have done nothing to change them and the chip was new, the factory defaults are in the documentation. – Chris Stratton Mar 01 '19 at 17:08
  • I think this first read bar means the reading of the device ID, nothing more. Did you try to actually read the flash by giving the appropriate options to avrdude? – the busybee Jul 08 '20 at 12:10

1 Answers1

1

@JacobGarby I think referring to "27.5 Entering the Boot Loader Program" in datasheet would give you a clear idea about Fuses which is controlled in firmware. You should Program the Boot Reset Fuse in order to reset from bootloader. Boot Reset Fuse

These parts are shipped with Pre Programmed USB Bootloader