Microchip Bootloader

Bootloader for Microchip PIC Processors

PIC BootloaderA bootloader is a small piece of software loaded onto the microchip that allows you to download programs to the chip via a simple serial connection. They have become very popular on the Arduino chips as it negates the need for an expensive programmer.

But there is also a freely available bootloader for the Microchip family of processors. As well as the bootloader code, it comes with a Windows graphical front end for the downloading of your programs to the microchip.

If you want to code using Microchips MPLAB front end using any of the freely downloadable compilers (MPASM, C18, HI-TECH C, Basic etc) then you can without the cost of buying an expensive programmer.

ds30Loader

ds30Loader is the bootloader software and can be downloaded from the authors website at

mrmackey.no-ip.org/elektronik/ds30loader/

The bootloader code takes up only about 300 bytes of programming space and is stored at the end of the programming space on the processor. For most processors no change to the actual program code needs to be done apart from removing the CONFIG settings as these are already in the bootloader code . Below is a screenshot of the Windows GUI for dsLoader software.

ds30 loader main screen

The picture below shows a Microchip 18F14K22 chip on a breadboard along with a Sparkfun FT232RL USB to Serial breakout board. The chip simply needs power (provided here by the USB connection), 0V, a pullup resistor on the MCLR line, and the TX and RX connections wired to RX and TX on the USB to Serial board. The bootloader runs at power up or when the MCLR pin is taken low. If communication with the ds30Loader program is not made within 3 seconds, then the bootloader runs the program that has been downloaded onto the chip. All very similar to the Arduino bootloader.

Microchip PIC 18F14K22 on breadboard

To download a program

In the ds30Loader main screen

  • Select the compiled hex file
  • Select the Device
  • Select the baud rate that the bootloader is set to (normally 115200)
  • Select the Port for your serial connection
  • Reset the microchip by either taking the MCLR pin low or removing and re-applying power
  • Click the Download button within 3 seconds

Similar to the following will be displayed in the text window

Initiating download...

Searching for bl .
Found PIC18F14K22 fw ver. 2.0.3
Waiting for bootloader to be ready ...ok
Writing flash ...ok
Download finished
Tx 7.1kB / Rx 389 bytes / 7s

Auto Resetting

You can setup the PIC processor to be automatically reset when you want to download a new program (which saves having to manually take the MCLR pin low or by removing and re-applying power) by adding a 0.1uF capacitor between the MCLR pin and the DTR pin from the USB to Serial board. This gives the MCLR pin a low pulse (and hence resets the chips) when communication is started.

Shopping Cart
0 items
 
DELIVERY/PAYMENT

Free Delivery Orders over £50

UK - £2.40 orders under £50
Airmail from £2.95 (+VAT)
More Details...

 
Brands
 
 Check out our videos
Follow us on:
acebook