# PIC32MZ, MPLAB X IDE, FreeRTOS, Harmony, File Structure and Setup

**URL:** <https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560>\
**Category:** Microchip\
**Created:** [April 17, 2020, 10:08pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560 "2020-04-17T22:08:34Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![marsmen](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@marsmen](https://forums.freertos.org/u/marsmen)\
**Post date:** [April 17, 2020, 10:08pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/1 "2020-04-17T22:08:34Z")

</div>

Hello Forum Peeps.

I am “trying” to get setup and not able to find clear answers. I’ve got some basics, and some advanced, but seem to be stuck in the early middle of the process.

I’ve a PIC32MZ…EFG100 on Digilent WiFIRE board. I’ve a chipKIT to interface with it for using the MPLAB X IDE to program.

I’ve installed MPLAB X IDE (v5.35) with XC32 (v2.4) and Harmony 3. I can create a project, but it seems to be missing “stuff”. It did see and reference the chipKIT and I did get the peripherals(.a) library add. It doesn’t have any header files in it, no bsp.

separately…

I’ve downloaded and modified the FreeRTOS per instructions. It has header files and some other things, but then the IDE doesn’t load the libraries, no bsp. And now doesn’t see my chipKIT even though it is plugged in.

It seems to not have the mainCREATE\_SIMPLE\_BLINKY\_DEMO\_ONLY in it.

I’ve a full workable project.x example for a PIC32MZ Curiosity board with bsp files (it works on Curiosity boards, this is for a class). I’m setting up for a parallel project.

The project.x is from Microchip that I got through the instructor, but it appears to have multiple FreeRTOS files in duplicate and the heap\_x has too many files…and it isn’t for my G100 PIC32MZ.

I’d really like, it would be great to have:

- Step-by-step instructions (without fluff of details) how to take a FreeRTOS demo project and make sure it is setup for my uC.

- Setup the IDE to open the project.

- Some screenshots of of the project’s file structure would be super helpful.

- Know what I can add to a project folder and what I cannot (like I don’t see the header folder in Finder (I’m on a Mac) but it is in the IDE.

Side note, I’ve read through the FreeRTOS pdf (plus website and looked though this forum) and the Microchip IDE User Manual (plus website and forums). The YouTube videos I’ve seen just seem to advertise capabilities. Digilent doesn’t have the support capabilities.

Thanks.

---

<div class="post-metadata">

**Author:** ![rtel](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/rtel/32/31_2.png) [@rtel](https://forums.freertos.org/u/rtel)\
**Post date:** [April 17, 2020, 10:43pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/2 "2020-04-17T22:43:55Z")

</div>

I’m finding it hard to understand what you have got from where and what it is you are trying to do.

> [@marsmen](#):
>
> I’ve downloaded and modified the FreeRTOS per instructions.

Which instructions did you use? If it is from the FreeRTOS distribution, from us, then it is a kernel only demo that shows you how to build the demo and how to use the APIs (it also tests the FreeRTOS PIC32 port). It won’t have any particular drivers beyond that though.

> [@marsmen](#):
>
> Step-by-step instructions (without fluff of details) how to take a FreeRTOS demo project and make sure it is setup for my uC.

I believe MPLAB and Harmony (from Microchip, not from us) will create a FreeRTOS project for you, in which case you won’t need anything from our (separate) FreeRTOS examples. In which case the documentation you will need is Microchip’s Harmony, and presumably that will configure things for you.

> [@marsmen](#):
>
> Setup the IDE to open the project.

We don’t provide IDEs, so again you will need to look at the documentation from the IDE’s vendor. Our documentation only shows how to open a pre-configured example that we may provide ourselves, but as already mentioned, that is a kernel only demo that won’t provide you the peripheral libraries you are looking for.

> [@marsmen](#):
>
> Side note, I’ve read through the FreeRTOS pdf (plus website and looked though this forum) and the Microchip IDE User Manual (plus website and forums). The YouTube videos I’ve seen just seem to advertise capabilities. Diligent doesn’t have the support capabilities.

Well these are the places I would recommend reading - just don’t get confused into thinking Microchip and our documentation are showing you how to do the same thing. Our demos are for the kernel only, and documentation show you how to open and run just that demo, plus provide information on using FreeRTOS on the PIC32. Microchip’s demos and documentation are centered around using their own libraries and tools to create a FreeRTOS project for you in a wider context (not just the kernel), and will hopefully therefore also bring in and configure FreeRTOS for you.

---

<div class="post-metadata">

**Author:** ![marsmen](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@marsmen](https://forums.freertos.org/u/marsmen)\
**Post date:** [April 17, 2020, 11:49pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/3 "2020-04-17T23:49:02Z")

</div>

Thanks for the response.

I understand limitations of ownership. I saw others post here with FreeRTOS/MPLAB/PIC32 questions and got support. I was hoping for the same.

I used the instructions from here:

> **[FreeRTOS - the small footprint professional grade free RTOS ports and demo...](https://www.freertos.org/a00090.html#MICROCHIP)**
>
> A list of FreeRTOS demo applications and FreeRTOS port to lots of different microcontrollers. FreeRTOS is a small footprint RTOS for microcontrollers, professional grade and free.

  

> **[FreeRTOS - Free RTOS Source Code Directory Structure](https://www.freertos.org/a00017.html#MICROCHIP)**
>
> Details all the FreeRTOS ports and describes the FreeRTOS directory structure

  
and… /PIC32MZ\_RTOS\_MIPS\_M14K…  
and… /porting-a-freertos-demo-to-different-hardware…  
and… /wp-content/uploads/2018/07/161204\_Mastering\_the\_FreeRTOS\_Real\_Time\_Kernel-A\_Hands-On\_Tutorial\_Guide…

At present, I have:  
A project.x that works for Curiosity boards, but is over stuffed with 2(?) kernels and has to heap\_# files. And no Curiosity board.

A project.x with no RTOS that looks partially complete for the WiFIRE board.

A RTOSDemo.x that appears to not let me correct it for the G100 (it is stuck on H144).

A FreeRTOS folder that I spliced together from the instructions aforementioned that looks to be the base. But seems to be missing a lot.

 ![Snip20200417_1](https://d2v6vdsk2p900z.cloudfront.net/original/1X/9c75b3b395709c2deca6f167565ca4977b7feda3.png)

---

<div class="post-metadata">

**Author:** ![cobusve](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/cobusve/32/1447_2.png) [@cobusve](https://forums.freertos.org/u/cobusve)\
**Post date:** [April 18, 2020, 12:57am UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/4 "2020-04-18T00:57:29Z")

</div>

Have you seen this ?

[[https://docs.aws.amazon.com/freertos/latest/userguide/getting\_started\_mch.html](https://docs.aws.amazon.com/freertos/latest/userguide/getting_started_mch.html)]

---

<div class="post-metadata">

**Author:** ![marsmen](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@marsmen](https://forums.freertos.org/u/marsmen)\
**Post date:** [April 18, 2020, 4:29pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/5 "2020-04-18T16:29:21Z")

</div>

I’d not. I will explore this. Thank you.

---

<div class="post-metadata">

**Author:** ![SergentSloGin](https://d3iykfbgfh8zhg.cloudfront.net/user_avatar/forums.freertos.org/sergentslogin/32/48_2.png) [@SergentSloGin](https://forums.freertos.org/u/SergentSloGin)\
**Post date:** [April 20, 2020, 1:58pm UTC](https://forums.freertos.org/t/pic32mz-mplab-x-ide-freertos-harmony-file-structure-and-setup/9560/6 "2020-04-20T13:58:47Z")

</div>

@marsmen you may also find [this topic](https://forums.freertos.org/t/advice-wanted-freertos-harmony-3-uart/8715/4) as well as [thisone](https://forums.freertos.org/t/pic32mx-interrupt-crashes-system/8818/16) of interest. TL;DR Harmony 3 and FreeRTOS don’t play nice together ☹
