In this tutorial, we are going to show how to load your program into MCU using UIC00B in MPLABX without PICKit2 standalone programmer GUI. 

Note**: This tutorial is continued from the following link and more focused on loading program into MCU using MPLAB X and UIC00B. If you are new to MPLAB X, you may refer to this link as well. Getting Started with MPLAB X IDE

1.0 Getting Started We will be using the sample code of LED_blink for this example. You can download it here

2.0 Loading Program to MCU 

First, build the sample source code you have downloaded or any other codes you like. If you have any problem, you can refer to this link. It gives clear instructions on how to add source files and build a program.

Get UIC00B programmer connected to your computer. Before loading program into MCU, make sure that you choose PICkit2 under hardware tool if you are using UIC00B as programmer.

You can check the setting by following the procedure below: Go to Run►Set Project Configuration►Customize

Fullscreen capture 8202013 14749 PM

OR you can simply click Project Properties button to proceed.Fullscreen capture 8202013 52251 PM

Check whether you are choosing PICkit2 under Hardware Tool. If UIC00B is connnected to your computer correctly, you will see the name of the device right under PICkit2 category. If PICkit2 is not selected, select it and click Apply

Fullscreen capture 8202013 53347 PM


Now we go to categories column on the left side of dialog. Select PICkit2 and double click it. You will enter a dialog shown as below.

Fullscreen capture 8262013 101725 AM

It is advisable to check 3-State on Release from Reset option to ensure the reset button works properly. Even you don’t have reset button or no reset function is needed, check it anyway just in case.

Use target power always is optional and depends on your target system.

  • Uncheck this option will force UIC00B programmer to provide power while loading hex file into MCU on your target system. (You will notice the orange light on UIC00B is always on). How much voltage the programmer gives will depend on the value you set at Set VDD voltage to. You can set the voltage value based on your system. Here we are setting 5V because the system runs at 5V. If your system runs at 3.3V, set 3.3V instead.
  • Check the option let you to use the power from the target system during the programming. If you select this option, ensure that VDD pin from ICSP programmer slot on your system is connected to VDD. Else you will get compilation error because of the lack of target power.

User program executive if available option enables the user to run the program after the program is loaded only if it is available ( power on condition,etc.). Check it anyway.

If you finish, click OK to exit the dialog.

Now we can start to load the program to MCU! What you need to do is one small step. Choose Make and Program Device icon.

Fullscreen capture 8202013 15500 PMNow all you need to do is wait for the programming to complete and you are ready for your program result. Done! Simple as that!

Fullscreen capture 8202013 15823 PM

Therefore now you have learnt how to load your program into flash MCU without using PICkit2 standalone programmer GUI. How about loading hex code from other sources straightaway into MCU using MPLAB X? It can be done as well. First, create a new project. Go to  File►New Project

Fullscreen capture 8202013 55708 PM

Under Categories column choose Microchip Embedded, 5 options should appear in Projects column. Choose Prebuilt (Hex,Loadable Image) Project and click NEXT to proceed.

Fullscreen capture 8202013 55539 PM

Next you need to do is choose the hex file that you want to load into MCU. Make sure you remember the location of targeted hex file. Under Device category, choose the device/MCU you want to load the hex file to. Of course the hex file you want to load also needs to be built based on the device/MCU you selected.  Under hardware tool, choose PICKit2 which is compatible with UIC00A programmer. After that, click NEXT to proceed.

Fullscreen capture 8202013 60021 PM

Now give your project a name and store location. You might have few other projects opened so it is better to check the box “Set as main project” so that the program you load later is this program. Click NEXT to proceed.

Fullscreen capture 8202013 60158 PM

You will enter SUMMARY where you can check your project details. Then you can click Finish

Fullscreen capture 8202013 60319 PM

OK, now you have created a project which the source file will contain only the hex code. What you need to do now is to select Make and Program Device to load the program. Just wait for the programming process to complete and we are done!

If you have any inquiries, welcome to ask at our technical forum. Have a nice try !  🙂


Leave a Comment

Your email address will not be published.

Share this Tutorial

Share on facebook
Share on whatsapp
Share on email
Share on print
Share on twitter
Share on pinterest
Share on facebook
Share on whatsapp
Share on email
Share on print
Share on twitter
Share on pinterest

Latest Tutorial

BLTouch Installation for Ender 3 with 32-bit V4.2.2 Board
Pick and Send Random Meal’s Option and Locations through Telegram Bot Using Grove WiFi 8266 on micro:bit
DIY Automated Vacuum Cleaner Using REKA:BIT With Micro:bit
Rainbow Spark in Mini House using Maker Uno.
TinyML on Arduino using Edge Impulse
Tutorials of Cytron Technologies Scroll to Top