Hello,
For context, I’m quite new to operating microprocessors. Apologies in advance, if I’m slow to understand what I’m doing wrong.
I’m currently trying to upload a .hex file through the Pololu USB AVR Programmer v2.1. I’m doing so, using:
- An ATmega324A microprocessor.
- AVR-GCC (for MacOS) for file assembly and compilation.
- AVRDUDE for uploading the program to the microprocessor.
When I first used the setup, I was able to pass the code to the AVR just fine.
But now, when I try and pass the same code again, I get the following error:
avrdude error: command failed
avrdude error: initialization failed, rc=-1
- double check the connections and try again
- use -B to set lower the bit clock frequency, e.g. -B 125kHz
- use -F to override this check
avrdude done. Thank you.
After checking through some of the forum posts, I checked the Configuration Status and got this:
Name: Pololu USB AVR Programmer v2.1
Serial number: 00255520
Firmware version: 1.02
Programming port: /dev/cu.usbmodem002555202
TTL port: /dev/cu.usbmodem002555204
Settings:
ISP frequency (kHz): 114
Max ISP frequency (kHz): 1714
Regulator mode: auto
VCC output: Disabled
VCC output indicator: Blinking
Line A function: None
Line B function: DTR
VCC/VDD maximum range (mV): 896
VCC 3.3 V minimum (mV): 2720
VCC 3.3 V maximum (mV): 3872
VCC 5 V minimum (mV): 4128
VCC 5 V maximum (mV): 5856
STK500 hardware version: F
STK500 software version: 2.A
Results from last programming:
Programming error: Initial SPI command failed.
Target VCC measured minimum (mV): 5120
Target VCC measured maximum (mV): 5248
Programmer VDD measured minimum (mV): 4896
Programmer VDD measured maximum (mV): 4960
Current status:
Target VCC (mV): 5152
Programmer VDD (mV): 4928
VDD regulator set point: 5 V
Last device reset: Power-on reset
I tried rewiring the Vcc & GND wires of breadboard connecting to the AVR, but the result is the same.
Is there something I’m missing?