Hello All,
I have the #define OS_TIMERS 1 in the conf file; but os_tmr_create() is always returning NULL - does this work on RTOS v1?
I have the v1.0 files installed; I am not able to upgrade this project to RTOS v2.
Thanks In Advance, John W.
Check below link: http://www.keil.com/forum/20906/
Non answer.
Unless the return value is osOK - like in using the other form of user timers: osTimerCreate() - which DOES work.
And I never saw os_tmr_call() ever work - couldn't even set a breakpoint on it in the debugger.
It apparently does not work. It would be great if Keil could publish some type of official post on this.
The revision history doesn't address these functions (os_tmr...) directly.
The lack of attention to detail and the cornucopia of misinformation on this forum is breathtaking.
Regards, John W.
The CMSIS-RTOS API does not support os_tmr_create(). What is supported is in the cmsis_os.h file.
CMSIS-RTOS RTX is am implementation of the CMSIS-RTOS API using RTX. RTX has an os_tmr_create() function, but this is not used by the CMSIS-RTOS RTX implementation. Because it is not used by the implementation it is not initialized by the implementation. Since you seem to be making direct calls to RTX (instead of using the CMSIS-RTOS API as intended) you are able to call the os_tmr_create() function, but since it is not initialized it always returns 0 (as you have already figured out). If you want to use the CMSIS-RTOS standard then you really should only make OS calls through this API.
You certainly could initialize RTX such that calls to os_tmr_create() would function, but the CMSIS_RTOS API has a standard timer interface as "full featured or better" than the RTX one.
The OS_TIMERS is for enabling CMSIS_RTOS timers, not RTX Timers.
Hello Robert,
Appreciate your response.
Having to be stuck in the RTOS API V1.0 boat doesn't make this any simpler; and as time passes the docs, support, etc. get more and more difficult.
I really hope we can update to version 2.1.2 of the RTOS API plus version 5.2.3 of the RTX 'lib' - at least that's the way I think of it right now from the 1.0/4.79 myopic view.
I suppose the success of this project will dictate whether we take that step.
Thanks Again! John W.