From: Charles K. <cha...@fr...> - 2012-01-26 09:15:52
|
Hi Frans My aim is to modify the usbpicprog into a portable programmer so that I can download my code into an external eeprom, remove the usbpicprog from the pc, then program my target using the usbpicprog as a stand alone programmer. I have added an eeprom (24LC64) to the usbpicprog board (I did forget the 2 x 10k pull up resistors on the SCL and SDA lines but have added them as a mod on the board), a pushbutton switch and a 5v regulator. As you can see from the schematic I used the pic sda and scl lines for the eeprom and changed the pgd and pgc lines to pins 17 and 18 respectively. I changed the firmware to use rc6 and rc7 and can program external pics with no problem. Unfortunately I can not seem to program an external eeprom (connected to pgd and pgc) or the on board eeprom (using sda and scl). monitoring with a scope I am getting activily on the clock and data lines but I suspect my timing is out. I have tried software and hardware I2C routines with no luck. I was thinking that if the usbpic prog did not detect an external pic, (or one could have an option in the pc programming software) it could dump the program memory, data memory and config bits to the eeprom. when the pushutton is pressed, to read the data from the eprom as though it were coming from the usb port and program the target. Unfortunately I am stuck and not too sure how to proceed. Do you have any advise and could you help with the firmware modifications. Kind Regards Charles Kerr ch...@cr... Cape Town South Africa |