Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
I also had some trouble with my first attempt for avr910 ISP. But after that I started to use the parallel port programmer. Also good and a quite simple programmer is ponyprog / siprog combination, siprog has a simple contruction on RS232, and You could power the attiny device on its PCB from RS232. Take a look at www.lancos.com/prog.html
If You would like, I could send You my PCB in eagle format for the parallel programmer that fits in handle, but unfortunately I do not have it here on my office computer, so remind me if You would like.
has anyone checked the validity of this circuit?
in particular, i'm trying to program ATtiny2313
using the parallel port of my PC (winXP)
according to the schematics in the above link.
i use Ponyprog software to flash the chip (i select
parallel port interface in the options).
according to the link you only need a few resistors,
capacitors and one XTAL to make the circuit work, but
unfortunately i can't flash my ATtiny2313. I have
checked the connections, circuit etc many times,
but no luck. It's been so many weeks now that i'm
really straggliing with this... i can't believe that i can't
I am suspecting that the XTAL and the 2 capacitors used
to provide clocking do not work right. I use the probe of
my oscilloscope to measure the waveform accross one of
the capacitors, it should be like a sinewave? or maybe
the pin named XTAL2 on ATtiny2313 should possess a
rect waveform? thank you !!
I have tried this circuit but again it seems that I'm unlucky.
I always get this error message when i use PonyProg:
''Device missing or unknown device''.
I checked circuit for connection errors hundred of times.
I also checked consistently pin numbering of the PC socket
(I use ''Interface setup--> Serial connection --> S1 Prog I/O then COM1).
Are there any other options that someone has to change
within the PonyProg? I checked publisher's website for info as well.
Unbelievable, i have a feeling that i may have damaged uP after
so many programming attemps... I can't think of any other error
I'm making...Programmer is so easy to make, I can't understand
what I'm doing wrong...
I attach the Hex file I am trying to flash into ATtiny2313
(I use Command -->Write Program(FLASH) ).
I do press 'Write Device' button, but
i get 'Device missing or unknown device(-24)' !
I will remake the circuit from the beginning,
it can be that a wire is faulty and i can't detect it.
However, during 'writing', the waveform at MISOand
MOSI pins on the uP (pin number 18 and 17 respectively
in the uP), as shown on my oscilloscope, are flat (no variation, just
a constant line). However, the SCK pin (number 19) is
active and shows an non-periodic square waveform...
I have a feeling that I may have not numbered properly the
pins of the PC D-SUB serial connector...
That's what i followed:
1 Carrier Detect 1 NC (No Connection)
2 Receive Data 2 --------> MISO
3 Transmit Data 3 --------> MOSI
4 Data Terminal Ready 4 NC
5 Signal Ground 5 --------> GND
6 Data Set Ready 6 \_____ SCK
7 Request to send 7 /
8 Clear to send 8 --------> RESET
9 Ring Indicate 9 NC
Then I'll need to modify the fuse bits: Impossible again because
I cannot write into the ATtiny2313.
I'm going to buy a new chip
today, I have a feeling that the one I have is damaged.
If this does not solve the problem, then I will call a technician
friend in my home to help me deal with this...unbelievable!
I have been into electronics for more than 10years, i never came
across with a problem similar like this before!
electronicus: thanks for the pics.
You actually gave me an idea. At the moment
I am using a long 3m cable to connect the PC
with the base circuit board. When I am measuring
with my oscilloscope the waveforms at the points
of SCK, MISO and MOSI, I can see that they are
'cloudy' and blurred. This might be caused from
excessive noise that enters my wires since the
cable I am using is too long. Hence, the uP cannot
be programmed properly since the signals are
distorted and noisy.
I will modify my circuit and make something the
way you did. I do not know if this helps me to
solve the programming problem I have with ATtiny2313
but I can't think of any other solution.
(on the photo: upper waveform: SCK
bottom waveform: MOSI (oscilloscope cannot 'lock' due to
poor triggering) )
Added after 1 hours 55 minutes:
I just followed my new idea and eventually
PonyProg indicated me a positive asnwer:
Before my circuit was correct, same for the pin
connections between the circuit and the PC socket.
The problem previously was arising from the fact
that the long cable was picking up unwanted excessive
noise (from somewhere...) and communication between
the PC and the circuit was impossible.
I have now shorted the cable length to the shortest possible,
and it worked!
The waveforms on my oscilloscope are now more clear and
nice, indication of noise elimination.
electronicus , thanks for the pics again, they inspired me with
(upper: SCK , bottom: MOSI )
(note also that I DID NOT have to add external clock to the ATtiny2313,
I don't know why but it worked without it - maybe the internal RC
oscillator is functioning)
cplia, windows is not strict real time operation system , so some phase jitter can be there. But as physical communication between PC and micro is synchronous with PC supplied clock , you dont have to worry about .