loading

We will see how to setup the Arduino IDE for FreeRTOS. After setting up the IDE, we will run the first FreeRTOS example on Arduino Uno.

Step 1: Setting Up :

Download and install the Arduino IDE from this link

Downlaod the FreeRtos files form the github and paste into the library folder of arduino.

The folder structure should be as shown in above figure.

Step 2: Running First Example :

Now run the the IDE and open the first example from File->Examples->FreeRTOS->01-TaskSwitching as shown in above image.

Step 3: Output on Serial Terminal :

Compile and upload the code. Open the serial monitor to see the output.

Step 4: FreeRtos Configuration :

Please check this tutorial for freeRtos configuration.

Step 5: Heap Settings :

The original free rtos project can be downloaded here . It uses heap_3.c file and memory allocation is done by malloc() and free() functions. Heap size needs to be configured through linker setting and configTOTAL_HEAP_SIZE setting in FreeRTOSConfig.h has no effect.In order to solve this we will be using heap_4.c. Please check this link for more info on freeRtos heap usage.

Step 6: Downloads :

Download the complete project and libraries from here.

Step 7:

About This Instructable

3,147views

17favorites

License:

Bio: We make Embedded Design tools, boards, sensors, peripherals, DIY kits and awesome tutorials. We also help companies and individuals prototype embedded electronics.
More by ExploreEmbedded:Power and Temperature Data Logger With ESP32 and AWS IOT Secure IOT With AWS and Hornbill ESP32 Using Arduino. ESP32 Bluetooth Ambience Light Controller With WS2812 LED Strips. 
Add instructable to: