My laptop does not have serial port. And ponyprog, up until now, have not provided support for any USB programmers. Today, I constructed my first USB programmer on a breadboard. I had a old USB extenstion cable which was out of order as the header was slack due to wear. I cut of that part and soldered breadboard wires.
My first goal was to make a ponyprog compatible programmer that emulates parallel port. I started with: USB2LPT
Afterwards, I realized that the emulation makes programming too slow. Thus I had to move to a dedicated programmer. But I really like a GUI for inputting, especially the fusebits. AVRdude is a command prompt based programmer. A wrong fusebit setting can lock the microcontroller irrepairable by a Serial Programmer.
Then I found AVR8 Burn-O-Mat: GUI for avrdude . The interface is even better than pony prog for fuses. It actually has small comments beside fusebits. AVRdude even supports my simplified SIProg. So I proceeded to make the famous USB ASP (http://www.fischl.de/usbasp/) I forgot to connect the ICP and INT0 at first, and kept getting “Unknown USB device”. I reflashed 4 times. Finally the programmer was operational and the driver was installed successfully.
I’ll give details of my schematics later. Here is a picture of the circuit.
Update: My Programmer is working now. Read Here.
Bookmark
Related Posts
- USBASP Programmer for AVR is working on Windows Vista
- External Crystals and Ponyprog
- (Really) Beginners Microcontroller Guide (Part-II) Configuring Ponyprog properly and writing program to uC
- Beginner’s Microcontroller Programming: Simplification of the LancOs’s SI Prog
- Beginner’s Microcontroller Programming-III: (Further) Simplification of the LancOs’s SI Prog the Serial Port Porgrammer
![[Bloglines]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/bloglines.png)
![[del.icio.us]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/delicious.png)
![[Digg]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/digg.png)
![[Facebook]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/facebook.png)
![[Google]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/google.png)
![[Twitter]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/twitter.png)
![[Yahoo!]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/yahoo.png)
![[Email]](http://www.sajidmc.net/wp-content/plugins/bookmarkify/email.png)
#1 by Sajid Muhaimin Choudhury - November 11th, 2008, 27 Kartrik 1415, 15:13
From my email:
Hello,
and I have some question about the USB programmer. You have used the schematics from (http://www.fischl.de/usbasp/) and what OS you used for programming ?
I visited your blog, nice works
I`m waiting for your reply,
Regards,
Deian COSAS,
Hi,
Thanks for emailing. I used both Win Vista and Win XP to test the programmer in 2 separate computers. The programmer was detected as a USB device successfully, although Vista warned that the driver was not signed. But unfortunately, when I tried to program a microcontroller using AVR dude, it gave verification error. I’ll make another version of it in a veroboard and try it again in a couple of days.
Regards,
Sajid
Hello,
First of all, I want to thank you for the fast answer, i`m really sorry that it didn`t worked for you, my hopes went down now, but I still think I`ll give it a chance and put the circuit togheter to see what is going on, I have a laptop with USB-ports only and I really need this programmer.
You said that it didn`t worked, but what do you think it is going wrong? I don`t understand what “verification error” means, it means maybe that avr-dude can`t see the Atmega8 as a programmer? or what?.
And last… what simulation application for microcontrolers are you using?
Thank you for your attention, and have a good day,
Regards
Deian COSAS,
I was also trying to build the USB programmer for my laptop.
Actually according to the AVRdude support page, verification error means that the clock signal from SCK pin was too high for the microcontroller to cope up. I didn’t have enough microcontroller at my hand to test the USB programmer with. So I am not sure whether the only microcontroller I had was malfunctioning, or was it the problem of the programmer. I used the slow clock jumper, but still it did not help. Now current stable version of AVRdude and USBASP does not support variable software control for SCK signal. They have released a patch for the AVRdude and USBasp for that:
http://www.mail-archive.com/avrdude-dev@nongnu.org/msg01500.html
I couldn’t actually understand how to patch it.
I think there is another programmer called USBtiny that is based on ATtiny2313. It supports software control of the clock speed. The comments in the source code was german, so I did not understand them to modify it.
http://www.xs4all.nl/~dicks/avr/usbtiny/
If you have any luck with patching it let me know. I’m kinda busy to go shopping for microcontroller, and when I get microcontrollers, I’ll let you know.
Sajid
#2 by sanaz - December 2nd, 2008, 18 Agrohayon 1415, 17:52
hello
I’m a student of electronic from Iran . I want to make an usb programer project , but I have no idea. Please help me to do this .
Regards,
sanaz
#3 by Sajid Muhaimin Choudhury - December 2nd, 2008, 18 Agrohayon 1415, 17:59
Thanks for leaving a reply. Are you familiar with Microcontrollers and basic circuit diagrams? Then you should be able to make the USBasp programmer yourself. You first need an SIProg (or other parallel port or serial port programmer) to load the firmware into ATmega8. Afterwards, construct the circuit and use it.
#4 by foker - January 9th, 2009, 26 Poush 1415, 11:30
hello…
im a student of electronic engineerng from indonesia.
i’ve a problem with my usb-asp programmer. i knew about usb-asp from http://www.fischl.de/usbasp/.
first i’m flash the atmega8 from paralel port, and its just fine.
but when i connect my usb-asp to my computer, windows detected as unrecognized device. not like in “readme.txt” the device known as USBASP.
and when i try to installing usb-asp from “bin\win-driver” it always failed.
can u help me whats the probelm!
is it on my schematic?
i’m waiting 4 ur reply
Thx
#5 by Sajid Muhaimin Choudhury - January 9th, 2009, 26 Poush 1415, 12:05
What can I say. Have you checked fusebits? Have you checked correct connection of the D+ and D- pins? Did you connect pull ups to D- pin?
#6 by foker - January 16th, 2009, 3 Magh 1415, 12:30
hehehe….
im not fuse the bit…
thanks…
#7 by TAHIR - January 23rd, 2009, 10 Magh 1415, 14:11
hi sajid
this is out of topic but i think you can guide me.i am trying to build a digital cap meter build around atiny2313 i have pony prog and i build serial por progammer but i cant reach the firmware.it is on other link and they want some kind of registration can you help me.thanks
tahir
#8 by Sajid Muhaimin Choudhury - January 23rd, 2009, 10 Magh 1415, 15:36
Tahir, I can’t understand. Ponyprog is freeware and opensource. Why would they want registration?
#9 by doublek - June 24th, 2009, 10 Ashar 1416, 13:14
With regard to one of ur previous posts u had said “What can I say. Have you checked fusebits? ” Could u pls elaborate on this. I just downloaded the firmware for atmega8 using ponyprog, should i do anything to the fuse bits???
#10 by Sajid Muhaimin Choudhury - June 25th, 2009, 11 Ashar 1416, 04:05
Yes, you should change the value of the fusebits of your microcontroller using pony prog to have external crystal enabled. Check the makefile of it to have the hfuse and lfuse values. Then go to http://www.engbedded.com/fusecalc/ and use those values to see the fusebits that need to be changed in ponyprog, (Security and configuration bits in menu). I don’t use ponyprog any more, and don’t have it installed any more.
#11 by doublek - July 15th, 2009, 31 Ashar 1416, 12:20
I’m not using an external crystal for the atmega8 in the usb programmer circuit. So i don’t need to change the fuse bits, do i ?? Also if i choose not to use the external crystal, then can i still use the same firmware code given in the http://www.fischl.de/usbasp/
-Thanks
#12 by Sajid Muhaimin Choudhury - July 15th, 2009, 31 Ashar 1416, 12:26
doublek: For the USB programmer, the bus timing is critical, therefore, it is crucial to have precisely 12 MHz clock frequency. For precise timings, you have to use 12KHz crystal. Without fuse settings change your microcontroller will run with internal RC oscillator at 1MHz, and the frequency will not be constant. So I don’t think you will be at all able to make a USB circuit without the crystal.
#13 by saurav samantray - November 9th, 2009, 25 Kartrik 1416, 12:50
sajid bhai i want the schematic for parallel programmer for avr8 burn-o-mat.actually i burned HFUSE=0xc9 and LFUSE=0xef for usbasp into my atmega8(using ponyprog) and now i cant write anything into my uC.So i want to try avr8 burn-o-mat.
#14 by Sajid Muhaimin Choudhury - December 22nd, 2009, 8 Poush 1416, 22:49
What programmer did you use with ponyprog. If the uC is locked with ponyprog it is very unlikely that it would respond the burn o mat, because possibly, the SPIEN fuse has been disabled by error.
#15 by salaken - February 20th, 2010, 8 Falgun 1416, 23:07
does USBasp work with ATmega32?if it works, is there any changes in circuit? and if I program uC with 12 KHz crystal, do I need to use this freq. all the time I use the uC?
#16 by kalmah - May 7th, 2010, 24 Boishakh 1417, 14:36
i want to ask the same question, how do i port usbasp into my ATmega32 (cause i have two of them but don’t have ATmega8)???
#17 by Fahad - July 2nd, 2010, 18 Ashar 1417, 02:50
I also want to ask same Q. Instead I have ATtiny26 and ATmega16. I go to patuatuli, but they said ATmega8 is out of market.
Sajid vai,this site is great!
#18 by Sajid Muhaimin Choudhury - July 2nd, 2010, 18 Ashar 1417, 06:12
Thank you very much. You have to recompile the source code before you can use some other microcontroller. Cheers….
#19 by shaad mahmud - August 12th, 2010, 28 Srabon 1417, 00:45
after working 3hour i have made this thak u sajid vai….here is my work “http://must-info.blogspot.com/2009/10/hallo.html”