We are converting a large production firmware package from Zilog eZ80 to PIC32MX795F512L. The current design uses cooperative scheduling via an OS we wrote ourselves. We would like to use preemptive scheduling via FreeRTOS and Harmony 3’s framework, where useful, primarily to become familiar with these and eventually to take advantage of the Harmony 3 device libraries.
The present challenge is about UARTs. We need 4 serial async-channels, 3 for RS485 and 1 for RS232. The baud rates are 9600 and 57600. At the moment we are not looking for demo code, (and I guess because Harmony 3 is new, there seems little available in any case), but rather advice on how to proceed. We see these alternatives:
Write the ISRs / Device drivers ourselves. Perhaps plib_uartx.c would be helpful as a starting point.
Use the Harmony 3 code and adapt it to our needs. This seems to omit much in the way of FreeRTOS integration.
Create ISRs to work with FreeRTOS, not using much from Harmony 3.
Fully integrate and use features from Harmony 3 and FreeRTOS, not that we are even sure what that would look like in practice.
We look forward to suggestions and ideas,