SsiSetCorrection


Function

Set the correction value.

Format

Ret = SsiSetCorrection ( Id , ChannelNo , CorrectionSlope , CorrectionOffset )

Parameters

Id [ C, C++: short ] [ Python: ctypes.c_short ]
Specify the device ID retrieved from SsiInit.

ChannelNo [ C, C++: short ] [ Python: ctypes.c_short ]
Specify the channel number.

CorrectionSlope [ C, C++: float ] [ Python: ctypes.c_float ]
Specify the correction slope.

Definition

Slope Value

Description

CSSI_CORRECTION_SLOPE_CH0_INSTALLATION_0

1.013

Horizontal installation: CH0

CSSI_CORRECTION_SLOPE_CH0_INSTALLATION_1

0.998

Vertical installation (Vertically placed): CH0

CSSI_CORRECTION_SLOPE_CH0_INSTALLATION_2

0.999

Vertical installation (Horizontally placed): CH0

CSSI_CORRECTION_SLOPE_CH1_INSTALLATION_0

1.005

Horizontal installation: CH1

CSSI_CORRECTION_SLOPE_CH1_INSTALLATION_1

1.008

Vertical installation (Vertically placed): CH1

CSSI_CORRECTION_SLOPE_CH1_INSTALLATION_2

1.009

Vertical installation (Horizontally placed): CH1

CSSI_CORRECTION_SLOPE_CH2_INSTALLATION_0

1.004

Horizontal installation: CH2

CSSI_CORRECTION_SLOPE_CH2_INSTALLATION_1

1.010

Vertical installation (Vertically placed): CH2

CSSI_CORRECTION_SLOPE_CH2_INSTALLATION_2

1.002

Vertical installation (Horizontally placed): CH2

CSSI_CORRECTION_SLOPE_CH3_INSTALLATION_0

1.005

Horizontal installation: CH3

CSSI_CORRECTION_SLOPE_CH3_INSTALLATION_1

0.998

Vertical installation (Vertically placed): CH3

CSSI_CORRECTION_SLOPE_CH3_INSTALLATION_2

1.003

Vertical installation (Horizontally placed): CH3

CorrectionOffset [ C, C++: float ] [ Python: ctypes.c_float ]
Specify the correction offset.

Definition

Offset Value

Description

CSSI_CORRECTION_OFFSET_CH0_INSTALLATION_0

3.019

Horizontal installation: CH0

CSSI_CORRECTION_OFFSET_CH0_INSTALLATION_1

2.484

Vertical installation (Vertically placed): CH0

CSSI_CORRECTION_OFFSET_CH0_INSTALLATION_2

2.415

Vertical installation (Horizontally placed): CH0

CSSI_CORRECTION_OFFSET_CH1_INSTALLATION_0

2.756

Horizontal installation: CH1

CSSI_CORRECTION_OFFSET_CH1_INSTALLATION_1

2.899

Vertical installation (Vertically placed): CH1

CSSI_CORRECTION_OFFSET_CH1_INSTALLATION_2

2.711

Vertical installation (Horizontally placed): CH1

CSSI_CORRECTION_OFFSET_CH2_INSTALLATION_0

2.462

Horizontal installation: CH2

CSSI_CORRECTION_OFFSET_CH2_INSTALLATION_1

2.501

Vertical installation (Vertically placed): CH2

CSSI_CORRECTION_OFFSET_CH2_INSTALLATION_2

2.384

Vertical installation (Horizontally placed): CH2

CSSI_CORRECTION_OFFSET_CH3_INSTALLATION_0

2.386

Horizontal installation: CH3

CSSI_CORRECTION_OFFSET_CH3_INSTALLATION_1

2.132

Vertical installation (Vertically placed): CH3

CSSI_CORRECTION_OFFSET_CH3_INSTALLATION_2

2.358

Vertical installation (Horizontally placed): CH3

Return Value

Ret [ C, C++: long ] [ Python: ctypes.c_long ]

Definition

Value

[Dec]

Description

SSI_ERR_SUCCESS

0

Succeeded

SSI_ERR_DLL_INVALID_ID

10001

Invalid device id.

SSI_ERR_DLL_CALL_DRIVER

10002

Can not call driver (ioctl failed).

SSI_ERR_DLL_BUFF_ADDRESS

10100

Invalid data buffer address.

SSI_ERR_SYS_NOT_SUPPORTED

20001

Function is not supported for this device.

SSI_ERR_SYS_CH_NO

20100

Channel No. is outside the setting range.

SSI_ERR_SYS_DISABLE_CH

20104

Disabled channel number.

SSI_ERR_SYS_CORRECTION_VALUE

20106

Correction value is outside of the setting range.

The others (See also: Details of Error Code)

Remarks

Set the correction value.
It is fixed the combinations that can be set for CorrectionSlope and CorrectionOffset.

Example

Set the correction value for 1ch.

C, C++

long Ret;
Ret = SsiSetCorrection(Id, 1 , CSSI_CORRECTION_SLOPE_CH1_INSTALLATION_0, CSSI_CORRECTION_OFFSET_CH1_INSTALLATION_0);
 

Python

Ret = ctypes.c_long()
Ret = cssi.SsiSetCorrection(Id, 1 , cssi.CSSI_CORRECTION_SLOPE_CH1_INSTALLATION_0, cssi.CSSI_CORRECTION_OFFSET_CH1_INSTALLATION_0)

 

See Also

SsiGetCorrection