Fixing Compile Errors in MPLAB-X Harmony TCP/IP Project

Posted by

I just bought a PIC32 Ethernet Starter Kit on eBay.

I initially tried to follow this guide to setting up a HTTP server:


However, I ran into a few issues when I tried to compile the project:

  1. The TCP/IP library complained about missing “SHA-256”. Easily resolved by adding: MPLAB Harmony Configurator –> MPLAB Harmony & Application Configuration –> Harmony Framework Configuration –> Cryptographic (Crypto) Library –> Hashes –> Use SHA-256


  2. The variables for the LEDs and buttons were missing. Most likely something changed in Harmony and you must check a box to get those now. Who knows. Instead, I noted that all the missing variables were defined as, for instance ‘BSP_LED_1’ rather than ‘APP_LED_1’. So, I just added the following defines to the top of ‘app.h’:

    #define APP_LED_1 BSP_LED_1

    #define APP_LED_2 BSP_LED_2

    #define APP_LED_3 BSP_LED_3

    #define APP_SWITCH_1StateGet BSP_SWITCH_1StateGet

    #define APP_SWITCH_2StateGet BSP_SWITCH_2StateGet

    #define APP_SWITCH_3StateGet BSP_SWITCH_3StateGet

Now the project compiles and runs!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.