TI J721E Imaging User Guide
Sensor Driver

Introduction

RTOS Sensor Driver Framework.

Path: imaging/sensor_drv

Data Structures

struct  IssSensor_LineInterleavedExpFrmInfo
 For Line Interleaved WDR mode, this structure is used for specifying position of each exposure frame. More...
 
struct  I2cParams
 Register address and value pair, with delay. More...
 
struct  IssSensor_ExposureParams
 AutoExposure results data structure. More...
 
struct  IssSensor_WhiteBalanceParams
 AutoWhiteBalance results data structure. More...
 
struct  IssSensor_DccParams
 Structure for setting DCC params. More...
 
struct  IssSensor_Info
 Sensor Information structure. More...
 
struct  IssSensor_CreateParams
 Create Time parameters, ISS sensor layer uses these parameters and configures board module and sensor. More...
 
struct  IssCapture_CmplxIoLaneCfg
 CSI-2 COmplex I/O Lane Configuration. More...
 
struct  IssSensorIntfParams
 Structure used for describing sensor interfacing. More...
 
struct  IssSensorConfig
 Structure used for specifying register configurations of sensor, serializer and deserializer. More...
 
struct  IssAeRange
 Min/Max Range, used in AWB calibration data. More...
 
struct  IssAeDynamicParams
 Sensor Specific Auto Exposure Dynamic Parameters. More...
 
struct  IssAwbDynamicParams
 Sensor Specific Auto WhiteBalance Dynamic Parameters. More...
 
struct  IssSensorFxns
 Structure containins sensor information, used for registering it to the sensor framework. More...
 
struct  IssSensors_Handle
 Handle to the sensor driver. Includes all the information about the sensor. More...
 

Functions

int32_t IssSensor_Init ()
 Function to initialize sensor driver framework. Registers with remote service. Includes init function of supported sensor drivers. This step is critical for registring a sensor driver with the framework. More...
 
int32_t IssSensor_DeInit ()
 Function to de-initialize sensor driver framework. Unregisters remote service. More...
 
int32_t IssSensor_Register (IssSensors_Handle *pSensorPrms)
 Function to register a sensor driver with the driver framework. More...
 
int32_t IssSensor_GetSensorInfo (char *name, IssSensor_CreateParams *pCreatePrms)
 Function to get Sensor information for given sensor It searches in the table of registered sensors, it returns information of first sensor, whose name matches with the given sensor. More...
 
int32_t IssSensor_GetSensorInfoFromDccId (uint32_t dccId, IssSensor_Info *pInfo)
 Function to get Sensor information for sensor whose DCC ID is passed. It searches in the table of registered sensors, it returns information of first sensor, whose dcc id matches with the given id. Typically used by the DCC Network handler to get the sensor information. More...
 
IssSensors_HandleIssSensor_GetSensorHandle (char *name)
 Function to get the sensor handle for the given sensor. This is used by the DCC Network Handler to Read/Write sensor register. Returns sensor handle only if it is opened. More...
 
void * IssSensor_Create (char *name)
 Creates the sensor, based on the create params, it searches for the given sensor in the registered sensors, configures the board module if sensor supports board module and creates sensor fvid2 driver. It also configures sensor in the given WDR mode and also sets the default output resolution in the sensor. More...
 
int32_t IssSensor_Control (void *handle, uint32_t cmd, void *cmdArgs, void *cmdRetArgs)
 Used for sending control commands, this layer supports all configuration using control commants. For the list of supported control command, see defines section of this file. More...
 
int32_t IssSensor_Start (void *handle, uint32_t chId)
 Used Starting the sensor, which is already opened using Create function. Must be called after Create function. More...
 
int32_t IssSensor_Stop (void *handle, uint32_t chId)
 Used stopping the sensor, which is alraedy opened using Create function. Must be called after Create function. More...
 
