Hello World Project With PIC Microcontroller – Part II

Summary of Hello World Project With PIC Microcontroller – Part II


This tutorial explains how to burn a HEX file generated in MPLAB to a PIC18F4550 microcontroller using the eXtreme Burner – PIC software. It details connecting the programmer, loading the file, and programming the chip via a ZIF socket. Finally, it lists the necessary components to build a circuit that blinks an LED, including a breadboard, crystal, resistors, capacitors, and wires.

Parts used in Hello World Project With PIC Microcontroller – Part II:

  • eXtreme Burner – PIC
  • PIC18F4550 chip
  • USB Cable
  • 12v DC adaptor
  • Breadboard
  • 20MHz Crystal
  • 330 Ohms resistor
  • 4.7k resistor
  • 2 x 22pF Ceramic Disk Type Capacitor
  • LED
  • Bread boarding wires

Hello Friends, Welcome back. In the last tutorial we started working with MPLab and HI-TECH C Compiler and written our first C program to blink LED. After compiling the program we got the HEX file. Now, in this tutorial we will see how to transfer(burn) the hex file to our Microcontroller chip and then power it up to actually blink the LED.

We will use eXtreme Burner – PIC , which is a easy to use GUI programmer for PIC18 MCUs. The burner supports USB connectivity with PC so it is very easy to install and use.

Launch eXtreme Burner – PIC from Windows Desktop or Start Menu.Hello World Project With PIC Microcontroller – Part II

Fig.: eXtreme Burner – PIC, Main Screen.

The software is easy to use. First you need to load the HEX file which was generated by MPLAB+HI-TECH C in previous tutorial. So select Open from File Menu or From the Toolbar. Then select the hex file. Now the HEX file will be loaded and the contents (FLASH,EEPROM,Chip Settings) will be available.

Now connect the programmer with your PC by using standard USB Cable the programmer will be automatically detected by software (provided drivers are installed previously) . Apply power to programmer using a 12v DC adaptor. Place a PIC18F4550 chip in the ZIF socket and lock it.

Fig.: eXtreme Burner – PIC, USB Programmer for PIC Micros.

After that select PIC18F4550 from Chip Menu and Programming Mode = ZIF Socket from Settings Menu. You are now ready Burn !!!

Select Write All From Toolbar or Write Menu.

The burner will start the Burn Process. It will write each section of memory and verify that they are written correctly.

Fig.: eXtreme Burner – PIC, Burning in Progress.

After few seconds the process ends. The chip is now programmed with the provided HEX file contents. The chips settings have also been modified to suit the hardware environment we will be using. These settings were also embedded in the HEX file (more on this topic in latter tutorial). And it got into the HEX file from the C file. Notice the two linesHello World Project With PIC Microcontroller – Part II schematic

__CONFIG(1,0x0F24);
__CONFIG(2,0X0000);

in the C file of previous tutorial.

The chips is now ready for some amazing lighting effects !

Get the following to see that in action

A Breadboard.
A 20MHz Crystal
1 x 330 Ohms resistor
1 x 4.7k resistor.
2 x 22pF Ceramic Disk Type Capacitor.
A LED
Some Bread boarding wires (free if you buy Breadboard from above link)

Go ahead and connect them like this.

 

 

 

For more detail: Hello World Project With PIC Microcontroller – Part II

Quick Solutions to Questions related to Hello World Project With PIC Microcontroller – Part II:

  • How do you transfer the hex file to the microcontroller?
    You use the eXtreme Burner – PIC software by selecting Write All after loading the hex file and inserting the chip into the ZIF socket.
  • What software is used to program the PIC18 MCUs?
    The article specifies using eXtreme Burner – PIC, which is described as an easy-to-use GUI programmer.
  • Can the programmer be connected via USB?
    Yes, the burner supports USB connectivity with a PC for easy installation and use.
  • What power source is required for the programmer?
    You must apply power to the programmer using a 12v DC adaptor.
  • Which microcontroller chip is used in this project?
    The project uses a PIC18F4550 chip placed in the ZIF socket.
  • What are the configuration settings embedded in the C file?
    The C file contains two lines: __CONFIG(1,0x0F24) and __CONFIG(2,0X0000).
  • What components are needed to see the lighting effects in action?
    You need a breadboard, a 20MHz crystal, a 330 Ohm resistor, a 4.7k resistor, two 22pF ceramic disk capacitors, an LED, and breadboarding wires.
  • Does the burning process verify the written data?
    Yes, the burner writes each section of memory and verifies that they are written correctly.
  • How do you select the correct chip model in the software?
    You select PIC18F4550 from the Chip Menu within the software interface.

About The Author

Ibrar Ayyub

I am an experienced technical writer holding a Master's degree in computer science from BZU Multan, Pakistan University. With a background spanning various industries, particularly in home automation and engineering, I have honed my skills in crafting clear and concise content. Proficient in leveraging infographics and diagrams, I strive to simplify complex concepts for readers. My strength lies in thorough research and presenting information in a structured and logical format.

Follow Us:
LinkedinTwitter