If my program I have 5 threads. I am using keil rtx5. when I run the program all thread got initialized but not running only Idle thread is running and timer thread is in block stage. But when I removed 1 thread then all 4 threads plus timer and Idle thread are running. what is may be the issue?
Your application might run out of stack or the memory pool for the RTX5 is not big enough. Please use the µVision debugger to see what's happening on your target system. I would enable the Event Recorder to see all the error messages.
https://developer.arm.com/documentation/101407/0538/Debugging/Debug-Windows-and-Dialogs/Event-Recorder/Setup-Event-Recorder
https://www.keil.com/pack/doc/CMSIS/RTOS2/html/config_rtx5.html#evtrecConfig
You should then see what your threads are doing like:https://developer.arm.com/documentation/101407/0538/Debugging/Debug-Windows-and-Dialogs/System-Analyzer?lang=en
And you would see all the RTX errors like this (but in red):https://developer.arm.com/documentation/101407/0538/Debugging/Debug-Windows-and-Dialogs/Event-Recorder/Event-Recorder-Window