|
WS63 SDK 文档 7021f4f@fbb_ws63
ws63 和 ws63e 解决方案的 SDK 文档
|

宏定义 | |
| #define | LOS_ERRNO_RPQUEUE_PTR_NULL LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x01) |
| #define | LOS_ERRNO_RPQUEUE_CB_DAMAGED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x02) |
| #define | LOS_ERRNO_RPQUEUE_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x03) |
| #define | LOS_ERRNO_RPQUEUE_WRITE_BUSY LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x04) |
| #define | LOS_ERRNO_RPQUEUE_BUF_EMPTY LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x05) |
| #define | LOS_ERRNO_RPQUEUE_BUF_NOT_ENOUGH LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x06) |
| #define | LOS_ERRNO_RPQUEUE_WRITE_ERROR LOS_ERRNO_OS_FATAL(LOS_MOD_RPQUEUE, 0x07) |
| #define | LOS_ERRNO_RPQUEUE_SIZE_TOO_SMALL LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x08) |
| #define | LOS_ERRNO_RPQUEUE_READ_LOCK LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x09) |
| #define | LOS_ERRNO_RPQUEUE_HEADER_DAMAGED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0A) |
| #define | LOS_ERRNO_RPQUEUE_INITED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0B) |
| #define | LOS_ERRNO_RPQUEUE_SIZE_TOO_LARGE LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0C) |
函数 | |
| UINT32 | LOS_RpqueueInit (void *queue, UINT32 size, UINT32 option) |
| Rpqueue init. | |
| UINT32 | LOS_RpqueueMaxSendSizeGet (void *queue, UINT16 *maxSendSize) |
| get Rpqueue current max send size. | |
| UINT32 | LOS_RpqueueSend (void *queue, const UINT8 *data, UINT16 len, const LosRpqueueSendCfg *cfg) |
| Rpqueue send message. | |
| UINT32 | LOS_RpqueueRecv (void *queue, LosRpqueueCallback recvDataCb) |
| Rpqueue data receive. | |
| #define LOS_ERRNO_RPQUEUE_BUF_EMPTY LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x05) |
Task error code: The Rpqueue is empty.
Value: 0x02002505.
Solution: None.
| #define LOS_ERRNO_RPQUEUE_BUF_NOT_ENOUGH LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x06) |
Task error code: The Rpqueue is not enough to write data.
Value: 0x02002506.
Solution: Wait for the receiver to read the data.
| #define LOS_ERRNO_RPQUEUE_CB_DAMAGED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x02) |
Task error code: The rpqueue is damaged.
Value: 0x02002502.
Solution: Receiver: Wait for transmitter to re-initialize this queue. Transmitter: Call LOS_RpqueueInit to re-initialize this queue.
| #define LOS_ERRNO_RPQUEUE_HEADER_DAMAGED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0A) |
Task error code: The header data is damaged.
Value: 0x0200250A.
Solution: Waiting for transmitter to re-initialize this queue.
| #define LOS_ERRNO_RPQUEUE_INITED LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0B) |
Task error code: This queue has been initialized.
Value: 0x0200250B.
Solution: Process the return value according to the actual situation.
| #define LOS_ERRNO_RPQUEUE_INVALID LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x03) |
Task error code: The Rpqueue is invalid.
Value: 0x02002503.
Solution: Check the queue and initialize it.
| #define LOS_ERRNO_RPQUEUE_PTR_NULL LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x01) |
Task error code: Null parameter.
Value: 0x02002501.
Solution: Check the parameter.
| #define LOS_ERRNO_RPQUEUE_READ_LOCK LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x09) |
Task error code: The Rpqueue is in read lock.
Value: 0x02002509.
Solution: Try again.
| #define LOS_ERRNO_RPQUEUE_SIZE_TOO_LARGE LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x0C) |
Task error code: The Rpqueue buffer size is too large to init.
Value: 0x0200250C.
Solution: Use smaller size.
| #define LOS_ERRNO_RPQUEUE_SIZE_TOO_SMALL LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x08) |
Task error code: The Rpqueue buffer size is too small to init.
Value: 0x02002508.
Solution: Use bigger size.
| #define LOS_ERRNO_RPQUEUE_WRITE_BUSY LOS_ERRNO_OS_ERROR(LOS_MOD_RPQUEUE, 0x04) |
Task error code: The Rpqueue is writing.
Value: 0x02002504.
Solution: Waiting for queue release.
| #define LOS_ERRNO_RPQUEUE_WRITE_ERROR LOS_ERRNO_OS_FATAL(LOS_MOD_RPQUEUE, 0x07) |
Task error code: Systemic failure has occurred.
Value: 0x03002507.
Solution: This is a major failure and requires the highest level of security checks.
Rpqueue init.
| queue | [IN] Rpqueue address. |
| size | [IN] Rpqueue buffer size, size range is 24 - 65543 bytes. |
| option | [IN] Rpqueue option. |
| LOS_ERRNO_RPQUEUE_PTR_NULL | Queue address is NULL. |
| LOS_ERRNO_RPQUEUE_INITED | This queue has been initialized. |
| LOS_ERRNO_RPQUEUE_SIZE_TOO_SMALL | The Rpqueue buffer size is too small to init. |
| LOS_ERRNO_RPQUEUE_SIZE_TOO_LARGE | The Rpqueue buffer size is too large to init. |
| LOS_OK | Initialization is successful. |
get Rpqueue current max send size.
| queue | [IN] Remote Processor address. |
| maxSendSize | [OUT] Max send size, the value of 0 also is useful. |
| LOS_ERRNO_RPQUEUE_PTR_NULL | Pointer is NULL. |
| LOS_ERRNO_RPQUEUE_INVALID | Queue address is invalid. |
| LOS_ERRNO_RPQUEUE_BUF_NOT_ENOUGH | Rpqueue remaining space is not enough to send. |
| LOS_OK | Get max send size successfully. |
| UINT32 LOS_RpqueueRecv | ( | void * | queue, |
| LosRpqueueCallback | recvDataCb | ||
| ) |
Rpqueue data receive.
| queue | [IN] Rpqueue address. |
| recvDataCb | [IN] Receive data callback. |
| LOS_ERRNO_RPQUEUE_READ_LOCK | Rpqueue is in read lock. |
| LOS_ERRNO_RPQUEUE_PTR_NULL | Rpqueue address is NULL. |
| LOS_ERRNO_RPQUEUE_INVALID | Rpqueue address is invalid. |
| LOS_ERRNO_RPQUEUE_HEADER_DAMAGED | The header data is damaged. |
| LOS_ERRNO_RPQUEUE_BUF_EMPTY | The Rpqueue is empty. |
| LOS_ERRNO_RPQUEUE_CB_DAMAGED | The rpqueue is damaged. |
| LOS_OK | Initialization is successful. |
| UINT32 LOS_RpqueueSend | ( | void * | queue, |
| const UINT8 * | data, | ||
| UINT16 | len, | ||
| const LosRpqueueSendCfg * | cfg | ||
| ) |
Rpqueue send message.
| queue | [IN] Rpqueue address. |
| data | [IN] Send data buffer. |
| len | [IN] Send data size. |
| cfg | [IN] The config of sending. |
| LOS_ERRNO_RPQUEUE_PTR_NULL | Rpqueue address is NULL. |
| LOS_ERRNO_RPQUEUE_INVALID | Rpqueue address is invalid. |
| LOS_ERRNO_RPQUEUE_WRITE_BUSY | Rpqueue write busy. |
| LOS_ERRNO_RPQUEUE_BUF_NOT_ENOUGH | Rpqueue remaining space is not enough to send. |
| LOS_ERRNO_RPQUEUE_CB_DAMAGED | The rpqueue is damaged. |
| LOS_OK | Sending success. |