Mega 2560 as ISP for ATTiny

For the past few days, I have been trying unsuccessfully to program an ATTiny45 AVR using an Arduino Mega 2560 as the ISP. All of the tutorials I have seen for using the Arduino as an ISP use the Uno and the Duemilanove. None of them mention the Mega2560.

I was wondering if something in the wiring or programming needed to be changed when using the Mega2560. For example, is a capacitor used between reset and ground? Or should a resistor connect reset to 5V? Before I started posting my specific error messages, I thought I would check to see if the problem was a simple difference between Uno/Duemilanove and Mega2560 setup.

Now this sounds familiar. Try reading this:

http://arduino.cc/forum/index.php/topic,99432.0.html

Thanks for pointing me in that direction. I had searched the forums for an answer all last week, but didn't post my question until this week. In the intervening time, that other thread answered my main question.

I have changed the MISO, MOSI, etc. to the correct pins for the Mega2560. This improved the situation to a degree. At least now the error messages are consistent.

When I try to burn the bootloader to the ATTiny45 @ 8 MHz, I get the error stk500_initialize(): programmer not in sync, resp=0x15. The same error occurs trying to burn the bootloader as an ATTiny45 @ 1 MHz. When I try to upload a sketch with the board set to the ATTiny at either 1 MHz or 8 MHz, I again get the same error.

I have tried changing the baud rate from 19200 to 9600, but that hasn't helped.

I am using the ArduinoISP for the programmer, and I have a 10uF capacitor between +5V RESET and GND to stop the Arduino from resetting.

Any thoughts on what might be causing this?

kwilson68:
Any thoughts on what might be causing this?

Yup...

I am using the ArduinoISP for the programmer, and I have a 10uF capacitor between +5V and GND to stop the Arduino from resetting.

Capacitor is connected to RESET and +5V (not GND) and GND. Be sure to get the polarity correct.

Sorry, I meant to say that I had the capacitor between RESET and GND.

Are you sure that the capacitor should be between RESET and +5V? The tutorials I have seen have said that the capacitor goes from RESET to GND. Some also suggest that a 120ohm resistor between RESET and +5V would work as well. One thread on the old forum even mentioned connecting both.

This is why I was unsure about the wiring for using the Arduino as an ISP. Can you confirm that the capacitor should go from +5V to RESET? You also mentioned getting the polarity correct. I would assume the negative lead goes to RESET, but correct me if I am wrong.

I appreciate your help. I have a lot of experience with programming, but I am new to playing with electronics.

kwilson68:
Sorry, I meant to say that I had the capacitor between RESET and GND.

Oh rats! The capacitor goes between RESET and GND. I apologize for the mistake.

Some also suggest that a 120ohm resistor between RESET and +5V would work as well. One thread on the old forum even mentioned connecting both.

I've read those things as well. I suggest trying: capacitor, resistor, then both. The goal is to disable auto-reset. If it looks like the board resets when an upload starts then try a different method.

I also suggest an LED (and series resistor) on pin 9. A "heartbeat" should always be present.

I have now added a 110ohm resistor between +5V and RESET and a 10uF capacitor between RESET and GND. With this configuration, I still get the message:

avrdude: stk500_initialize(): programmer not in sync, resp=0x15
avrdude: initialization failed, rc=-1

Despite this error, the IDE says that it has finished uploading. Before, the bar above the serial window in the IDE was turning orange and reporting an error, so I am counting this as a small step in the right direction. But I still get that error when trying to burn a bootloader (i.e., set the clock fuses) on the ATTiny45.

I have had a heartbeat on Pin 9 the whole time, and it is pulsing fine. It continues pulsing through the entire process of uploading the script. I just added error and communication LEDs on 8 and 7 respectively. They pulse twice when ArduinoISP is started (or reset), but do not come on at all during the programming of the ATtiny45.

Here is the initial avrdude output, in case that tells you something:

         Using Port                    : \\.\COM3
         Using Programmer              : stk500v1
         Overriding Baud Rate          : 9600
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
         AVR Part                      : ATtiny45
         Chip Erase delay              : 4500 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : possible i/o
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

Just to see what would happen, I removed the wires connecting the MOSI and MISO on the Mega2560 with those on the ATTiny45. I got the exact same error as before, so I suspect the Mega is not even getting to the point of communicating with the ATTiny45.

Thanks for your help.

It looks to me like it received the part number, so, so far so good.

Is the ArduinoISP designed for the Attiny45? I don't know for sure whether it is or not.

For around $22 you could order the USBtinyISP device and use that. It might save some pain.

I can confirm that it works with ATtiny45 processors.

Overriding Baud Rate : 9600

Did you change the ArduinoISP sketch to 9600 baud?

