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.

Making a thread sleep on the DSP

We have encountered a situation wherein in the DM6467, while running our application on the ARM and running our proprietary codec on the DSP side, it has been deemed necessary to introduce a sleep or something similar to relinquish control of threads on the DSP.

Could someone suggest a method to achieve the same ??

 

Thanks in advance.

  • You're running on BIOS, so you could just call TSK_yield() or TSK_sleep().

    Note, that this method is not XDAIS compliant, so it's frowned upon and may have strange side effects.  Often frameworks make assumptions that BIOS threads at the same priority don't pre-empt each other, and XDAIS algs cannot block (so you can't call TSK_yield()!).  But if your system is simple, introducing a TSK_yield()/TSK_sleep() may be enough for you to see if the DSP-side scheduling is really where your root issue is.

    There are XDAIS-compliant methods for 'co-operative pre-emption', but it's a complex topic.  You might find some value reading through this article - http://processors.wiki.ti.com/index.php/Resource_Management_Framework_Components#Cooperative_Multitasking_and_Preemption

    Just don't put a codec calling TSK_yield()/TSK_sleep() into _my_ system...  ;)

    Chris