Hello,
Recently I stumbled on this instructable http://www.instructables.com/id/Ghetto-Programming%3A-Getting-started-with-AVR-micro/
to program AVR microcontrollers (ATtiny in my case) with a parallel port.
This worked wonderfully well.
Then I noticed that my arduino could be turned into an isp programmer. This is great because now I don't have to use that ancient computer on the attic.
I followed the steps on the arduino site and the forum to get everything ready (and since I use an arduinoUNO, they've told me to put a resistor between 5v and reset for it to work properly)
Now I can upload simple sketches written in the Arduino IDE on my ATtiny (you know, in tools->select board-> ATtiny2313 8Mhz). But, my sketches have to be really simple and since I want to use some I2C devices with my ATTiny, I can forget the Arduino IDE.
So, i want to use this instructable to learn I2C with ATtiny2313:
And instead of uploading it with winAVR on the the old computer with the parallel port, I want to use my Arduino as ISP. But that does not work.
This is what I have done:
For a test, I wanted to upload a small led-blinking program that certainly worked with the old computer with parallel port.
Since I don't use the parallel port anymore I had to change the "makefile" right?
I changed: "AVRDUDE_PROGRAMMER = dapa" -------------- into: "AVRDUDE_PROGRAMMER = avrisp" (arduino programmer is avrisp?)
"AVRDUDE_PORT = lpt1" ---------------------------------------into: "AVRDUDE_PORT = COM3" (because it is connected to COM3)
(Normally, I have attached my makefile and C program to this message)
And then I tried to get my blink sketch on my ATtiny.
But I always get:
avrdude -p attiny2313 -P COM3 -c avrisp -E reset -U flash:w:LED_Demo.hex
avrdude: WARNING: -E option not supported by this programmer type
avrdude: stk500_getsync(): not in sync: resp=0x00
avrdude done. Thank you.
make.exe: *** [program] Error 1
And the haertbeat led stops beating.
(If I do it manually wit the cmd, I get the same "not in sync" error).
And if I upload the blink example from and in the arduino IDE it works perfectly fine, so everything should be connected well.
I am not familiar with programming microcontrollers so there must be something I didn't see.
Thank you very much if you have some advice!
LED_Demo.c (473 Bytes)
Makefile (10.3 KB)