balluff_ethernet_ip.py 386 B

1234567891011
  1. from cpppo.server.enip import client
  2. from cpppo.server.enip.getattr import attribute_operations
  3. HOST = "192.168.1.100"
  4. TAGS = ["@4/100/3"]
  5. with client.connector(host=HOST) as conn:
  6. for index, descr, op, reply, status, value in conn.synchronous(
  7. operations=attribute_operations(
  8. TAGS, route_path=[], send_path='' )):
  9. print(": %20s: %s" % (descr, value))