Platform/ECM3532/M3/framework/sensor_mgr/src/sensor.c
/**
 * Sal Ioctl call
 *
 * @param sHandle  Sensor driver handle
 * @param iCmd IOCTL command
 * @param iSensor Sensor type
 * @param vPtr pointer to data for IOCTL command
 *
 * @return 0 on success, negative error code on failure.
 */
Sal Ioctl call
@param sHandle  Sensor driver handle
@param iCmd IOCTL command
@param iSensor Sensor type
@param vPtr pointer to data for IOCTL command

@return 0 on success, negative error code on failure.
Sal Ioctl call @param sHandle Sensor driver handle @param iCmd IOCTL command @param iSensor Sensor type @param vPtr pointer to data for IOCTL command @return 0 on success negative error code on failure .
int32_t SalSensorIoctl(tSDrvHandle sDrvHandle, tSensorType iSensor,
                    tSensorIOCTL iCmd, void *vPtr)
{
    int32_t ret = -EINVAL;
    uint8_t ui8Idx;
    tDrvHandle vDrvHandle;
    if ((sDrvHandle != INVALID_HANDLE) && (sDrvHandle < DRIVER_MAX_CNT))
    {
        vDrvHandle = sHandleMapList[sDrvHandle].vDrvHandle;
        if (vDrvHandle != INVALID_HANDLE)
        {
            ui8Idx = sHandleMapList[sDrvHandle].ui8SensorDevIndex;
            ret = sSensorDevList[ui8Idx].sDops->
                    DrvIoctl(vDrvHandle, iSensor, iCmd, vPtr);
        }
        else
        {
            ecm35xx_printf("SM IOCTL: Error Invalid Handle\r\n");
        }
    }
    return ret;
}
int32_t SalSensorIoctl ( tSDrvHandle sDrvHandle , tSensorType iSensor , tSensorIOCTL iCmd , void * vPtr ) { int32_t ret = - EINVAL ; uint8_t ui8Idx ; tDrvHandle vDrvHandle ; if ( ( sDrvHandle != INVALID_HANDLE ) && ( sDrvHandle < DRIVER_MAX_CNT ) ) { vDrvHandle = sHandleMapList [ sDrvHandle ] . vDrvHandle ; if ( vDrvHandle != INVALID_HANDLE ) { ui8Idx = sHandleMapList [ sDrvHandle ] . ui8SensorDevIndex ; ret = sSensorDevList [ ui8Idx ] . sDops -> DrvIoctl ( vDrvHandle , iSensor , iCmd , vPtr ) ; } else { ecm35xx_printf ( " \r \n " ) ; } } return ret ; }
Sal Ioctl call
 @param sHandle  Sensor driver handle
 @param iCmd IOCTL command
 @param iSensor Sensor type
 @param vPtr pointer to data for IOCTL command
Sal Ioctl call @param sHandle Sensor driver handle @param iCmd IOCTL command @param iSensor Sensor type @param vPtr pointer to data for IOCTL command