feat: 초기 프로젝트 구조 추가
This commit is contained in:
14
test.py
Normal file
14
test.py
Normal file
@@ -0,0 +1,14 @@
|
||||
import re
|
||||
from pymelsec import Type3E
|
||||
from pymelsec.constants import DT
|
||||
|
||||
plc = Type3E(host="192.168.3.39", port=5010, plc_type="Q")
|
||||
plc.connect("192.168.3.39", 5010)
|
||||
|
||||
# D500에 값 전송
|
||||
plc.batch_write(ref_device="B5F", values=[1], data_type=DT.BIT)
|
||||
|
||||
re = plc.batch_read(ref_device="B52", read_size=1, data_type=DT.BIT)
|
||||
print(re)
|
||||
|
||||
plc.close()
|
||||
Reference in New Issue
Block a user