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

osMutexWait() function before the RTX osKernelInitialize()

Hi.

If I call the osMutexWait() function before the RTX osKernelInitialize() function is executed, an error is returned naturally.
After that, I call the osKernelInitialize() function. Is there any adverse effect of reading the osMutexWait() function?
What kind of scene is, the two devices (EEPROM and ADC) accessed by SPI I/F are exclusively controlled by MUTEX,
but it is necessary to read the EEPROM before starting the thread when the power is turned on.
Thank you.

jun

Parents
  • Thank you for your reply.
    I'm sorry it's hard to understand.
    Because it shares the function. This is because we want to use the function used when exclusive control is required in the same way even when exclusive control is not required. Also, because the function is used deep inside the nest, it is difficult to separate it with or without MUTEX.
    Probably, there is no problem if the MUTEX function gives an error (osErrorParameter) before OS initialization, and there is no problem if OS initialization is performed after that (because it is initialized), but the OS initialization process What about the content?

Reply
  • Thank you for your reply.
    I'm sorry it's hard to understand.
    Because it shares the function. This is because we want to use the function used when exclusive control is required in the same way even when exclusive control is not required. Also, because the function is used deep inside the nest, it is difficult to separate it with or without MUTEX.
    Probably, there is no problem if the MUTEX function gives an error (osErrorParameter) before OS initialization, and there is no problem if OS initialization is performed after that (because it is initialized), but the OS initialization process What about the content?

Children