rtel wrote on Saturday, June 14, 2014:
If you have the demo project running, then you have the correct source files included, everything configured correctly. The demo will be taking up much of the Flash and RAM space though, so the first thing to do is remove the function calls that start the demo tasks to make room for your own application.
Open up main.c, and find the main() function. Remove all the lines between (but not including) prvSetupHardware() and vTaskStartScheduler().
Now the demo tasks are not being created you can remove the files that implement them from the project. In the Project window of MPLAB X you will see a folder called Standard Demo Tasks. You can remove all the files it contains (BlockQ.c, blocktim.c, etc.).
You can then start to add in your own code and header files - how you do that is specific to MPLAB, rather than FreeRTOS, so outside the scope of support for this particular forum - although there is plenty of documentation with MPLAB X and on the Microchip website, plus Microchip have a forum specific to MPLAB X.