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.

PROCESSOR-SDK-J784S4: Clarification regarding IPC driver timeout units in API documentation (in QNX context)

Part Number: PROCESSOR-SDK-J784S4
Other Parts Discussed in Thread: SYSBIOS

Tool/software:

I am trying to understand in what unit I should input the timeouts to the IPC driver API commands RPMessage_recv and RPMessage_getRemoteEndPt().

This is PDK API Guide for J721E, 08.06, see 

PDK API Guide for J721E: IPC Driver Header (ti.com)

I want to understand what I should put as timeout in these calls for QNX - navigated to the documentation from psdkqa/08.06.00.07/qnx/docs/user_guide/qnx_sdk_components_j721e.html and psdkqa/08.06.00.07/qnx/docs/user_guide/qnx_sdk_components_j721e.html#ipc-resource-manager

  • The documentation for RPMessage_getRemoteEndPt() states:

Suitable values for timeout are the same as for the ti.sysbios.knl.Semaphore module.

timeout[IN] Timeout value (in system ticks)

  • The documentation for RPMessage_getRemoteEndPt() states:

timeout[IN] Maximum duration to wait for a message in microseconds.

When I try to follow the actual code, I end up that both API calls are using the SemaphoreP in ti/osal. This states:

* @param timeout Timeout (in milliseconds) to wait for the semaphore to be posted (signalled).

extern SemaphoreP_Status SemaphoreP_pend(SemaphoreP_Handle semPhandle,
uint32_t timeout);

Concrete implementations either seems to use system ticks (nonos) or milliseconds (freertos, safertos).

Could you please explain what units I should use for the timeout parameter to the IPC driver calls RPMessage_recv and RPMessage_getRemoteEndPt() in QNX context?

  • Hello,

    IPC driver timeout units in the QNX context are in microseconds.

    For IPC, please refer --> <SDK_INSTALL_PATH>/psdkqa/pdk//packages/ti/dev/IPC/src/ipc_api.c - See lockMutex() functions being used, which take "timeout" as a parameter.

    The implementation of lockMutex() is implanted as Ipc_qnxSemWait() function. See <SDK_INSTALL_PATH>/psdkqa/pdk//packages/ti/drv/ipc/src/ipc_osal_qnx.c

    Thanks.

  • Hi

    Thank you for the quick response. I have found the specific files and see now that microseconds is used in the QNX context.

    For the future, would it be possible to update the IPC API documentation to more explicitly state that the timeout is dependant on implementation. It is misleading at the moment I think (e.g. for RPMessage_getRemoteEndPt is states

    [IN] Timeout value (in system ticks)

    )