Go to the source code of this file.
Functions | |
SbgErrorCode | sbgEComCmdGenericGetModelId (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, uint32_t *pModelId) |
SbgErrorCode | sbgEComCmdGenericGetModelInfo (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, SbgEComModelInfo *pModelInfo) |
SbgErrorCode | sbgEComCmdGenericSetModelId (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, uint32_t modelId) |
SbgErrorCode | sbgEComReceiveAnyCmd (SbgEComHandle *pHandle, uint8_t *pMsgClass, uint8_t *pMsg, void *pData, size_t *pSize, size_t maxSize, uint32_t timeOut) |
SbgErrorCode | sbgEComReceiveCmd (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, void *pData, size_t *pSize, size_t maxSize, uint32_t timeOut) |
SbgErrorCode | sbgEComSendAck (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, SbgErrorCode cmdError) |
SbgErrorCode | sbgEComWaitForAck (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, uint32_t timeOut) |
SbgErrorCode sbgEComCmdGenericGetModelId | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
uint32_t * | pModelId | ||
) |
Generic function to get an error model ID
[in] | pHandle | A valid sbgECom handle. |
[in] | msgClass | Original message class |
[in] | msg | Original message ID |
[out] | pModelId | Returns the currently used model ID. |
Definition at line 446 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComCmdGenericGetModelInfo | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
SbgEComModelInfo * | pModelInfo | ||
) |
Generic function to retrieve error model information.
[in] | pHandle | A valid sbgECom handle. |
[in] | msgClass | Original message class |
[in] | msg | Original message ID |
[out] | pMotionProfileInfo | Pointer to a SbgEComModelInfo to contain model info. |
Definition at line 512 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComCmdGenericSetModelId | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
uint32_t | modelId | ||
) |
Generic function to set an error model ID
[in] | pHandle | A valid sbgECom handle. |
[in] | msgClass | Original message class |
[in] | msg | Original message ID |
[in] | modelId | Model ID to set |
Definition at line 380 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComReceiveAnyCmd | ( | SbgEComHandle * | pHandle, |
uint8_t * | pMsgClass, | ||
uint8_t * | pMsg, | ||
void * | pData, | ||
size_t * | pSize, | ||
size_t | maxSize, | ||
uint32_t | timeOut | ||
) |
Wait until any command that is not a output log is recevied during a specific time out. All binary logs received during this time are handled trough the standard callback system.
[in] | pHandle | A valid sbgECom handle. |
[out] | pMsgClass | Pointer used to hold the received command class. |
[out] | pMsg | Pointer used to hold the received command ID. |
[out] | pData | Allocated buffer used to hold received data field. |
[out] | pSize | Pointer used to hold the received data field size. |
[in] | maxSize | Max number of bytes that can be stored in the pData buffer. |
[in] | timeOut | Time out in ms during which we can receive the command. |
Definition at line 25 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComReceiveCmd | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
void * | pData, | ||
size_t * | pSize, | ||
size_t | maxSize, | ||
uint32_t | timeOut | ||
) |
Wait for a specific command to be received given a time out.
All binary logs received during this time are handled trough the standard callback system.
NACK for the requested command is treated as a negative answer and the corresponding error code is returned to user. In case an ACK is returned, we condider it's an error as well as expected command is not an ACK but regular command.
[in] | pHandle | A valid sbgECom handle. |
[out] | msgClass | Command class we expect to receive |
[out] | msg | Message id we expect to receive |
[out] | pData | Allocated buffer used to hold received data field. |
[out] | pSize | Pointer used to hold the received data field size. |
[in] | maxSize | Max number of bytes that can be stored in the pData buffer. |
[in] | timeOut | Time out in ms during which we can receive the command. |
Definition at line 174 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComSendAck | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
SbgErrorCode | cmdError | ||
) |
Send an ACK for a specific command with an associated error code.
[in] | pHandle | A valid sbgECom handle. |
[in] | msgClass | The message class that we want to send |
[in] | msg | The message ID that we want to send. |
[in] | cmdError | The associated error code. |
Definition at line 351 of file sbgEComCmdCommon.c.
SbgErrorCode sbgEComWaitForAck | ( | SbgEComHandle * | pHandle, |
uint8_t | msgClass, | ||
uint8_t | msg, | ||
uint32_t | timeOut | ||
) |
Wait for an ACK for a specified amount of time.
[in] | pHandle | A valid sbgECom handle. |
[in] | msgClass | The message class that we want to check |
[in] | msg | The message ID that we want to check |
[in] | timeOut | Time out in ms during which we can receive the ACK. |
Definition at line 278 of file sbgEComCmdCommon.c.