Yes. One of the tutorials said the Arduino IDE 1.0 reduced the buffer size and recommended reducing the baud as well to avoid overflowing the buffer.

Believe me, I have seriously considered it at several points. But given that the Arduino is supposed to be able to do this and a number of people have gotten it to work, I'm determined to make it work myself.

Try using avrdude with -vvvv option to see just how far through it gets.

Here is the output with it set to verbose:

Binary sketch size: 756 bytes (of a 4096 byte maximum)
C:\Program Files (x86)\arduino-1.0\hardware/tools/avr/bin/avrdude -CC:\Program Files (x86)\arduino-1.0\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -pattiny45 -cstk500v1 -P\\.\COM3 -b9600 -Uflash:w:C:\Users\Kevin\AppData\Local\Temp\build6208833073255571373.tmp\ModifiedBlink.cpp.hex:i 

avrdude: Version 5.11, compiled on Sep  2 2011 at 19:38:36
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "C:\Program Files (x86)\arduino-1.0\hardware/tools/avr/etc/avrdude.conf"

         Using Port                    : \\.\COM3
         Using Programmer              : stk500v1
         Overriding Baud Rate          : 9600
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
         AVR Part                      : ATtiny45
         Chip Erase delay              : 4500 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : possible i/o
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65     6     4    0 no        256    4      0  4000  4500 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           flash         65     6    32    0 yes      4096   64     64  4500  4500 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lock           0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           hfuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           efuse          0     0     0    0 no          1    0      0  9000  9000 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           calibration    0     0     0    0 no          2    0      0     0     0 0x00 0x00

         Programmer Type : STK500
         Description     : Atmel STK500 Version 1.x firmware
avrdude: Send: A [41] . [80]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [02] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [12] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [98]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
         Hardware Version: 2
         Firmware Version: 1.18
         Topcard         : Unknown
avrdude: Send: A [41] . [84]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [85]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [86]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [87]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [89]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
         Vtarget         : 0.0 V
         Varef           : 0.0 V
         Oscillator      : Off
         SCK period      : 0.1 us

avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [12] 
avrdude: Recv: . [10] 
avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [01] . [00] . [00] . [00] . [10] . [00]   [20] 
avrdude: Recv: . [15] 
avrdude: stk500_initialize(): programmer not in sync, resp=0x15
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [01] . [00] . [00] . [00] . [10] . [00]   [20] 
avrdude: Recv: . [15] 
avrdude: stk500_initialize(): programmer not in sync, resp=0x15

**********[deleted]**********

avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [01] . [00] . [00] . [00] . [10] . [00]   [20] 
avrdude: Recv: . [15] 
avrdude: stk500_initialize(): programmer not in sync, resp=0x15
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.

avrdude: Send: Q [51]   [20] 
avrdude: Recv: . [15] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: Q [51]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 

avrdude done.  Thank you.

The [deleted] section above merely repeats

avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [01] . [00] . [00] . [00] . [10] . [00]   [20] 
avrdude: Recv: . [15] 
avrdude: stk500_initialize(): programmer not in sync, resp=0x15

over and over again (roughly 30 times), until it eventually spits out initialization failed, rc=-1 and gives up.

Photo please?

         Hardware Version: 2
         Firmware Version: 1.18

That is a response from ArduinoISP. Up to that point, everything is in good order.

If auto-reset was firing, the bootloader would run and potentially respond (but probably not at 9600 baud). We would expect something like this for a response...

         Hardware Version: 3
         Firmware Version: 3.3
avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [01] . [00] . [00] . [00] . [10] . [00]   [20] 
avrdude: Recv: . [15]

Everything up to that point appears to be correct. fill consumes the 20 bytes and then checks for a space (0x20). It blocks until a character arrives. As far as I can tell, there are only two possibilities: 1. The space was corrupted; 2. The two sides are hopelessly out of synchronization. Unfortunately, the evidence indicates that neither is true.

It's time for black-box probing: How does it behave when the baud rate is 19200?

Here is a photo of my setup (without the USB cable).

It might be difficult to tell from the photo which pins are attached where, so for the SPI pins:

  • Red to 52
  • White to 50
  • Blue to 51
  • Orange to 53

The top of the breadboard has the red rail connected to +5V. This feeds the ATTiny and the line that runs through the two resistors and back to RESET. The resistors are 10ohms and 100ohms in series. A 10uF capacitor is also connected to the RESET line and then to the ground pin below 53 (a green wire) on the Mega2560. The setup on the left is the three LEDs on pins 9, 8, and 7 for feedback from ArduinoISP. The ground rail on the bottom of the breadboad grounds out the LEDs and the ATTiny.

And just for the sake of completeness, the desk is made of oak.

