0

Standalone AVR Chip Programmer - Upload code on Arduino V1.0
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Standalone AVR Chip Programmer - Upload code on Arduino V1.0

by rossco_s on Sat Dec 16, 2017 2:45 am

Hi,
I have a Standalone AVR Chip Programmer thats been sitting in my parts box for some time and I want to use it to burn some bootloaders.

If I use it as specified in the ArduinoISP, it works, but I want it to be standalone.

When following the Standalone guide, if I try compiling the AdaLoader sketch in Arduino version 1.8.5 I get the following:
Code: Select all | TOGGLE FULL SIZE
/root/Arduino/AdaLoader/AdaLoader.ino: In function 'void loop()':
/root/Arduino/AdaLoader/AdaLoader.ino:82:27: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Signature fail");
                           ^
/root/Arduino/AdaLoader/AdaLoader.ino:84:23: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Image fail");
                       ^
/root/Arduino/AdaLoader/AdaLoader.ino:89:35: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Programming Fuses fail");
                                   ^
/root/Arduino/AdaLoader/AdaLoader.ino:92:35: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Failed to verify fuses");
                                   ^
/root/Arduino/AdaLoader/AdaLoader.ino:113:36: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
    error("Flash programming failed");
                                    ^
/root/Arduino/AdaLoader/AdaLoader.ino:121:35: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Programming Fuses fail");
                                   ^
/root/Arduino/AdaLoader/AdaLoader.ino:128:34: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Failed to verify chip");
                                  ^
/root/Arduino/AdaLoader/AdaLoader.ino:134:35: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
     error("Failed to verify fuses");
                                   ^
/tmp/ccTbQny2.ltrans0.ltrans.o: In function `start_pmode()':
/root/Arduino/AdaLoader/AdaLoader.ino:170: undefined reference to `spi_transaction(unsigned char, unsigned char, unsigned char, unsigned char)'
/tmp/ccTbQny2.ltrans0.ltrans.o: In function `setup':
/root/Arduino/AdaLoader/AdaLoader.ino:51: undefined reference to `pulse(int, int)'
/root/Arduino/AdaLoader/AdaLoader.ino:53: undefined reference to `pulse(int, int)'
/tmp/ccTbQny2.ltrans0.ltrans.o: In function `loop':
/root/Arduino/AdaLoader/AdaLoader.ino:81: undefined reference to `readSignature()'
/root/Arduino/AdaLoader/AdaLoader.ino:83: undefined reference to `findImage(unsigned int)'
/root/Arduino/AdaLoader/AdaLoader.ino:86: undefined reference to `eraseChip()'
/root/Arduino/AdaLoader/AdaLoader.ino:88: undefined reference to `programFuses(unsigned char const*)'
/root/Arduino/AdaLoader/AdaLoader.ino:91: undefined reference to `verifyFuses(unsigned char const*, unsigned char const*)'
/root/Arduino/AdaLoader/AdaLoader.ino:105: undefined reference to `readImagePage(unsigned char*, unsigned int, unsigned char, unsigned char*)'
/root/Arduino/AdaLoader/AdaLoader.ino:112: undefined reference to `flashPage(unsigned char*, unsigned int, unsigned char)'
/root/Arduino/AdaLoader/AdaLoader.ino:120: undefined reference to `programFuses(unsigned char const*)'
/root/Arduino/AdaLoader/AdaLoader.ino:127: undefined reference to `verifyImage(unsigned char*)'
/root/Arduino/AdaLoader/AdaLoader.ino:133: undefined reference to `verifyFuses(unsigned char const*, unsigned char const*)'
collect2: error: ld returned 1 exit status
exit status 1
Error compiling for board Arduino Duemilanove or Diecimila.


If I try using Arduino 1.0 or Arduino 0023 I get the following message:
Code: Select all | TOGGLE FULL SIZE
./arduino: 22: ./arduino: java: not found

Which is weird because I don't have arduino 0022.

rossco_s
 
Posts: 40
Joined: Thu Jul 14, 2011 12:01 am

Re: Standalone AVR Chip Programmer - Upload code on Arduino

by rossco_s on Sun Dec 17, 2017 2:51 pm

Can anyone help me with this problem?

rossco_s
 
Posts: 40
Joined: Thu Jul 14, 2011 12:01 am

Re: Standalone AVR Chip Programmer - Upload code on Arduino

by franklin97355 on Sun Dec 17, 2017 9:46 pm

Can you post some pictures of the programmer and its connections?

franklin97355
 
Posts: 17313
Joined: Mon Apr 21, 2008 2:33 pm
Location: Lacomb, OR.

Re: Standalone AVR Chip Programmer - Upload code on Arduino

by rossco_s on Wed Dec 20, 2017 2:30 am

IMG_20171219_232256815_HDR.jpg
IMG_20171219_232256815_HDR.jpg (106.38 KiB) Viewed 82 times
Here is a photo.
It worked last time I used it, although that was quite some time ago.

The problem seems to be with the software side of things.

rossco_s
 
Posts: 40
Joined: Thu Jul 14, 2011 12:01 am

Re: Standalone AVR Chip Programmer - Upload code on Arduino

by rossco_s on Fri Dec 22, 2017 2:20 am

I just tried installing Arduino using apt-get package manager in Ubuntu. I still got some minor compile errors:

Code: Select all | TOGGLE FULL SIZE
images.cpp:3:17: error: variable ‘image_328’ must be const in order to be put into read-only section by means of ‘__attribute__((progmem))’
 image_t PROGMEM image_328 = {
                 ^


When I made image_t a const it compiled.

Would I be correct to assume that if I upload the code to a Uno and use the https://learn.adafruit.com/standalone-avr-chip-programmer/assembly to program the bootloader that I would then be burning Uno bootloaders?

I have a sneaking suspicion that since the Optiloader code is quite old ( ~5 years) that it may well be a Duemilanove. Would that be unfounded?

rossco_s
 
Posts: 40
Joined: Thu Jul 14, 2011 12:01 am

Re: Standalone AVR Chip Programmer - Upload code on Arduino

by rossco_s on Fri Dec 22, 2017 2:28 am

I just tried burning the bootloader onto a fresh ATmega328P-PU. I double checked the orientation, locked the chip in and pressed the button.

The red LED immediately came on and the buzzer sounded continuously. I had to unplug the Arduino to stop the buzzer.

I'm not sure how to proceed now. It would be great if an Adafruit moderator could chime in.

rossco_s
 
Posts: 40
Joined: Thu Jul 14, 2011 12:01 am

Please be positive and constructive with your questions and comments.