int32_t IssSensor_Delete (void *handle)
 Used for deleting the sensor, which is already opened using Create function. Internally it deletes sensor's fvid2 driver. After this call, handle is not valid. More...
 
int32_t ub960_cfgScript (I2cParams *script, int8_t ub960InstanceId)
 Function to configure UB960 deserializer. More...
 
int32_t ub953_cfgScript (uint8_t i2cInstId, uint8_t i2cAddr, I2cParams *script)
 Function to configure UB953 serializer. More...
 
IssSensors_HandlegetSensorHandleFromName (char *name)
 Function to get sensor handle from name. More...
 
int32_t IssSensor_PowerOn (void *handle, uint32_t chMask)
 Function to power ON the sensor. More...
 
int32_t IssSensor_PowerOff (void *handle, uint32_t chId)
 Function to power OFF the sensor. More...
 
int32_t IssSensor_Config (void *handle, uint32_t chId, uint32_t feat)
 Function to configure the sensor. More...
 
int32_t IssSensor_SetAeParams (void *handle, uint32_t chId, IssSensor_ExposureParams *pExpPrms)
 Function to send Exposure parameters to the sensor. More...
 
int32_t IssSensor_SetAwbParams (void *handle, uint32_t chId, IssSensor_WhiteBalanceParams *pWbPrms)
 Function to send WhiteBalance gains to the sensor. More...
 
int32_t enableUB960Streaming (uint32_t chId)
 Function to enable streaming from UB960 by setting register 0x33 to 0x3 for the given camera channel. More...
 
int32_t disableUB960Streaming (uint32_t chId)
 Function to enable streaming from UB960 by setting register 0x33 to 0x2 for the given camera channel. More...
 
int8_t getUB960InstIdFromChId (uint32_t chId)
 Function to map UB960 Instance to channel number On Fusion board the mapping is as follows Camera Channel 0 - UB960 Instance 0 Camera Channel 1 - UB960 Instance 0 Camera Channel 2 - UB960 Instance 0 Camera Channel 3 - UB960 Instance 0 Camera Channel 4 - UB960 Instance 1 Camera Channel 5 - UB960 Instance 1 Camera Channel 6 - UB960 Instance 1 Camera Channel 7 - UB960 Instance 1. More...
 

Typedefs

typedef int32_t(* IssSensor_ProbeFxn) (uint32_t chId, void *pSensorHdl)
 Callback for sensor probe. Detection of sensor HW using chip ID register. More...
 
typedef int32_t(* IssSensor_ConfigFxn) (uint32_t chId, void *pSensorHdl, uint32_t sensor_features_requested)
 Callback for sensor & SerDes configuration. More...
 
typedef int32_t(* IssSensor_StreamOnFxn) (uint32_t chId, void *pSensorHdl)
 Callback for starting streaming. More...
 
typedef int32_t(* IssSensor_StreamOffFxn) (uint32_t chId, void *pSensorHdl)
 Callback for stopping streaming. More...
 
typedef int32_t(* IssSensor_PowerOnFxn) (uint32_t chId, void *pSensorHdl)
 Callback for powering ON the sensor and/or configuring the deserialser so that the sensor is visible to the SoC. More...
 
typedef int32_t(* IssSensor_PowerOffFxn) (uint32_t chId, void *pSensorHdl)
 Callback for powering OFF the sensor, if applicable. More...
 
typedef int32_t(* IssSensor_SetAeParamsFxn) (void *pSensorHdl, uint32_t chId, IssSensor_ExposureParams *pExpPrms)
 Callback for setting sensor exposure and gain. More...
 
typedef int32_t(* IssSensor_GetDccParamsFxn) (uint32_t chId, void *pSensorHdl, IssSensor_DccParams *pDccPrms)
 Callback for getting DCC parameters. Reserved for future use. More...
 
