Show Posts
Pages: [1]
1  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 23, 2013, 02:22:19 pm
I was finally able to upload the Blink sketch to the ATtiny2313! I tried Ernis suggestion and moved it to a different breadboard and it worked right away. I feel kind of stupid for not thinking of trying that on my own.
Thanks so much for your help, guys.
2  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 23, 2013, 06:42:05 am
I will do that this evening. I'm not sure what you mean by "target removed", though. Just without the ATtiny2313?
3  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 05:08:42 pm
Here it is, thanks for having a look. I kind of hope to be embarrassed by you spotting the error right away.
4  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 03:17:22 pm
Hm, thanks, but re-re-re-checked and checked again when you said it is wrong, I have no idea what might be wrong. It is wired excactly like it is described in the tutorial and I double checked with the picture also, just to be sure. The ATtiny2313 is not upside down. I don't know what to do different.
I guess the resistors would only prevent damage but not solve my problem, right?
5  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 02:18:01 pm
Oh, sorry, the "not in sync" error was due to the "AVR ISP" I had set as programmer. When I switched it to "Arduino as ISP" I only get the "programmer not responding" error. Here is the avrdude output:

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

         System wide configuration file is "/Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf"
         User configuration file is "/Users/gringle/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/tty.usbmodem1d11
         Using Programmer              : stk500v1
         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                      : ATtiny2313
         Chip Erase delay              : 9000 us
         PAGEL                         : PD4
         BS2                           : PD6
         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        128    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      2048   32     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] # [23] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00]   [20] . [00] . [80] . [00] . [00] . [08] . [00]   [20]
avrdude: Recv: . [14]
avrdude: Recv: . [10]
avrdude: Send: E [45] . [05] . [04] . [d4] . [d6] . [01]   [20]
avrdude: Recv: . [14]
avrdude: Recv: . [10]
avrdude: Send: P [50]   [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
 
6  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 01:36:37 pm
Still the same result, I uploaded the different ArduinoISP sketch, unplugged the board, put the capacitor in, selected ATtiny2313@1Mhz and Ardunino as ISP and then clicked Upload with programmer.

programmer is not responding.
7  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 05:59:57 am
Thanks for the update, I will try this when I get home this evening.

@Coding Badly: I thought this was done with the 10 µF capacitor from reset to ground as it was mentioned in Ernis tutorial and also at http://arduino.cc/en/Tutorial/ArduinoISP. Do I also need a 120 Ohm resistor between 5V and Reset?
8  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 22, 2013, 03:17:51 am
Ok, so I rechecked the wiring and did everything according to http://www.ernstc.dk/arduino/2313.htm.
I uploaded ArduinoISP and checked with an LED on pin 9. Then I unplugged the Arduino Board, connected the capacitor from Ground to Reset, plugged it in again, chose ATtiny2313@1MHz in the Board menu and tried to upload the Blink sketch.  This is what I got:
avrdude: stk500_getsync(): not in sync: resp=0xe0

I unplugged and replugged the Arduino again and tried the same with ATtiny@8Mhz: Same error.

This is all with AVR ISP chosen as programmer. When I try this with Arduino as ISP, I get a lot more avrdude: Send and avrdude: Recv messages but it ends with
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding

Any idea what I might be doing wrong?
9  Using Arduino / Microcontrollers / Re: Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 21, 2013, 12:27:53 pm
Thanks for your answers.

Nick, I had a look at your solution, it looks interesting but might be a bit too much for what I'm trying to do.

Thanks for the tip about the verbose output, Erni. Since I was able to install Tiny-core now, I'll give it a try. Maybe I tried the wrong avrdude command.
10  Using Arduino / Microcontrollers / Trying to use Arduino Uno R3 as ISP for ATTiny2313 on: January 20, 2013, 08:44:53 am
Hi,

I want to program a ATTiny2313 with a hex file and since I recently got myself an Arduino Uno, I am trying to use it as an ISP and upload the hex file with avrdude. I am working with OSX.

Mainly I have been following this tutorial: http://www.ernstc.dk/arduino/2313.htm
I also read (among many other stuff) this thread: (http://arduino.cc/forum/index.php/topic,84943.0.html)

According to the tutorial I connected the 2313 to the Arduino board.

Some things are not clear to me, hopefully someone can help me a bit. I do not want to program the 2313 using the Arduino IDE, I just want to upload an existing hex file with avrdude. Do I need to install the Tiny-core as explained in the tutorial for this? If so, I need some help with that as well. I tried to install it according to the ReadMe.txt but I can't get the new options to show up in the Tools->Board menu in the Arduino IDE. I extracted the Tiny-core into Documents/Arduino/libraries/hardware/ while the IDE was closed, but when I started it again I didn't have any new options.
I figured out how to install the Tiny-core. For anyone who might also have problems with this: Go to your application folder and Ctrl-Click the Arduino.app file and choose Show Package Contents. Then navigate to the Contents/Resources/Java/hardware folder and copy the tiny folder into it.

I uploaded the ArduinoISP sketch to the Arduino and tested it with an LED, which was fading on and off so I guess at least that worked.

Hopefully someone can give me a few pointers in the right direction.

Pages: [1]