Well this is what I tried - with success ...

I had an Attiny85 to hand, not an Attiny45 - but it's the same datasheet.

Orange: Attiny85 pin 5 (MOSI) to Mega pin 51
White: Attiny85 pin 6 (MISO) to Mega pin 50
Red: Attiny85 pin 7 (SCK) to Mega pin 52
Green: Attiny85 pin 1 (/RESET) to Mega pin 53

Blue: Gnd
Other red on right: +5V

47uF cap between Mega /RESET and Gnd

Decoupling 0.1 uF cap on breadboard.
Other components not connected (from earlier test).

Loaded ArduinoISP from Examples in the 1.0 Version of the IDE.

Hit reset button on the Mega. Waited till flickering stopped.

Sent command:

avrdude -c arduino -p t85 -vvvv -P /dev/tty.usbmodemfd141 -b 19200

Got response:

avrdude: Version 5.8cvs, compiled on Jan 15 2010 at 17:27:01
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "/usr/local/CrossPack-AVR-20100115/etc/avrdude.conf"
         User configuration file is "/Users/nick/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/tty.usbmodemfd141
         Using Programmer              : arduino
         Overriding Baud Rate          : 19200
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
         AVR Part                      : ATtiny85
         Chip Erase delay              : 4500 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : possible i/o
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
...
         Programmer Type : Arduino
         Description     : Arduino
avrdude: Send: A [41] . [80]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [02] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [12] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [98]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
         Hardware Version: 2
         Firmware Version: 1.18
         Topcard         : Unknown
avrdude: Send: A [41] . [84]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [85]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [86]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [87]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [89]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
         Vtarget         : 0.0 V
         Varef           : 0.0 V
         Oscillator      : Off
         SCK period      : 0.1 us

avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [12] 
avrdude: Recv: . [10] 
avrdude: Send: B [42] . [14] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] @ [40] . [02] . [00] . [00] . [00]   [20] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: please define PAGEL and BS2 signals in the configuration file for part ATtiny85
avrdude: Send: P [50]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: AVR device initialized and ready to accept instructions

Reading |                                                    | 0% 0.00savrdude: Send: u [75]   [20] 
avrdude: Recv: . [14] . [1e] . [93] . [0b] . [10] 
Reading | ################################################## | 100% 0.04s

avrdude: Device signature = 0x1e930b
avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, lfuse value: e2
avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, lfuse value: e2
avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, lfuse value: e2
avrdude: safemode: lfuse reads as E2
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, hfuse value: df
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, hfuse value: df
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, hfuse value: df
avrdude: safemode: hfuse reads as DF
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, efuse value: ff
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, efuse value: ff
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, efuse value: ff
avrdude: safemode: efuse reads as FF
avrdude: Send: V [56] . [a0] . [01] . [fc] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [fd] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [fe] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [ff] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 

avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, lfuse value: e2
avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, lfuse value: e2
avrdude: Send: V [56] P [50] . [00] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [e2] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, lfuse value: e2
avrdude: safemode: lfuse reads as E2
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, hfuse value: df
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, hfuse value: df
avrdude: Send: V [56] X [58] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [df] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, hfuse value: df
avrdude: safemode: hfuse reads as DF
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 1, efuse value: ff
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 2, efuse value: ff
avrdude: Send: V [56] P [50] . [08] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [ff] 
avrdude: Recv: . [10] 
avrdude: safemode read 3, efuse value: ff
avrdude: safemode: efuse reads as FF
avrdude: safemode: Fuses OK
avrdude: Send: Q [51]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 

avrdude done.  Thank you.

So it all works. Now you just need to work out where you differ from those steps. :slight_smile:

Oh and the desk is Laminex I think. :stuck_out_tongue:

I had the same problem. I couldn't figure out how to program an ATtiny with an Arduino Mega as all the tutorials used Arduino Unos. I eventually figured it out and made my own tutorial and posted it on my blog.

http://jamestav.blogspot.com/2014/08/programming-attiny85-microchip-using.html

thatonekid123:
I had the same problem. I couldn't figure out how to program an ATtiny with an Arduino Mega as all the tutorials used Arduino Unos. I eventually figured it out and made my own tutorial and posted it on my blog.

http://jamestav.blogspot.com/2014/08/programming-attiny85-microchip-using.html

I viewed your blog...I do have to say the detail is good. However, ALL IC pins are counted in a U direction. Pin 1 denoted by a dot/indent or left of the indent on top. The ATTINY being 8 pins, 1 top left, 4 bottom left, 8 top right and 5 bottom right. So, I'm now gonna dig for the datasheet to find the pins. Might wanna fix that to make it correct. other than that...good job on the explanation