typedef int32_t(* IssSensor_GetExpParamsFxn) (uint32_t chId, void *pSensorHdl, IssSensor_ExposureParams *pExpPrms)
 Callback for getting current exposure settings. Reserved for future use. More...
 
typedef void(* IssSensor_InitAewbConfigFxn) (uint32_t chId, void *pSensorHdl)
 Callback for setting AEWB specific sensor settings, if applicable. Reserved for future use. More...
 
typedef void(* IssSensor_GetIspConfigFxn) (uint32_t chId, void *pSensorHdl)
 Callback for getting ISP settings specific to the sensor, if applicable. Reserved for future use. More...
 
typedef void(* IssSensor_DeinitFxn) (uint32_t chId, void *pSensorHdl)
 Callback for de-initializing the sensor, if applicable. Reserved for future use. More...
 
typedef int32_t(* I2cRegReadWriteFxn) (uint32_t chId, void *pSensorHdl, uint32_t readWriteFlag, I2cParams *pReg)
 Callback for reading/writing sensor registers from the application. Reserved for future use. More...
 
typedef int32_t(* IssSensor_GetExpPrgFxn) (uint32_t chId, void *pSensorHdl, IssAeDynamicParams *p_ae_dynPrms)
 Callback for getting sensor's exposure constraints. Needed for AutoExposure tuning. More...
 
typedef int32_t(* IssSensor_GetWbConfigFxn) (uint32_t chId, void *pSensorHdl, IssAwbDynamicParams *p_awb_dynPrms)
 Callback for getting sensor's WB constraints. Needed for AutoWhiteBalance tuning. More...
 
typedef int32_t(* IssSensor_SetAwbParamsFxn) (void *pSensorHdl, uint32_t chId, IssSensor_WhiteBalanceParams *pWbPrms)
 Callback for setting WB gains in the sensor. More...
 

Enumerations

enum  IMAGE_SENSOR_CTRLCMD {
  IMAGE_SENSOR_CTRLCMD_GETEXPPRG = 0, IMAGE_SENSOR_CTRLCMD_GETWBCFG, IMAGE_SENSOR_CTRLCMD_SETEXPGAIN, IMAGE_SENSOR_CTRLCMD_GETEXPGAIN,
  IMAGE_SENSOR_CTRLCMD_SETWBGAIN, IMAGE_SENSOR_CTRLCMD_GETWBGAIN, IMAGE_SENSOR_CTRLCMD_DEBUG, IMAGE_SENSOR_CTRLCMD_READ_SENSOR_REG,
  IMAGE_SENSOR_CTRLCMD_WRITE_SENSOR_REG, IMAGE_SENSOR_CTRLCMD_MAX, IMAGE_SENSOR_CTRLCMD_FORCE32BITS = 0x7FFFFFFF
}
 IOCTLS supported as part of IM_SENSOR_CMD_CTL command. More...
 
enum  IssSensor_Features {
  ISS_SENSOR_FEATURE_HFLIP = 0x1, ISS_SENSOR_FEATURE_VFLIP = 0x2, ISS_SENSOR_FEATURE_EMBEDDED_DATA = 0x4, ISS_SENSOR_FEATURE_MANUAL_EXPOSURE = 0x8,
  ISS_SENSOR_FEATURE_MANUAL_GAIN = 0x10, ISS_SENSOR_FEATURE_LINEAR_MODE = 0x20, ISS_SENSOR_FEATURE_COMB_COMP_WDR_MODE = 0x40, ISS_SENSOR_FEATURE_TWO_FRAME_WDR_MODE = 0x80,
  ISS_SENSOR_FEATURE_DCC_SUPPORTED = 0x100, ISS_SENSOR_FEATURE_CFG_UC1 = 0x200, ISS_SENSOR_FEATURE_CFG_UC2 = 0x400, ISS_SENSOR_MAX_FEATURES = 0x800,
  ISS_SENSOR_FEATURE_FORCE32BITS = 0x7FFFFFFF
}
 Enum for Sensor Features. More...
 
enum  IssSensor_Exposures {
  ISS_SENSOR_EXPOSURE_LONG, ISS_SENSOR_EXPOSURE_SHORT, ISS_SENSOR_EXPOSURE_VSHORT, ISS_SENSOR_MAX_EXPOSURE,
  ISS_SENSOR_EXPOSURE_FORCE32BITS = 0x7FFFFFFF
}
 Enum for different sensor exposures in WDR sensor. More...
 
enum  AlgItt_IssAewbMode {
  ALGORITHMS_ISS_AEWB_MODE_AWB = 0, ALGORITHMS_ISS_AEWB_MODE_AE = 1, ALGORITHMS_ISS_AEWB_MODE_AEWB = 2, ALGORITHMS_ISS_AEWB_MODE_NONE = 3,
  ALGORITHMS_ISS_AEWB_MODE_MAX = 4, ALGORITHMS_ISS_AEWB_MODE_FORCE32BITS = 0x7FFFFFFF
}
 AEWB Algorithm Mode. More...
 
enum  AlgItt_IssAeMode { ALGORITHMS_ISS_AE_AUTO = 0, ALGORITHMS_ISS_AE_MANUAL = 1, ALGORITHMS_ISS_AE_DISABLED = 2 }
 AE Algorithm SubModes. More...
 
enum  AlgItt_IssAwbMode { ALGORITHMS_ISS_AWB_AUTO = 0, ALGORITHMS_ISS_AWB_MANUAL = 1, ALGORITHMS_ISS_AWB_DISABLED = 2 }
 AWB Algorithm SubModes. More...
 

Macros

#define SENSOR_I2C_TIMEOUT   (5000U)
 RPC Commands application can send to sensor driver. More...
 
#define MAX_AE_DYN_PARAMS   (10U)
 Maximum number of dynamic parameter configuration supported for Auto Exposure Algorithm tuning. More...
 

Macro Definition Documentation

◆ SENSOR_I2C_TIMEOUT

#define SENSOR_I2C_TIMEOUT   (5000U)

RPC Commands application can send to sensor driver.

◆ MAX_AE_DYN_PARAMS

#define MAX_AE_DYN_PARAMS   (10U)

Maximum number of dynamic parameter configuration supported for Auto Exposure Algorithm tuning.

Typedef Documentation

◆ IssSensor_ProbeFxn

typedef int32_t(* IssSensor_ProbeFxn) (uint32_t chId, void *pSensorHdl)

Callback for sensor probe. Detection of sensor HW using chip ID register.

◆ IssSensor_ConfigFxn

typedef int32_t(* IssSensor_ConfigFxn) (uint32_t chId, void *pSensorHdl, uint32_t sensor_features_requested)

Callback for sensor & SerDes configuration.

◆ IssSensor_StreamOnFxn

typedef int32_t(* IssSensor_StreamOnFxn) (uint32_t chId, void *pSensorHdl)

Callback for starting streaming.

◆ IssSensor_StreamOffFxn

typedef int32_t(* IssSensor_StreamOffFxn) (uint32_t chId, void *pSensorHdl)

Callback for stopping streaming.

◆ IssSensor_PowerOnFxn

typedef int32_t(* IssSensor_PowerOnFxn) (uint32_t chId, void *pSensorHdl)

Callback for powering ON the sensor and/or configuring the deserialser so that the sensor is visible to the SoC.

◆ IssSensor_PowerOffFxn

typedef int32_t(* IssSensor_PowerOffFxn) (uint32_t chId, void *pSensorHdl)

Callback for powering OFF the sensor, if applicable.

◆ IssSensor_SetAeParamsFxn

typedef int32_t(* IssSensor_SetAeParamsFxn) (void *pSensorHdl, uint32_t chId, IssSensor_ExposureParams *pExpPrms)

Callback for setting sensor exposure and gain.

◆ IssSensor_GetDccParamsFxn

typedef int32_t(* IssSensor_GetDccParamsFxn) (uint32_t chId, void *pSensorHdl, IssSensor_DccParams *pDccPrms)

Callback for getting DCC parameters. Reserved for future use.

◆ IssSensor_GetExpParamsFxn

typedef int32_t(* IssSensor_GetExpParamsFxn) (uint32_t chId, void *pSensorHdl, IssSensor_ExposureParams *pExpPrms)

Callback for getting current exposure settings. Reserved for future use.

◆ IssSensor_InitAewbConfigFxn

typedef void(* IssSensor_InitAewbConfigFxn) (uint32_t chId, void *pSensorHdl)

Callback for setting AEWB specific sensor settings, if applicable. Reserved for future use.

◆ IssSensor_GetIspConfigFxn

typedef void(* IssSensor_GetIspConfigFxn) (uint32_t chId, void *pSensorHdl)

Callback for getting ISP settings specific to the sensor, if applicable. Reserved for future use.

◆ IssSensor_DeinitFxn

typedef void(* IssSensor_DeinitFxn) (uint32_t chId, void *pSensorHdl)

Callback for de-initializing the sensor, if applicable. Reserved for future use.

◆ I2cRegReadWriteFxn

typedef int32_t(* I2cRegReadWriteFxn) (uint32_t chId, void *pSensorHdl, uint32_t readWriteFlag, I2cParams *pReg)

Callback for reading/writing sensor registers from the application. Reserved for future use.

◆ IssSensor_GetExpPrgFxn

typedef int32_t(* IssSensor_GetExpPrgFxn) (uint32_t chId, void *pSensorHdl, IssAeDynamicParams *p_ae_dynPrms)

Callback for getting sensor's exposure constraints. Needed for AutoExposure tuning.

◆ IssSensor_GetWbConfigFxn

typedef int32_t(* IssSensor_GetWbConfigFxn) (uint32_t chId, void *pSensorHdl, IssAwbDynamicParams *p_awb_dynPrms)

Callback for getting sensor's WB constraints. Needed for AutoWhiteBalance tuning.

◆ IssSensor_SetAwbParamsFxn

typedef int32_t(* IssSensor_SetAwbParamsFxn) (void *pSensorHdl, uint32_t chId, IssSensor_WhiteBalanceParams *pWbPrms)

Callback for setting WB gains in the sensor.

Enumeration Type Documentation

◆ IMAGE_SENSOR_CTRLCMD

IOCTLS supported as part of IM_SENSOR_CMD_CTL command.

Enumerator
IMAGE_SENSOR_CTRLCMD_GETEXPPRG 
IMAGE_SENSOR_CTRLCMD_GETWBCFG 
IMAGE_SENSOR_CTRLCMD_SETEXPGAIN 
IMAGE_SENSOR_CTRLCMD_GETEXPGAIN 
IMAGE_SENSOR_CTRLCMD_SETWBGAIN 
IMAGE_SENSOR_CTRLCMD_GETWBGAIN 
IMAGE_SENSOR_CTRLCMD_DEBUG 
IMAGE_SENSOR_CTRLCMD_READ_SENSOR_REG 
IMAGE_SENSOR_CTRLCMD_WRITE_SENSOR_REG 
IMAGE_SENSOR_CTRLCMD_MAX 
IMAGE_SENSOR_CTRLCMD_FORCE32BITS 

◆ IssSensor_Features

Enum for Sensor Features.

Enumerator
ISS_SENSOR_FEATURE_HFLIP 

Horizontal Flip feature

ISS_SENSOR_FEATURE_VFLIP 

Vertical Flip feature

ISS_SENSOR_FEATURE_EMBEDDED_DATA 

Embedded extra data in the frame feature

ISS_SENSOR_FEATURE_MANUAL_EXPOSURE 

Support for Manual Exposure

ISS_SENSOR_FEATURE_MANUAL_GAIN 

Support for Manual Gain

ISS_SENSOR_FEATURE_LINEAR_MODE 

Support for Linear Mode output

ISS_SENSOR_FEATURE_COMB_COMP_WDR_MODE 

Support for Combined Compressed WDR Mode

ISS_SENSOR_FEATURE_TWO_FRAME_WDR_MODE 

Support for Two Pass WDR Mode

ISS_SENSOR_FEATURE_DCC_SUPPORTED 

DCC Feature

ISS_SENSOR_FEATURE_CFG_UC1 

Advanced sensor configuration for custom usecases.

ISS_SENSOR_FEATURE_CFG_UC2 

Advanced sensor configuration for custom usecases.

ISS_SENSOR_MAX_FEATURES 

Max Features

ISS_SENSOR_FEATURE_FORCE32BITS 

Last enum to make it int32

◆ IssSensor_Exposures

Enum for different sensor exposures in WDR sensor.

Enumerator
ISS_SENSOR_EXPOSURE_LONG 

Long Exposure output from sensor

ISS_SENSOR_EXPOSURE_SHORT 

Short Exposure output from sensor

ISS_SENSOR_EXPOSURE_VSHORT 

Very short Exposure output from sensor

ISS_SENSOR_MAX_EXPOSURE 
ISS_SENSOR_EXPOSURE_FORCE32BITS 

◆ AlgItt_IssAewbMode

AEWB Algorithm Mode.

Enumerator
ALGORITHMS_ISS_AEWB_MODE_AWB 

Auto White Balance Mode only

ALGORITHMS_ISS_AEWB_MODE_AE 

Auto Exposure Mode only

ALGORITHMS_ISS_AEWB_MODE_AEWB 

Auto Exposure and Auto White Balance Mode

ALGORITHMS_ISS_AEWB_MODE_NONE 

None of AEWB Mode, Used when DCC Functionality is required, but not AEWB Also used when AEWB is dynamically enabled/disabled using DCC

ALGORITHMS_ISS_AEWB_MODE_MAX 

Max mode value, used for error checking

ALGORITHMS_ISS_AEWB_MODE_FORCE32BITS 

This should be the last value after the max enumeration value. This is to make sure enum size defaults to 32 bits always regardless of compiler.

◆ AlgItt_IssAeMode

AE Algorithm SubModes.

Enumerator
ALGORITHMS_ISS_AE_AUTO 

Auto Exposure Manual Exposure

ALGORITHMS_ISS_AE_MANUAL 

Exposure Control Disabled

ALGORITHMS_ISS_AE_DISABLED 

◆ AlgItt_IssAwbMode

AWB Algorithm SubModes.

Enumerator
ALGORITHMS_ISS_AWB_AUTO 

Auto WhiteBalance Manual Exposure

ALGORITHMS_ISS_AWB_MANUAL 

Exposure Control Disabled

ALGORITHMS_ISS_AWB_DISABLED 

Function Documentation

◆ IssSensor_Init()

int32_t IssSensor_Init ( )

Function to initialize sensor driver framework. Registers with remote service. Includes init function of supported sensor drivers. This step is critical for registring a sensor driver with the framework.

Parameters
registeredSensorNamesOUT Names of all the registered sensors
Returns
0 in case of success error otherwise

◆ IssSensor_DeInit()

int32_t IssSensor_DeInit ( )

Function to de-initialize sensor driver framework. Unregisters remote service.

Returns
0 in case of success error otherwise

◆ IssSensor_Register()

int32_t IssSensor_Register ( IssSensors_Handle pSensorPrms)

Function to register a sensor driver with the driver framework.

Parameters
pSensorPrmsAll sensor properties and the APIs
Returns
0 in case of success error otherwise

◆ IssSensor_GetSensorInfo()

int32_t IssSensor_GetSensorInfo ( char *  name,
IssSensor_CreateParams pCreatePrms 
)

Function to get Sensor information for given sensor It searches in the table of registered sensors, it returns information of first sensor, whose name matches with the given sensor.

Parameters
nameName of the sensor
pCreatePrms[OUT] Pointer to sensor create parmas structure
Returns
0 in case of success error otherwise

◆ IssSensor_GetSensorInfoFromDccId()

int32_t IssSensor_GetSensorInfoFromDccId ( uint32_t  dccId,
IssSensor_Info pInfo 
)

Function to get Sensor information for sensor whose DCC ID is passed. It searches in the table of registered sensors, it returns information of first sensor, whose dcc id matches with the given id. Typically used by the DCC Network handler to get the sensor information.

Parameters
dccIdDCC Id of the sensor
pInfo[OUT] Pointer to sensor information structure
Returns
0 in case of success error otherwise

◆ IssSensor_GetSensorHandle()

IssSensors_Handle* IssSensor_GetSensorHandle ( char *  name)

Function to get the sensor handle for the given sensor. This is used by the DCC Network Handler to Read/Write sensor register. Returns sensor handle only if it is opened.

Parameters
dccIdDCC Id of the sensor
pInfo[OUT] Pointer to sensor information structure
Returns
0 in case of success error otherwise

◆ IssSensor_Create()

void* IssSensor_Create ( char *  name)

Creates the sensor, based on the create params, it searches for the given sensor in the registered sensors, configures the board module if sensor supports board module and creates sensor fvid2 driver. It also configures sensor in the given WDR mode and also sets the default output resolution in the sensor.

Parameters
pCreatePrmsPointer to the create params
Returns
handle to the created sensor NULL if there is any error

◆ IssSensor_Control()

int32_t IssSensor_Control ( void *  handle,
uint32_t  cmd,
void *  cmdArgs,
void *  cmdRetArgs 
)

Used for sending control commands, this layer supports all configuration using control commants. For the list of supported control command, see defines section of this file.

Must be called after Create function

Parameters
handleHandle to the created sensor
cmdControl command
cmdArgsPointer to the command specific arguments.
cmdRetArgs[OUT] Pointer to the command specific return arguments
Returns
0 in case of success error otherwise

◆ IssSensor_Start()

int32_t IssSensor_Start ( void *  handle,
uint32_t  chId 
)

Used Starting the sensor, which is already opened using Create function. Must be called after Create function.

Parameters
handleHandle of the sensor
chIdID of the channel to be started.
Returns
0 in case of success error otherwise

◆ IssSensor_Stop()

int32_t IssSensor_Stop ( void *  handle,
uint32_t  chId 
)

Used stopping the sensor, which is alraedy opened using Create function. Must be called after Create function.

Parameters
handleHandle of the sensor
chIdID of the channel to be stopped.
Returns
0 in case of success error otherwise

◆ IssSensor_Delete()

int32_t IssSensor_Delete ( void *  handle)

Used for deleting the sensor, which is already opened using Create function. Internally it deletes sensor's fvid2 driver. After this call, handle is not valid.

Must be called after Create function.

Returns
0 in case of success error otherwise

◆ ub960_cfgScript()

int32_t ub960_cfgScript ( I2cParams script,
int8_t  ub960InstanceId 
)

Function to configure UB960 deserializer.

Parameters
scriptArray of type I2CParams with last entry being {0xFFFF, 0x00, 0x00}
ub960InstanceIdID 0/1 indicating which UB960 on the board is to be configured
Returns
0 in case of success error otherwise

◆ ub953_cfgScript()

int32_t ub953_cfgScript ( uint8_t  i2cInstId,
uint8_t  i2cAddr,
I2cParams script 
)

Function to configure UB953 serializer.

Parameters
i2cInstIdI2C bus on which the serializer is populated
i2cAddr7-bit I2C address, usually alias address as configured in UB960
scriptArray of type I2CParams with last entry being {0xFFFF, 0x00, 0x00}
Returns
0 in case of success error otherwise

◆ getSensorHandleFromName()

IssSensors_Handle* getSensorHandleFromName ( char *  name)

Function to get sensor handle from name.

Parameters
namename of the sensor as specfied in IssSensor_CreateParams
Returns
pointer to the sensor handle if the name was found in the registered sensor list NULL otherwise

◆ IssSensor_PowerOn()

int32_t IssSensor_PowerOn ( void *  handle,
uint32_t  chMask 
)

Function to power ON the sensor.

Parameters
handlePointer to sensor handle
chMaskBinary mask indicating which cameras are to be powered ON For e.g. 0x1F means that first 5 cameras must be enabled This would mean configuring both the UB960 deserializers Another example - chMask = 0x1 means only the first camera should be enabled Therefore, only first instance of UB960 should be configured.
Returns
0 if success -1 otherwise

◆ IssSensor_PowerOff()

int32_t IssSensor_PowerOff ( void *  handle,
uint32_t  chId 
)

Function to power OFF the sensor.

Parameters
handlePointer to sensor handle
chIdChannel ID indicating which camera needs to be disabled
Returns
0 if success -1 otherwise

◆ IssSensor_Config()

int32_t IssSensor_Config ( void *  handle,
uint32_t  chId,
uint32_t  feat 
)

Function to configure the sensor.

Parameters
handlePointer to sensor handle
chIdChannel ID of the camera to be configured
featFeature mask. Sensor drver can apply different settings for different features For e.g. linear mode vs WDR mode OR 30fps mode vs 60fps mode
Returns
0 if success -1 otherwise

◆ IssSensor_SetAeParams()

int32_t IssSensor_SetAeParams ( void *  handle,
uint32_t  chId,
IssSensor_ExposureParams pExpPrms 
)

Function to send Exposure parameters to the sensor.

Parameters
handlePointer to sensor handle
chIdChannel ID of the camera to be configured
pExpPrmsExposure parameters - integration time and sensor gain
Returns
0 if success -1 otherwise

◆ IssSensor_SetAwbParams()

int32_t IssSensor_SetAwbParams ( void *  handle,
uint32_t  chId,
IssSensor_WhiteBalanceParams pWbPrms 
)

Function to send WhiteBalance gains to the sensor.

Parameters
handlePointer to sensor handle
chIdChannel ID of the camera to be configured
pWbPrmsWhiteBalance parameters - RGB colors gains
Returns
0 if success -1 otherwise

◆ enableUB960Streaming()

int32_t enableUB960Streaming ( uint32_t  chId)

Function to enable streaming from UB960 by setting register 0x33 to 0x3 for the given camera channel.

Parameters
chIdChannel ID of the camera to be configured
Returns
0 if success -1 otherwise

◆ disableUB960Streaming()

int32_t disableUB960Streaming ( uint32_t  chId)

Function to enable streaming from UB960 by setting register 0x33 to 0x2 for the given camera channel.

Parameters
chIdChannel ID of the camera to be configured
Returns
0 if success -1 otherwise

◆ getUB960InstIdFromChId()

int8_t getUB960InstIdFromChId ( uint32_t  chId)

Function to map UB960 Instance to channel number On Fusion board the mapping is as follows Camera Channel 0 - UB960 Instance 0 Camera Channel 1 - UB960 Instance 0 Camera Channel 2 - UB960 Instance 0 Camera Channel 3 - UB960 Instance 0 Camera Channel 4 - UB960 Instance 1 Camera Channel 5 - UB960 Instance 1 Camera Channel 6 - UB960 Instance 1 Camera Channel 7 - UB960 Instance 1.

On customer boards, this mapping maybe redefined

Parameters
chIdChannel ID of the camera to be configured
Returns
0 if success -1 otherwise