First Time Programming a Microcontroller
In my previous post we have carried out the construction of the base Circuit board for our USB demo Interface Board.So lets begin with out next part for little but more info about the pic18f USB on PCB. (If wish then you can also review my pic18f4550 tutorial for beginner) . So lets get on with usb board now.
Simply connecting the USB cable from your computer to the USB Interface Board immediately after you complete the soldering wonβt make it start working right away.Β Of-course like any new hardware installation you will need drivers for windows in order it to get detected by the system. I will provide the links for the driver in my coming posts. The drivers are coded by Microchip. And in order for the driver to communicate with the board the chip must be programmed first, with some sort of firmware. The codes for the micro-controllers are written with some special IDE softwares which have their own programming language which is similar to C.
JDM programmer is not so famous but it is easy to make and cheap, so beginners can go with it pretty fine . Once a sample demo firmware is loaded into the microcontroller then later you can update the microcontrollerβs firmware with your own CODE directly from the demo board using a boot-loading software.
PIC18F4550 belongs to www.microchip.com, you can find various resources and interesting materials on their website or you can also check my version of tutorial.
Β For further steps you need to download microchips MCHPFSUSB framework, from microchipβs website, it contains various examples, driver and some precompiled demo firmware we need.
Microchip appliction libraries
There are many versions of MCHPFSUSB which were released later , the version I used for my board wasΒ MCHPFSUSB v1.2 , you can download and install it to continue further steps .
you can download it from their website. The links for those download page areΒ It willΒ install some packages Β by default in C:\ drive of your system.
For the 1st time loading you need a base firmware or a demo firmware, The firmware usually comes in .hex format. You can find it. Copy the string and save it as firmware.hex . We will load this firmware.hex into the microcontroller in later steps.
With the help of JDM programmer (a hardware) and a software we will load firmware into the pic18f4550, In coming posts we will also learn how to Make your own JDM programmer and also a step by step tutorial to load the firmware into chip using a software named winpic800.
For more detail: First Time Programming a Microcontroller