3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.2 3.2.1 3.2.0 Korean English Chinese Czech Dutch French German Hungarian Italian Japanese Polish Portuguese Spanish
3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.2 3.2.1 3.2.0 Korean English Chinese Czech Dutch French German Hungarian Italian Japanese Polish Portuguese Spanish

set_mode_analog_input()

Definition

set_mode_analog_input(ch, mod)

Features

This function sets the channel mode of the controller analog input.

Parameters

Parameter Name

Data Type

Default Value

Description

ch

int

-

  • 1 : channel 1

  • 2 : channel 2

mod

int

-

analog io mode

  • DR_ANALOG_CURRENT: Current mode

  • DR_ANALOG_VOLTAGE: Voltage mode

Return

Value

Description

0

Success

Negative value

Failed

Exception

Exception

Description

DR_Error (DR_ERROR_TYPE)

Parameter data type error occurred

DR_Error (DR_ERROR_VALUE)

Parameter value is invalid

DR_Error (DR_ERROR_RUNTIME)

C extension module error occurred

DR_Error (DR_ERROR_STOP)

Program terminated forcefully

Example

Python
# Sets analog_input channel 1 to the current mode.
set_mode_analog_input(ch=1, mod=DR_ANALOG_CURRENT) 

# Sets analog_input channel 2 to the voltage mode.
set_mode_analog_input(ch=2, mod=DR_ANALOG_VOLTAGE)

Keyword

set / mode / analog / input / set_ / set_mode / analog_input / mode_analog_input