Pages: 1 2 3 [4]   Go Down
Author Topic: [noob-ask] burning bootloader using LPT programmer  (Read 5365 times)
0 Members and 1 Guest are viewing this topic.
eindhoven, nl
Offline Offline
Newbie
*
Karma: 0
Posts: 21
try and try and try and try
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hi all...

finally a little bit of progress, but i still have a problem.

i tried uisp instead of avrdude:

uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --wr_lock=0x3f
uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --wr_fuse_e=0x00
uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --wr_fuse_h=0xdd
uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --wr_fuse_l=0xff
uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --erase --ipload if=[bootloader directory] -v
uisp -dpart=atmega168 -dprog=dapa - dlpt=0x378 --wr_lock=0xCF

It seemed to burn the bootloader, but the LED on pin 13 blinks so fast after i reset.

And i cant upload sketches. when im still uploading the sketch, the led blinks.

what did i do wrong here?  
« Last Edit: June 16, 2008, 07:08:17 am by kodockz » Logged

eindhoven, nl
Offline Offline
Newbie
*
Karma: 0
Posts: 21
try and try and try and try
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

FINALLY!

I can upload my sketch directly thru avrdude!

So, all along it was the printer port setting.

macsimski. thank you for your post. if not because i read his post i wouldnt change the parallel port.

1. I changed the parallel port settings to ECP then adress 0x378
2. i used 'uisp' to check if my parallel programmer is working or not
$ uisp -dprog=dapa -dlpt=0x378
- the number of 0x378 is from the parallel port properties (check uisp website for valid port adresses)
- uisp then will try to find your chip, if it does, it will tell you waht chip u have

3. then i tried using avrdude.
avrdude -c dapa -P lpt1 -p m168
it read the signature and its ok.

4. reading the fuses
uisp -dprog=dapa -dlpt=0x378 -dpart=atmega168 --rd_fuses
or
avrdude -c dapa -P lpt1 -p m168 -U efuse:r:-:h
avrdude -c dapa -P lpt1 -p m168 -U hfuse:r:-:h
avrdude -c dapa -P lpt1 -p m168 -U lfuse:r:-:h

5. open/ ulnlock bit  
uisp -dprog=dapa -dlpt=0x378 -dpart=atmega168 --wr_lock = 0x3f
or
avrdude -c dapa -P lpt1 -p m168 -U lock:w:0x3f:m

6. set fuses
uisp -dprog=dapa -dlpt=0x378 -dpart=atmega168 --wr_fuse_e=0x00 --wr_fuse_h=0xdd --wr_fuse_l=0xff
or
avrdude -c dapa -P lpt1 -p m168 -U efuse:w:0x00:m
avrdude -c dapa -P lpt1 -p m168 -U hfuse:w:0xdd:m
avrdude -c dapa -P lpt1 -p m168 -U lfuse:w:0xff:m

7. upload hex
uisp -dprog=dapa -dlpt=0x378 -dpart=atmega168 -- Upload if=[hex file location] -v
or
avrdude -c dapa -P lpt1 -p m168 -U flash:w:[hex file location]

8. lock bits again.. now 0x0f. in some other source they say 0xcf

pls note that no.3 to no.6 is what i did based on many resources. also im not realy sure that the fuse settings are correct. better check the datasheet.
also i hvent been able to upload the bootloader. im uploading the hex files created form the sketch.

thanks to uchobby's and javier valcarce's tutorial.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello! I ve got 2 questions: (Iam very noob! I ve got arduino 2 days ago.) How could I blink 2 LEDs together? The longer leg of the first LED can be placed in the 12. bank, and the shorter can be (must be) placed in GND. And the longer leg of the second LED can be placed in the 13th bank, and the shorter must be placed in GND. Can it work?  I found the program in: File / Sketchbook / examples / digital / Blink Can somebody send me this program?
How is it possible to make 3 4 5 ... leds work?

Thanks for your help.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello! I ve got 2 questions: (Iam very noob! I ve got arduino 2 days ago.) How could I blink 2 LEDs together? The longer leg of the first LED can be placed in the 12. bank, and the shorter can be (must be) placed in GND. And the longer leg of the second LED can be placed in the 13th bank, and the shorter must be placed in GND. Can it work?  I found the program in: File / Sketchbook / examples / digital / Blink Can somebody send me this program?  
How is it possible to make 3 4 5 ... leds work?  
 
Thanks for your help.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 10
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm glad it worked for someone.

I put a lot of effort into trying to get the parallel port programmer working and now I wish I hadn't bothered. I's simple. It should work. But it never did for me. Reading around trying to find out why it didn't, it gradually became clear that you're at the mercy of your parallel port - some work - some don't and if your's doesn't there aint nothing you can do. Parallel ports have their uses but they're a total pain.

BTW, does anyone know how to make a usb parallel adapter appear as parallel port (instead of as 'usb printing support') under Linux or Windows. Call me a masochist, but I tempted to give it another try.
Logged

0
Offline Offline
Faraday Member
**
Karma: 8
Posts: 2526
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
does anyone know how to make a usb parallel adapter appear as parallel port (instead of as 'usb printing support') under Linux or Windows. Call me a masochist
OK, you're a masochist. (:

Really.  You just think the real parallel port was problem - don't even start with the USB adapter.  Been there, done that.  I don't recall the specifics, but I want to say it was a commercial parallel port programmer of some sort.

Just send about US$20 to LadyAda.  Or $36 to digikey.  Or shoot, send me a blank ATmega with return postage and address label, and I'll burn it for you.

-j

Logged

Pages: 1 2 3 [4]   Go Up
Jump to: