NVIDIA DRIVE OS Linux SDK API Reference5.1.6.0 Release |
An ISC device represents a device that is attached or linked to the root I2C port.
Data Structures | |
struct | NvMediaISCAdvancedConfig |
Holds a pointer to a description of the target I2C device. More... | |
struct | NvMediaISCModuleConfig |
Holds the ISC Module ISP configuration. More... | |
struct | NvMediaISCAttrRange |
Holds the range of a sensor attribute. More... | |
struct | NvMediaISCSensorAttributes |
Holds the sensor attributes. More... | |
struct | NvMediaISCExposure |
Holds sensor exposure information. More... | |
struct | NvMediaISCWhiteBalance |
Holds the sensor white balance gain structure. More... | |
struct | NvMediaISCFrameReport |
Holds the sensor report frame report structure. More... | |
struct | NvMediaISCPWL |
Holds the sensor companding piecewise linear (PWL) structure. More... | |
struct | NvMediaISCTemperature |
Holds the sensor temperature structure. More... | |
struct | NvMediaISCCRC |
Holds the sensor CRC structure. More... | |
struct | NvMediaISCFrameSeqNum |
Holds the sensor frame sequence number structure. More... | |
struct | NvMediaISCSensorControl |
Holds the sensor control structure. More... | |
struct | NvMediaISCEmbeddedDataInfo |
Holds the sensor embedded data parsed info structure. More... | |
struct | NvMediaISCEmbeddedDataChunk |
struct | NvMediaISCExposureControl |
Holds exposure control information. More... | |
struct | NvMediaISCWBGainControl |
Holds the white balance control structure. More... | |
struct | NvMediaISCEmbeddedDataBuffer |
Holds the embedded data buffer structure. More... | |
struct | NvMediaISCEmbeddedData |
Holds the embedded data structure. More... | |
Typedefs | |
typedef struct NvMediaISCModuleConfig | NvMediaISCModuleConfig |
Holds the ISC Module ISP configuration. More... | |
typedef struct NvMediaISCAttrRange | NvMediaISCAttrRange |
Holds the range of a sensor attribute. More... | |
typedef struct NvMediaISCSensorAttributes | NvMediaISCSensorAttributes |
Holds the sensor attributes. More... | |
typedef struct NvMediaISCExposure | NvMediaISCExposure |
Holds sensor exposure information. More... | |
typedef struct NvMediaISCWhiteBalance | NvMediaISCWhiteBalance |
Holds the sensor white balance gain structure. More... | |
typedef struct NvMediaISCFrameReport | NvMediaISCFrameReport |
Holds the sensor report frame report structure. More... | |
typedef struct NvMediaISCPWL | NvMediaISCPWL |
Holds the sensor companding piecewise linear (PWL) structure. More... | |
typedef struct NvMediaISCTemperature | NvMediaISCTemperature |
Holds the sensor temperature structure. More... | |
typedef struct NvMediaISCCRC | NvMediaISCCRC |
Holds the sensor CRC structure. More... | |
typedef struct NvMediaISCFrameSeqNum | NvMediaISCFrameSeqNum |
Holds the sensor frame sequence number structure. More... | |
typedef struct NvMediaISCSensorControl | NvMediaISCSensorControl |
Holds the sensor control structure. More... | |
typedef struct NvMediaISCEmbeddedDataInfo | NvMediaISCEmbeddedDataInfo |
Holds the sensor embedded data parsed info structure. More... | |
typedef struct NvMediaISCEmbeddedDataChunk | NvMediaISCEmbeddedDataChunk |
typedef struct NvMediaISCExposureControl | NvMediaISCExposureControl |
Holds exposure control information. More... | |
typedef struct NvMediaISCWBGainControl | NvMediaISCWBGainControl |
Holds the white balance control structure. More... | |
typedef struct NvMediaISCEmbeddedData | NvMediaISCEmbeddedData |
Holds the embedded data structure. More... | |
Functions | |
NvMediaISCDevice * | NvMediaISCDeviceCreate (NvMediaISCRootDevice *rootDevice, uint32_t *deviceAddressList, uint32_t numDevices, NvMediaISCDeviceDriver *deviceDriver, NvMediaISCAdvancedConfig *advancedConfig) |
Creates an object that describes a device and returns a handle to the object. More... | |
void | NvMediaISCDeviceDestroy (NvMediaISCDevice *device) |
Destroys the object that describes an ISC device. More... | |
NvMediaStatus | NvMediaISCDeviceRead (NvMediaISCDevice *device, uint32_t deviceIndex, uint32_t regLength, uint8_t *regData, uint32_t dataLength, uint8_t *data) |
Performs a read operation over I2C. More... | |
NvMediaStatus | NvMediaISCDeviceWrite (NvMediaISCDevice *device, uint32_t deviceIndex, uint32_t dataLength, const uint8_t *data) |
Performs a write operation over I2C. More... | |
NvMediaStatus | NvMediaISCGetModuleConfig (NvMediaISCDevice *device, NvMediaISCModuleConfig *moduleConfig) |
Gets the module ISP configuration. More... | |
NvMediaStatus | NvMediaISCGetSensorAttributes (NvMediaISCDevice *device, NvMediaISCSensorAttributes *sensorAttr, const size_t sensorAttrStructSize) |
Gets the sensor attributes. More... | |
NvMediaStatus | NvMediaISCSetSensorControls (NvMediaISCDevice *device, const NvMediaISCSensorControl *sensorControl, const size_t sensrCtrlStructSize) |
Sets sensor control parameters. More... | |
NvMediaStatus | NvMediaISCParseEmbedDataInfo (NvMediaISCDevice *device, const NvMediaISCEmbeddedDataChunk *embeddedTopDataChunk, const NvMediaISCEmbeddedDataChunk *embeddedBotDataChunk, const size_t embeddedDataChunkStructSize, NvMediaISCEmbeddedDataInfo *embeddedDataInfo, const size_t dataInfoStructSize) |
Parses sensor embedded data info and provides sensor image settings information for the captured frame. More... | |
NvMediaStatus | NvMediaISCSetSensorCharMode (NvMediaISCDevice *device, uint8_t expNo) |
Set sensor to characterization mode. More... | |
typedef struct NvMediaISCAttrRange NvMediaISCAttrRange |
Holds the range of a sensor attribute.
typedef struct NvMediaISCCRC NvMediaISCCRC |
Holds the sensor CRC structure.
typedef struct NvMediaISCEmbeddedData NvMediaISCEmbeddedData |
Holds the embedded data structure.
typedef struct NvMediaISCEmbeddedDataChunk NvMediaISCEmbeddedDataChunk |
typedef struct NvMediaISCEmbeddedDataInfo NvMediaISCEmbeddedDataInfo |
Holds the sensor embedded data parsed info structure.
The sensor driver can selectively activate or deactivate any of the parsed info blocks, depending on whether the sensor supports it.
To activate a sensor info block, the sensor driver must set the info block's valid flag to TRUE and populate the parsed information corresponding to the block. To disable a sensor info block, it must set the valid flag to FALSE.
For example, if a sensor supports only exposure, white balance and CRC info, the sensor driver activates only the sensorExpInfo, sensorWBInfo, and sensorCRCInfo blocks (it sets their valid flags to TRUE) and disables all of the others (it sets their valid flags to FALSE).
typedef struct NvMediaISCExposure NvMediaISCExposure |
Holds sensor exposure information.
typedef struct NvMediaISCExposureControl NvMediaISCExposureControl |
Holds exposure control information.
typedef struct NvMediaISCFrameReport NvMediaISCFrameReport |
Holds the sensor report frame report structure.
typedef struct NvMediaISCFrameSeqNum NvMediaISCFrameSeqNum |
Holds the sensor frame sequence number structure.
typedef struct NvMediaISCModuleConfig NvMediaISCModuleConfig |
Holds the ISC Module ISP configuration.
typedef struct NvMediaISCPWL NvMediaISCPWL |
Holds the sensor companding piecewise linear (PWL) structure.
typedef struct NvMediaISCSensorAttributes NvMediaISCSensorAttributes |
Holds the sensor attributes.
typedef struct NvMediaISCSensorControl NvMediaISCSensorControl |
Holds the sensor control structure.
To activate a sensor control block, set the corresponding valid flag to TRUE and populate the control settings to be set.
To disable a sensor control block, set the corresponding valid flag to FALSE.
For example, to activate the white balance control block, set the wbValid flag in the wbControl structure to TRUE and populate the white balance settings to be programmed. To disable white balance control block, set the wbValid flag to FALSE.
typedef struct NvMediaISCTemperature NvMediaISCTemperature |
Holds the sensor temperature structure.
typedef struct NvMediaISCWBGainControl NvMediaISCWBGainControl |
Holds the white balance control structure.
typedef struct NvMediaISCWhiteBalance NvMediaISCWhiteBalance |
Holds the sensor white balance gain structure.
Defines Exposure mode.
Definition at line 1575 of file nvmedia_isc.h.
Defines ISC sensor attributes.
Definition at line 1653 of file nvmedia_isc.h.
NvMediaISCDevice* NvMediaISCDeviceCreate | ( | NvMediaISCRootDevice * | rootDevice, |
uint32_t * | deviceAddressList, | ||
uint32_t | numDevices, | ||
NvMediaISCDeviceDriver * | deviceDriver, | ||
NvMediaISCAdvancedConfig * | advancedConfig | ||
) |
Creates an object that describes a device and returns a handle to the object.
[in] | rootDevice | A pointer to the root device created with NvMediaISCRootDeviceCreate(). |
[in] | deviceAddressList | A pointer to a list of I2C device addresses corresponding to this NvMediaISCDevice object. |
[in] | numDevices | Number of I2C addresses in deviceAddressList. |
[in] | deviceDriver | A pointer to a structure that defines the behavior of the device. |
[in] | advancedConfig | A pointer to a structure that defines advanced configuration information about the device. |
void NvMediaISCDeviceDestroy | ( | NvMediaISCDevice * | device | ) |
Destroys the object that describes an ISC device.
[in] | device | Handle to the device to destroy. |
NvMediaStatus NvMediaISCDeviceRead | ( | NvMediaISCDevice * | device, |
uint32_t | deviceIndex, | ||
uint32_t | regLength, | ||
uint8_t * | regData, | ||
uint32_t | dataLength, | ||
uint8_t * | data | ||
) |
Performs a read operation over I2C.
For safety use cases, application software must perform a read followed by a read back of the same register locations using NvMediaISCDeviceRead() and verify that the two values match.
[in] | device | A pointer to the device to use. |
[in] | deviceIndex | Index of the subdevice to use |
[in] | regLength | Length of the register address, in bytes. |
[in] | regData | A pointer to the register address. |
[in] | dataLength | Length of data to be read, in bytes. |
[out] | data | A pointer to the location for storing the read data. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCDeviceWrite | ( | NvMediaISCDevice * | device, |
uint32_t | deviceIndex, | ||
uint32_t | dataLength, | ||
const uint8_t * | data | ||
) |
Performs a write operation over I2C.
For safety use cases, application software must perform a write using NvMediaISCDeviceWrite() followed by a read back of the same register locations using NvMediaISCDeviceRead() and verify that the write was successful.
[in] | device | A pointer to the device to use. |
[in] | deviceIndex | Index of the subdevice to use. |
[in] | dataLength | Length of data to be written, in bytes. |
[in] | data | A pointer to data to be written to device via I2C. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCGetModuleConfig | ( | NvMediaISCDevice * | device, |
NvMediaISCModuleConfig * | moduleConfig | ||
) |
Gets the module ISP configuration.
[in] | device | A pointer to the device to use. |
[out] | moduleConfig | A pointer to the module ISP configuration. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCGetSensorAttributes | ( | NvMediaISCDevice * | device, |
NvMediaISCSensorAttributes * | sensorAttr, | ||
const size_t | sensorAttrStructSize | ||
) |
Gets the sensor attributes.
Sensor attributes are static properties like sensor name, exposure-gain ranges supported, and number of active exposures.
[in] | device | A pointer to the device to use. |
[out] | sensorAttr | A pointer a sensor attributes structure. |
[in] | sensorAttrStructSize | Size of the sensorAttr structure. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCParseEmbedDataInfo | ( | NvMediaISCDevice * | device, |
const NvMediaISCEmbeddedDataChunk * | embeddedTopDataChunk, | ||
const NvMediaISCEmbeddedDataChunk * | embeddedBotDataChunk, | ||
const size_t | embeddedDataChunkStructSize, | ||
NvMediaISCEmbeddedDataInfo * | embeddedDataInfo, | ||
const size_t | dataInfoStructSize | ||
) |
Parses sensor embedded data info and provides sensor image settings information for the captured frame.
This function can be used to retrieve sensor image settings like exposure, gain, and white balance information applied to the frame.
[in] | device | A pointer to the device to use. |
[in] | embeddedTopDataChunk | A pointer to the top sensor embedded data chunk structure. |
[in] | embeddedBotDataChunk | A pointer to the bottom sensor embedded data chunk structure. |
[in] | embeddedDataChunkStructSize | Size of the embeddedTopDataChunk and embeddedBottomDataChunk structures, in bytes. |
[out] | embeddedDataInfo | A pointer to the embedded data parsed info structure. |
[in] | dataInfoStructSize | Size of the embeddedDataInfo structure, in bytes. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL or invalid. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCSetSensorCharMode | ( | NvMediaISCDevice * | device, |
uint8_t | expNo | ||
) |
Set sensor to characterization mode.
This function configures the sensor for characterization. Sensor characterization provides optimal parameters, corresponding to the sensor's physical and functional characteristics, for image processing.
Sensor characterization for High Dynamic Range (HDR) sensors with multiple exposures (T1, T2,... Tn) requires separately characterizing individual exposures for some sensors. This function can configure the sensor to capture each exposure separately, if required by sensor characterization. It changes sensor static attributes like numActiveExposures, sensorExpRange, and sensorGainRange, and so must be called during sensor initialization.
To characterize sensor exposure number n, where n = {1,2,3, … , N} for an N-exposure HDR sensor, set expNo to n. For a non-HDR sensor, set expNo to 1.
[in] | device | A pointer to the sensor control device in use. |
[in] | expNo | Sensor exposure number to be used for characterization. Must be in the range [0, (NVMEDIA_ISC_MAX_EXPOSURES - 1)]. For a non-HDR sensor, must be set to 1. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that device was NULL or invalid. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |
NvMediaStatus NvMediaISCSetSensorControls | ( | NvMediaISCDevice * | device, |
const NvMediaISCSensorControl * | sensorControl, | ||
const size_t | sensrCtrlStructSize | ||
) |
Sets sensor control parameters.
This function enables you to control sensor image settings like exposure time, sensor gain, and white balance gain. All parameters provided to this function are applied together at a frame boundary through ISC's "group hold" functionality, if supported by the sensor.
[in] | device | A pointer to the sensor control device in use. |
[in] | sensorControl | A pointer to a sensor control structure for device. |
[in] | sensrCtrlStructSize | Size of the sensorControl structure. |
NVMEDIA_STATUS_OK | indicates that the operation was successful. |
NVMEDIA_STATUS_BAD_PARAMETER | indicates that one or more pointer parameters was NULL. |
NVMEDIA_STATUS_NOT_SUPPORTED | indicates that the device driver does not support this functionality. |
NVMEDIA_STATUS_ERROR | indicates that any other error occurred. |