Welcome! Log In Create A New Profile

Advanced

JDM, SDCC, Pikdev, first flash, 16F628A ... successful

Posted by Joost 
JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 20, 2007 06:34PM
Hi all,

Today I embarked on the complete unknown - PIC programming. I was rather surprised to actually find out it was a successful venture ;-) The following is a short overview of the things that were done, configuration etc. Since I really am not sure *what* it is I'm doing, no guarantee it will work for someone else...

The system I have done this all on is a (homebuilt) pc with a "normal" serial port running Ubuntu 6.10 (Edgy Eft) with all the updates. The PIC is a 16F828A.

I started by making the JDM programmer as described on the wiki [www.reprap.org]. Then I downloaded Pikdev, a PIC programmer which can be found here [pikdev.free.fr.] There is a feature in there that allows for testing the voltages on the serial connection, which I did using a multimeter, but they were slightly different (i.e. lower, 9 instead of 13V for example). I figured it shouldn't be a major problem (still unable to grasp what is correct) and continued with the next step, getting and compiling SDCC. I updated my SVN repository (the stuff that is on Sourceforge in the RepRap project) and tried to run make.

It gave a few errors during several compilation runs: missing the CVS executables (so it would not download from the SDCC repository), something named flex and something named yacc. All were installed (using apt-get install cvs, apt-get install flex and apt-get install byacc). Also, I modified the make script to download the latest version (or at least that's what I think I did... I removed the "-D 20051210" parameter on line 50 in Makefile) When running Make it gave the same error Zach has had (read about it here [forums.reprap.org]) and modified the same line as he has. Apparently, this has something to do with old style C++ code, see [lists.opensuse.org]) After a while all seemed done and - no errors! I also had some brand new .hex files in the reprap_svn/reprap/firmware/build/16f628 folder

Next step was hooking up the JDM programmer and running PikDev. I configured it to use the serial port, JDM Classic and the 16F628a(p) - as it is named in the list in PikDev. Final step was to write the program (in menu Tools->Program, then PIC operations->Program PIC). To my surprise, it actually did something and there was no smoke or explosions. Finally, since I could not believe this actually worked, I detached and re-attached the serial JDM cable and did a PIC operations-> Read PIC. The same stuff that was put in actually came out...

Next step will be verification using the universal board, comms board and a stepper motor to see if it also works in the real physical world

Joost
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 20, 2007 07:46PM
fantastic! this is a tricky step, but apparently you navigated it just fine. yay!
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 21, 2007 06:06PM
I built a JDM programmer today and tried using ic-prog however i keep getting popup boxes saying "privileged instruction" when i try to do the hardware check. I tried pikdev too but my serial port does not seem to work in linux (i think its a lack of driver problem). Has anyone else had this problem or does anyone else know another program that will work with the JDM programmer?

Thanks.
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 21, 2007 10:34PM
Thats a known issue.. let me look that up again..
Aha.. Yes umm...

To quote the page

"We suggest "IC-Prog", as it is well-supported and free for personal use. You can obtain the latest version of IC-Prog from www.ic-prog.com. In all, you'll need to download three files: the application (icprog105a.zip), the driver for Windows NT/2000/XP (icprog_driver.zip) and the help file (icprog.chm)."

And the page I found with this reference is..

[www.siliconchip.com.au]

Hey Zach, would you please add this somewhere with the windows stuff?
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 22, 2007 10:25AM
most definitely.

i used icprog to do my programming, and i can attest to it being a great piece of software.
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 22, 2007 12:06PM
ICProg was always rock solid. It was the JDM board that was usually causing the problems.
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 22, 2007 08:47PM
I should have made more of an effort:
Files here
[www.ic-prog.com]
[www.ic-prog.com]
[www.ic-prog.com]
Unzip them all to the same place and then run the executable.
set the programmer settings according to the programmer you have.
Link to settings links here
[www.ic-prog.com]
That should do it.
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 23, 2007 09:28AM
I've downloaded the 2000/xp driver and the zip contains the file 'icprog.sys' I've tried running ic-prog with this file in the same directory as the program and got the same errors. Is there some kind of system directory i should be copying icprog.sys to?

Thanks
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 23, 2007 10:04PM
Oh yeah, I didn't see this last night even after looking, so I looked harder. You have to select option to use the driver. Settings->Options then select Misc tab and check the Checkbox Enable NT/2000/XP Driver.

Dear Zach, can you get this into the instructions too?
Attachments:
open | download - ic-prog_setup.bmp (605 KB)
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 24, 2007 03:48PM
Thanks it's now working perfectly and i've tested it using a pic and it programs fine.
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
May 24, 2007 06:00PM
I've written up bartlee45's info on how to obtain and set up IC-Prog on the Wiki
in a new page ICProgHints, see [www.reprap.org]

Jonathan
I am working with PIC16F877/PIC16F877A
I got problem while downloading programm to IC through IC-PROG 1.06A
which is giving verify address failed at 000h
Thank you
Use the windows api option in the serial configuration.. it worked for me.. the new windows does not allow direct access of hardware... and thus the error
Re: JDM, SDCC, Pikdev, first flash, 16F628A ... successful
September 19, 2011 10:37AM
Holy thread resurrection batman! winking smiley
Sorry, only registered users may post in this forum.

Click here to login