This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

tsk_lock() and tsk_unlock()

Hallo,

i use tsk_lock() for disables task switching(on Arm Cortex-M3)
is this the same function as NVIC_DisableIRQ(SysTick_IRQn)

i wonder because tsk_lock() takes longer then calling
NVIC_DisableIRQ(SysTick_IRQn)

Rgds,
Willi Huber

Parents
  • "using the OS API can have side effects beyond what you immediately assume."

    For those who AREN'T reluctant to read the Keil supported documentation, it can be whole lot easier.

    The on-line help states:

    The tsk_lock function disables the RTX kernel timer
    interrupts and thereby disables task switching.
    

    Looking at the source code and you find, guess what, the timer interrupt is disabled. No more, no less.

Reply
  • "using the OS API can have side effects beyond what you immediately assume."

    For those who AREN'T reluctant to read the Keil supported documentation, it can be whole lot easier.

    The on-line help states:

    The tsk_lock function disables the RTX kernel timer
    interrupts and thereby disables task switching.
    

    Looking at the source code and you find, guess what, the timer interrupt is disabled. No more, no less.

Children