Using ChipKit programmer on DIY board

Talk about anything you want!
Post Reply
george4657
Posts: 21
Joined: Fri Apr 05, 2013 7:05 pm

Using ChipKit programmer on DIY board

Post by george4657 » Mon Jul 24, 2017 9:26 pm

I purchased a chipkit programmer when I purchased my chipkit max32 board a while back.
I have now built my own board using a pic32mx250 for an embedded project.
I was able to write a basic program and program it into the board using the programmer with Mplab X.
All was ok till I unpluged the programmer with external power left on, then the program stopped and pressing reset does not restart it.
I noticed when programming it for the first time it said it was writing a boot loader which I don't understand why.

So my questions are:
Does using the chipkit programmer with Mplab x mean it assumes I am programming a chipkit board and adds boot loader?
If I now have a boot loader on my chip how do I get it to run my program( I don't have usb connected ).

George

EDIT:
Solved problem. Bad connection on jumper wire so MCLR was powered only by programmer.
I think write to bootloader was an update to Chipkit programmer as it had not been used for a long time.

Thanks anyway.
George

User avatar
majenko
Site Admin
Posts: 2181
Joined: Wed Nov 09, 2011 7:51 pm
Location: UK
Contact:

Re: Using ChipKit programmer on DIY board

Post by majenko » Tue Jul 25, 2017 10:09 am

"writing to bootloader" doesn't mean it's actually writing a bootloader to the chip, just that it's writing to that portion of the flash memory.

The chip's flash is split into two parts - the main program flash, and the (3K) bootloader flash. The chip always boots from the bootloader flash, so something has to be there to execute. If you don't have an actual bootloader the linker places some of your program's startup code (crt0) in the bootloader area. That then executes on power up and then jumps to your code in main flash.
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".

GastonLagaffe
Posts: 102
Joined: Sun Oct 26, 2014 2:50 pm

Re: Using ChipKit programmer on DIY board

Post by GastonLagaffe » Tue Jul 25, 2017 10:11 am

Salut George,

I use PicKit3 to flash the CPU. Every time I connect the programmer it downloads the latest bootloader and firmware for the PicKit3. This also happens when I change the CPU type (e.g. from 44 pins to 28).

Ciao, Mathias

Post Reply