Defines an API for the Data sensor.
Data Structures | |
| struct | dwDataPacket |
| Holds a data packet. More... | |
Typedefs | |
| typedef struct dwDataPacket | dwDataPacket |
| Holds a data packet. More... | |
Functions | |
| DW_API_PUBLIC dwStatus | dwSensorData_readPacket (const dwDataPacket **const packet, dwTime_t const timeoutUs, dwSensorHandle_t const sensor) |
| Reads the next data packet. More... | |
| DW_API_PUBLIC dwStatus | dwSensorData_returnPacket (dwDataPacket const *const scan, dwSensorHandle_t const sensor) |
| Returns the data previously read to the internal pool. More... | |
| typedef struct dwDataPacket dwDataPacket |
Holds a data packet.
| DW_API_PUBLIC dwStatus dwSensorData_readPacket | ( | const dwDataPacket **const | packet, |
| dwTime_t const | timeoutUs, | ||
| dwSensorHandle_t const | sensor | ||
| ) |
Reads the next data packet.
The pointer returned is to the internal data pool. The data must be explicitly returned by the application. The method blocks until either a new valid frame is received from the sensor or the given timeout exceeds.
@req{GID-AV_REQ-6775212}
| [out] | packet | A pointer to a data packet read from the sensor. |
| [in] | timeoutUs | Specifies the timeout in microseconds. Special values: DW_TIMEOUT_INFINITE - to wait infinitely. Zero - means polling of internal queue. Normalized value in the range 0-5000000. |
| [in] | sensor | Specifies the sensor handle of the sensor previously created with 'dwSAL_createSensor()'. |
| DW_API_PUBLIC dwStatus dwSensorData_returnPacket | ( | dwDataPacket const *const | scan, |
| dwSensorHandle_t const | sensor | ||
| ) |
Returns the data previously read to the internal pool.
This API does not perform any of the functionality of this SW unit, but support API dwSensorData_readPacket. dwSensorData_readPacket in fact provides temporarily an packet, in the form of a pointer to an element of queue, to the User. While the element is in use by the User it is not part of the queue and not used by this SW unit; when the User does not need anymore the packet the element shall be returned in order to be used again. This API allows returning the packet previously read via API dwSensorData_readPacket to the queue.
@req{GID-AV_REQ-6830867}
| [in] | scan | A pointer to the data previously read using API dwSensorData_readPacket to be returned to the pool. |
| [in] | sensor | Specifies the sensor handle of the sensor previously created with 'dwSAL_createSensor()'. |