Go Down

Topic: Guide: How to use an Arduino as an In System Programmer (ISP) (Read 23645 times) previous topic - next topic


Hmm, that's weird.
Are you sure you have connected everything to the atmega8? Like all ground connections, VCC and a crystal (if you are using that).



I tried to replace the card with another Arduino Mega 2560 and also the ATmega8 chip.
I'm using version 0.23 of the IDE.
AVRDUDE used is provided with the IDE.
I also added the crystal.

But the result is always the same.

You can see photo of the installation.


Feb 20, 2012, 04:30 pm Last Edit: Feb 22, 2012, 03:55 pm by Lauszus Reason: 1

You should install avrdude separately and not use the one bundled with the Arduino software - I have seen other people having problems with the bundled one as well.

I recommend downloading either WinAVR: http://winavr.sourceforge.net/ if you are running Windows or CrossPack: http://www.obdev.at/products/crosspack/index.html if you use MAC OS X. As they include all you will ever need like: a compiler (avr-gcc), programmer (avrdude), and debugger (avr-gdb) plus more.
You can also just download avrdude seperatly: http://savannah.nongnu.org/projects/avrdude, but I can't see the point, as WinAVR and CrossPack is just way faster to get installed.

Hope that did the trick :)



Thank you very much, but:
I downloaded WinAVR, type 'avrdude -p m8 -P com4 -c avrisp -b 19200' in C:\WinAVR-20100110\bin directory, and result is:
avrdude.exe: stk500_program_enable(): protocol error, expect=0x14, resp=0x50
avrdude.exe: initialization failed, rc=-1
             Double check connections and try again, or use -F to override
             this check.

avrdude.exe: stk500_disable(): protocol error, expect=0x14, resp=0x51

I downloaded avrdude-5.11-Patch7610-win32, but the result is the same.

The problem could be the  bootloader?



Hmm, are you sure that you have connected it the right way? See this post for more info: http://www.ladyada.net/make/usbtinyisp/help.html
Also take a look at this old thread, where people are discussing some of the errors you get: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1248528012/all



I found a oscilloscope and checked Arduino pins (10,11,12,13):
they don't move when I type 'avrdude -p m8 -P com4 -c avrisp -b 19200'.

What it means?



Are you sure com4 is the correct port? Also try to use "-c arduino" instead if "-c avrisp".



Hi Lauszus, com4 is correct, IDE Serial Port is com4 (upload ArduinoISP Sketch) and when type "avrdude -p m8 -P com4 -c avrisp -b 19200" RX and TX leds in Arduino Mega 2560 blinking.

I used "-c arduino" instead of "-c avrisp", avrdude return:
avrdude.exe: stk500_getsync(): not in sync: resp=0x00

But with "-c arduino" instead of "-c avrisp" pin 13 (SCK) goes high for about 300 ms.



Hi Lauszus,
After many attempts I tried to use Arduino UNO.
At the first shot it's worked.

I thank you for your support, I don't know why Mega 2560 doesn't work.




hi lauzsuz,
i have questions:
1) can i have program my at89s52 with tis isp concept
2) where i find avrdude program (or we program our chip over arduino)
3)how we connect our chip to arduino uno?


where i find avrdude program (or we program our chip over arduino)

It is in the Arduino distribution, on my PC - C:\Program Files (x86)\arduino-0022\hardware\tools\avr\bin -
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)


1) can i have program my at89s52 with tis isp concept

It seems like a lot of people have tried to port it, but it's still not supported in avrdude, so I don't think it will be that easy.
Here is a example of a old post I found: http://old.nabble.com/How-to-add-AT89S52-to-avrdude-support-list--td24198268.html

2) where i find avrdude program (or we program our chip over arduino)

It's much easier to just download WinAVR (http://winavr.sourceforge.net/) or CrossPack (http://www.obdev.at/products/crosspack/index.html) as you will also get the newest version of avrdude.

3)how we connect our chip to arduino uno?

Check the datasheet for your chip and connect MOSI, MISO and SCK to pin 11 (MOSI), 12 (MISO) and 13 (SCK) on your Arduino. Then connect pin 10 (Slave select or just SS) on your Arduino to the reset pin of your chip.



Hi all!

I had the same problem - avrdude.exe: stk500_getsync(): not in sync: resp=0x00
If someone still need a solution, Try next: "avrdude -p m328p -P //./COM5 -c avrisp -b 19200"
It helps me. Good luck!


Jan 16, 2014, 06:25 am Last Edit: Jan 16, 2014, 06:53 am by Yigiter007 Reason: 1
So I bought the Graphic LCD Serial Backpack (https://www.sparkfun.com/products/9352) and I'm trying to upload a updated firmware to add the needed flow control from http://serialglcd.sourceforge.net/ I have read through the comments and came across this forum. I also found a comment that the file being over sized and a solution here https://code.google.com/p/mega-isp/issues/detail?id=14&can=1 . It was also commented to use Mega ISP  http://playground.arduino.cc/Code/MegaISP

Where I'm stuck is step 5. I never used WinAVR. Can someone explain step 5. Which program is doing the compiling and which file is being compiled? I downloaded the serialGLCD1.62 files and there are a bunch of files inside.

"5) Compile the program to make a hex file, this can be done by typing "make all"  in a terminal while inside the folder (use "cd" and then the path to the folder - see step 11 for help)
You might have to change some setting for it to work. If there is already an hex file (as in my example) you can just skip this step"

So far I have the following filles

And the following programs
Arduino programmer

Hardware I'm using
Graphic LCD 128x64 https://www.sparkfun.com/products/710
Graphic LCD Serial Backpack https://www.sparkfun.com/products/9352
Pocket AVR Programmer https://www.sparkfun.com/products/9825

Thanks in advance

Should I follow this forum's tutorial or the sparkfun one here (https://learn.sparkfun.com/tutorials/serial-graphic-lcd-hookup/firmware-overview) ? Is one newer? Can the sparkfun be applied to any firmware?

P.S.S Has sparkfun actually updated the firmware from the original? Do i need to still update it?

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!

via Egeo 16
Torino, 10131