Cannot program PIC18F452

Status
Not open for further replies.

yngndrw

New Member
Hi,

I'm new to PIC programming, but not to general programming. (Mainly Visual Basic, C, C++ and PHP) I've been programming the PICs in ASM basically because it's a new thing and I like to learn new stuff.

I have a Velleman K8048 programmer and a PIC16F627 which I started off with, that all went fine and I had that interfaced with an LCD as my first project. I was able to program that fine, through ICSP on a breadboard.

I then bought a PIC18F452. For this I decided to make a bootloader.

After making a program, I tried to program it but the programmer software which comes with the K8048 but this software only supports the PIC16F series.

I then googled (A lot) for a compatiable programmer and the only one I found to do what I wanted was WinPic.

I installed WinPic and set it up to use:
* SMPORT
* Custom interface on COM port
* The pre-made "velleman_k8048.ini" custom interface file
* COM2

When I press Initialize, in the messages box I get:
Failed read back of DATA line (LOW) !
WARNING: Could not initialize programmer !

I also noticed that when I did anything with the K8048 programmer software, the Read/Write light flashed off, on the programmer, but with ANY other software which I've tried, it does not.

The Read/Write light is connected to the VPP line.

There is a circuit diagram for the K8048 here.

Just as a note, I'm using a USB -> Serial adapter. The programmer is a virtual COM port. I'm also running Windows Vista x32 (Business). I have however tried a normal COM port with the same effect.

I have ordered an ICD2 Clone from eBay, but it will take a while to arrive. I really want to continue practicing while I wait for the new programmer to arrive.

Any ideas ?

Thanks,
-Andrew.
 
Last edited:
yngndrw said:
Nobody have any ideas ?

My 2 cents...

Stop futzing with the Velleman and wait for the ICD2 to show up.

Because you have an ICD2 on order the Velleman is not worth the effort.

You can play with the PIC16F627 till it shows.
 
Well I just really want to learn why - I mean we learn from our mistakes and I want to know what I've done wrong.

The Velleman is just the same as a simple Serial programmer so I don't see why it wouldn't.

I am using the PGD and PGC pins as outputs through 10K resistors, could that be why ?

Also the PIC16F627 cannot write to it's Flash so I can't play with my bootloader.

Thanks anyhow.
 

Hi,

"I then bought a PIC18F452. For this I decided to make a bootloader..."

Why are you making a bootloader while there are bootloaders available, like e.g. TinyBootloader? I use it with 18F252. Works great and source is available...

Kind regards,
Jack.
 
Because it's to help me learn about them. That and it's easier to create an x86 program which works with my own protocols.

Also lets me learn about the .hex files that the assembler creates.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…