avrdude-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[avrdude-dev] AVRdude.conf and the AT89S52


From: Tim Ward
Subject: [avrdude-dev] AVRdude.conf and the AT89S52
Date: Tue, 3 May 2011 18:37:59 -0700 (PDT)

I see Tobias Kaiser submitted a patch to allow the AT89S51/52 to be programmed.
I've successfully programmed an AT89S52 without that patch using the AT89ISP 
(parallel port) programmer, by inverting the reset pin in the AT89ISP 
definition in the avrdude.conf file.
I'm trying to do a workaround for setting the lock bits.  What I've done so far 
is to define 4 more single byte memory spaces for the 89S52: fuse1, fuse2, 
fuse3, and lock.  Each of the fuse write commands is fixed, and that memory 
space's read command returns only the bit that should have been programmed.
Since the bits are offset in the byte returned by the processor, I set and 
verify them by -Ufuse1:w:4:m -Ufuse2:w:8:m -Ufuse3:w:0x10:m
The purpose of the lock memory is to read and verify all the bits at once, as 
-Ulock:v:0x1C:m

If I send these commands one at a time, they set and verify fine.  If I send 
them all on the same invocation of avrdude, they don't.
This makes me think I've got a timing problem, but I'm not clear on what 
parameters in the part definition I should be changing to spread the commands 
out a little more.  There's only three items total to write, so even a pretty 
long delay would be fine with me.
A max_write_delay of 90000 in the memory definitions didn't seem to make a 
difference.
 
I've read the man page and the documentation regarding the avrdude.conf, and 
looked at the source a bit.
Where should I be looking to find the appropriate parameters and their meanings?
Or if someone can tell me a better way to do it, that would be good, too. 

Tim Ward




reply via email to

[Prev in Thread] Current Thread [Next in Thread]