Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Using Atmega8 based USBASP to program PIC18F uC

Status
Not open for further replies.

savvej

Member
I have USBASP AVR Programmer but dont have any PIC programmer.
I searched net for some usb based PIC programmers but they seem to be costlier as compared to USBASP.Basically they use PIC micro which has inbuilt USB hardware to communicate and program which makes them costly.
Now as I came to know,USBASP emulates USB in firmware inside its atmega 8 and then uses SPI to program supported AVR uC.
Is'nt same possible with PIC uC?
As in can't we make similar programmer using similar PIC uC like PIC16F628?
Or is there some way by modifying the code for usbasp(which is open source) for PIC uC and use atmega 8 uC to program PIC uC (LOL :p atmel programming PIC) as I have 2-3 atmega 8 spare with me?



:- I actually have only PIC16F628 with me :p as far as PIC uC's are concerned and it was lying in my electronics box since a long time as I had no programmer for it.I searched for simple programmers and got JDM based serial PIC programmer but since my laptop has no serial port and since USB-Serial Adapters don't work with JDM based programmers,I am in a great fix for finding a programmer.Also I am low on pocket money to buy a new PIC programmer..I have many passive components in my box..so I wish to use them to make a simple and a elegant usb based programmmer :p
 
ok..so after 2 days of searching net for PIC programmers this is what I want to build:
Microchip's PICKIT2 ICSP Programmer (with schematics and source codes given on their website) and their clones available all around internet..It offers so many good debugging features too..But as I said before most programmers are using pic18f2550 or pic18f4550 having inbuilt usb hardware as is this one too.
Now I dont have pic 18f2550 .
And I found these notes from atmel:
1)Software USB implemtation application note(and source code on avr309 application source code).:I breifed through it and it says that it implements USB 1.1 low speed(1.5Mbps) on atmega8/attiny2313 using 12Mhz crystal.It explains usb protocol quite well in breif and provides template kind of library implementing for example usb-rs232 convertor.
2)AN258a from Microchip which tells on how ICSP is performed-basically for 8/14 pin uC's (havent read it completely just an overlook) says using pic16c754 which has inbuilt usb ,using the same for communication and using PID in firmware to produce appropriate working voltages for programming.
3)AN589 from Microchip gives some idea on how ICSP is performed(though it is actually a parallel port programmer note)

ANYONE online wanting to throw some light on this topic and wanting to build this kind of programmer(as i could'nt find one on net as of yet and anyways I havent worked with usb before so it would be a good learning experience)?If yes let's do it.
 
Last edited:
After pondering as to why JDM based programmers dont work with usb-serial adapters-searching on the net I found that it was due to delay problems.
One solution the author has presented is to use a microcontroller to interpret instructions from usb-serial convertor and use the uC to program to resolve the latency problem.
A programmer supposedly to follow the same technique was discovered by me on the following site:
https://www.kitsrus.com/pic.html
Their kits k150,k128 etc use ftdi's chip ft232 for usb-serial and then PIC uC to interpret them and latter on powerbooster circuit meant for programming..
I have a usb-serial convertor.... and can make this programmer ..if i get the sorce code of the hex file dumped in the pic of programmer..
Anyone who has made a similar programmer plz let me know..

p.s. plz see k150v2.pdf on the link given and plz give your feedback on the same..
 
Last edited:
Anyone interested in making k150 kind of clone by kitrsus using atmega8 and want to join me,can contact me on shabbarvejlani[at]gmail[dot]com
We can plan out things and do group study..As of today I read some basics of PIC programming by reading the 16f628 Programming specs by Microchip and how data is stored in hex file.Anyone having experience in making pc interface applications using visual c++/visual basic is invited.Remaining communications will be done by mail/gtalk and if the moderator allows updates of progress will be put on this thread.
 
Hi savvej, for the price of UPP628 at euro 35 (without shipping - around euro 10, I believe-) I think that is best buy it mounted and tested that build one yourself.
I have experience with this programmer and it's very well.
Thanks.
Regards.
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top