less than 1 minute read

PID Logger
PID Logger (PLC Data Logging).

PID Logger Instantiation Example

import pypidtune

pid_logger = pypidtune.PIDLogger(
    comm_type="opc",
    init_logix_ip_address="192.168.1.100",
    init_logix_slot=1,
    init_opc_address="opc.tcp://localhost:4840",
    init_sp_tag="SP_Tag",
    init_pv_tag="PV_Tag",
    init_cv_tag="CV_Tag",
)
pid_logger.root.mainloop()

In this example:

  • comm_type is set to ‘opc’, specifying the communication type.
  • init_logix_ip_address is set to ‘192.168.1.100’, initializing the IP address for Logix communication.
  • init_logix_slot is set to 1, setting the initial slot for Logix communication.
  • init_opc_address is set to ‘opc.tcp://localhost:4840’, initializing the address for OPC communication.
  • init_sp_tag, init_pv_tag, and init_cv_tag are initialized with specific tags for setpoint, process variable, and control variable.