How to Program PIC MCU With PICkit Programmer Using a Breadboard

Introduction: How to Program PIC MCU With PICkit Programmer Using a Breadboard

About: Electronics.

You do not need expensive and sophisticated tools to play with PIC (or any other) microcontrollers. All you need is a breadboard where you test your circuit and programming. Of course some kind of a programmer and IDE is necessary. In this instructable I will use MPLAB X IDE and PICkit3 programmer.

I have chosen PIC18F14K22. There is no special reason for this particular PIC, I just have it unused at the moment. It works in the voltage range between 2.3 V and 5.5 V. The programming process will be shown with the simple code that lets the LED periodically blink.

Step 1: What We Need

  • PICkit3 programmer
  • breadboard
  • PIC18F14K22 MCU
  • 6-pin header
  • some cables
  • either 4.5 V battery or USB cable (you can use some from old mouse or keyboard or make one yourself)
  • any color LED and 470 resistor for testing purposes



PICkit 3

Step 2: Wiring


Let's take a look at the PICkit3 programmer. Notice the 6-pin female header on the bottom side. The pin number one is signed with a white triangle so from the front side pins are numbered from right to left. Pins' description:

  1. MCLR
  2. Vdd
  3. Ground
  4. ICSP Data
  5. ICSP Clock
  6. Not connected


First place 6-pin header and PIC close enough to each other on the breadboard. In the PIC datasheet we have to find out functions mapping:

  1. Vdd - pin 1
  2. Vss (ground) - pin 20
  3. PGD (ICSP Data) - pin 19
  4. PGC (ICSP Clock) - pin 18
  5. MCLR - pin 4
  6. RC0 - pin 16 (the pin by which the LED will be driven)

The circuit scheme is shown in the Fritzing picture.


As it was mentioned earlier the circuit can be powered either from the 4.5 V battery or the USB outlet (5 V). To make it clear 5 V is ok for this particular PIC but does not have to be for others. Always check the datasheet for the voltage range applicable to the device.

Step 3: Programming

I prepared pretty simple code for testing purposes. When you have the MPLAB project ready for programming attach the PICkit3 to the pin header on the breadboard. Do not forget to have the circuit powered otherwise the connection between the PIC and the programmer fails. Click the "Make and Program Device Main Project" button and wait until the programming is finished. After that the LED should blink - 500 ms on and 500 ms off.

Be the First to Share


    • Lamps and Lighting Contest

      Lamps and Lighting Contest
    • Soup & Stew Speed Challenge

      Soup & Stew Speed Challenge
    • Halloween Contest

      Halloween Contest