This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMDX570LC43HDK: Variable delay triggering of a task with freeRtos on TMDX570LC43HDK

Part Number: TMDX570LC43HDK

Hy,

in my application based on FreeRTOS I receive a message from the EMAC,

the payload contains an integer representing a time in ms,

if the payload is 5 it means I've to do something after 5ms,

instead if the payload is 10 it means I've to do something after 10ms, and so on,

my question is about the best way to implement this variable triggering of a task using freeRTOS on TMDX570LC43HDK?

Thanks

Antonio

  • How about this?

    A countdown list. Add the value as new entry on the end of the list.

    Have a 1ms task that inspects the countdown list.
    1). decrements every value in the list by 1.
    2). if any are zero; then perform the action and deletes that item from the list.

    Does that make sense?
  • The idea is nice, thanks,

    which is the minimum interrupt period I could have with freeRTOS on TMDX570LC43HDK?

    Can I obtain for example an interrupt every 100microseconds or less?

    Or I-ve to consider multiple of the OS Tick?

    If I can obtain an interrupt every 100microseconds I can use this resolution as base and use your approach,

    Antonio

  • You might look at vTaskDelay, which lists dwMilliseconds as a units, but also tells users that it is system ticks (which would be a hardware configuration and firmware issue to resolve inorder to make the ticks a 1 ms duration).
  • Antonio,

    I wanted to check to see if the discussions with Neil helped you arrive at the solution you needed? If so, can we close this thread?
  • Hy,

    Neil answer help me to understand that my kwoweledge of freertos wasn't enough,

    now I think the best solution for our project is software timers but again these are multiple of the system tick,

    so I will try to test with a systick lower than 1ms and a sw timer and see what happens,

    thanks for your help

    Antonio