Hi, I'm working with CCS and I want to know how can I make anything similar to sleep_ms or wait or whatever to stop de program 10seconds with a command.
Thank you!
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.
Pol,
My apologies for the slow reply. We missed this one as it had a reply.
Is your project using TI-RTOS? There is a Task_sleep() function that can be used.
The compiler does have a __delay_cycles intrinsic that could be used.
__delay_cycles()
However this would use CPU cycles for the delay. If you want to really sleep during that time then I would ask in the sub 1-GHz forum what the best approach is.
Regards,
John
The input is "ticks" which can be configured. There is some information here: software-dl.ti.com/.../Clock.html
However I will ask someone to post a summary.
Regards,
John
Not much to summarize but here goes:
All timeout arguments in SYS/BIOS APIs (ie Task_sleep(), Semaphore_pend(), Even_pend(), Mailbox_pend()) are in units of Clock module 'ticks'.
The default "tick" period for almost all devices is 1000us (ie 1ms).
To configure the tick period within the user's .cfg file:
var Clock = xdc.useModule('ti.sysbios.knl.Clock');
Clock.tickPeriod = 1000; /* units are in microseconds */
Alan