Go Down

Topic: Error compiling Bootloader? (Read 1 time) previous topic - next topic

pcfr33k

Oct 08, 2012, 01:49 am Last Edit: Oct 08, 2012, 02:00 am by pcfr33k Reason: 1
I have a second ATmega328 chip on breadboard using TinyUSBISP to burn the bootloader.

I seem to be having an error in Main when checking the script before I load it to the chip

C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-g++ -c -g -Os -Wall -fno-exceptions -ffunction-sections -fdata-sections -mmcu=atmega328p -DF_CPU=16000000L -MMD -DUSB_VID=null -DUSB_PID=null -DARDUINO=101 -IC:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\arduino\cores\arduino -IC:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\arduino\variants\standard C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\sketch_oct07a.cpp -o C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\sketch_oct07a.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WInterrupts.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_analog.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_digital.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_pulse.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_shift.c.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\CDC.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\HardwareSerial.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\HID.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\IPAddress.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\main.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\new.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Print.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Stream.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Tone.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\USBCore.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WMath.cpp.o
  Using previously compiled: C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WString.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WInterrupts.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_analog.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_digital.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_pulse.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\wiring_shift.c.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\CDC.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\HardwareSerial.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\HID.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\IPAddress.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\main.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\new.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Print.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Stream.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\Tone.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\USBCore.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WMath.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-ar rcs C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\WString.cpp.o
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\tools\avr\bin\avr-gcc -Os -Wl,--gc-sections -mmcu=atmega328p -o C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\sketch_oct07a.cpp.elf C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\sketch_oct07a.cpp.o C:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp\core.a -LC:\Users\pcfr33k\AppData\Local\Temp\build6502781173554477768.tmp -lm
core.a(main.cpp.o): In function `main':
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\arduino\cores\arduino/main.cpp:11: undefined reference to `setup'
C:\Users\pcfr33k\Downloads\arduino-1.0.1\hardware\arduino\cores\arduino/main.cpp:14: undefined reference to `loop'

MarkT

You appear to be compiling with main() for sketches, bootloader shouldn't pull that in, has its own main I think.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

pcfr33k

That must be why.  I still have a problem though.  I get an error if I do not hold down the manual reset switch until its done?

I have it on a breadboard with a Manual Reset switch with Resister and capacitor.  If I hold switch down switch the entire time I get a successful burn and verification.

If I hold it down 3/4 of the time and let it go before its done burning and verifying,  I get a verification error at the end!!

For example Verification Error, first mismatch at byte 0x0000
0xff != 0x04
Content mismatch

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy