Skip to content

Building and flash firmware

Dilshan R Jayakody edited this page Oct 26, 2019 · 7 revisions

Compiling firmware

Compiling firmware is an optional step. This step is necessary only if the provided source code is modified or updated. If you plan to use a compiled binary file which is available in the release section of this project site, then this "compilation" step is not needed to perform.

The firmware of this USB hub is developed using Microchip MPLAB X IDE and MPLAB XC8 compiler. The compilation process of this firmware is straightforward, and it does not need any additional libraries or configurations. This compiler and IDE are available to download at Microchip MPLAB homepage.

Flashing firmware

Following components are necessary to flash the compiled firmware into MCU:

To flash firmware connect PICKit3 programmer into PCB as illustrated below:

ICSP connection

At the programming stage, it is necessary to feed supply voltage to the PCB using an external +5V power supply. The most suggested power source is USB +5V output from PC or through mobile phone charging adapter.

Before establishing PICKit3 connectivity, make sure to change the J7(PMODE) jumper to position 2-3.

PMODE and ICSP jumpers

After the above steps system is now ready to transfer the firmware. Microchip IPE appears with an uncomplicated UI, and the programming process is straightforward. Refer to the IPE documentation for more details.

After downloading firmware, disconnect PICKit3 from PCB and restore the J7 jumper to position 1-2.