This first tutorial is the usual flashy LEDs example.
We will be introducing the development board we use (its the QL200 PIC development board), we will be using the CCS C Compiler and we use the QL Programmer software that comes with the development board to program the PIC.
First of all , the development board. I chose this board as it had many features that I thought were suitable for myself as a beginner, it has a variety of LEDs, 4×4 key matrix, Seven segment display on board, a remote control IC, buzzer and many more features. You can hook up an LCD to a connector, there are areas for various 3rd party ICs such as EEPROMs, RTC chip, D/A convertor and so on.
The kicker for me was that this development board supports many PIC chips, mine has a PIC16F877A on it. Here is a picture of the board
The example as stated was written using the http://www.ccsinfo.com/downloads.php compiler.
//Include the header for 16F877A.
//We use an xtal crystal, no watchdog,
//no low-voltage protection and no code protection.
#fuses XT, NOWDT, NOLVP, NOPROTECT
//The crystal is at 4,000,000 Hz.
#use delay (clock=4M)
//This is the starting point of the program.
//Send a hexadecimal byte to port A
//Send a hexadecimal byte to port B
//Send a hexadecimal byte to port C
Compile this and you will get a hex file created. I needed to use the programmer that came on the CD with the board. You can see this in the image below.
Fairly simple operation, connect your board to your PC using the USB cable supplied, select the programmer using Options -> Select Programmer. Make sure the Chip Select is set to the correct chip. Click on Load, locate your hex file from earlier, then click on prog to program your PIC. Now you should see the LEDs flashing on and off.