Skip to main content
Skip table of contents

get_modbus_inputs_list(iobus_list)

기능

Modbus Slave 장치의 Register Type의 복수 개 신호를 읽어오기 위한 명령어입니다.

인수

인수명자료형기본값설명

iobus_list

list(string)

-

modbus input 이름 list (TP에서 설정)

signal type이 아래의 경우에만 사용가능

  • DR_MODBUS_REG_INPUT
  • DR_MODBUS_REG_OUTPUT

리턴

설명

res

읽은 값의 갯수

val_list

한번에 읽은 복수 개의 신호 값의 list

예외

예외설명

DR_Error (DR_ERROR_TYPE)

인수들의 데이터형 오류 시

DR_Error (DR_ERROR_VALUE)

인수의 값이 유효하지 않을 시

DR_Error (DR_ERROR_RUNTIME)

C Extension 모듈 에러 발생 시

DR_Error (DR_ERROR_STOP)

프로그램 강제 종료 시

예제

PY
# Modbus Register I/O 입력 신호 ”Holding1”은 1234, ”Input1”은 567, ”Holding2”은 9876 인 경우
res, val_list = get_modbus_inputs_list(iobus_list=[“Holding1", "Input1", "Holding2”])
	  #res 기대값 = 3
	  #val_list 기대값 = [1234, 567, 9876]
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.