The gpib module

This is a bus module intended to manage the Prologix GPIB-USB or GPIB-Ethernet controllers.

See documentation of buses for details of its behavior.


cmd_gpib.init_gpib(gpib_id, conf_string)[source]

Initialize a GPIB link.

conf_string must include:

  • bus: conf_string of the underlying bus module. For tcp and serial, the default tcp port or serial vendor and product id will be included if not present. For a USB adapter, a typical value could be serial()
  • dst_addr: GPIB address of the destination device
  • adapter_addr (defaults to 0): GPIB address of the adapter

Deinitialize and deregister GPIB link gpib_id.


Configure GPIB link gpib_id.


Invalidate configuration of GPIB link gpib_id.

cmd_gpib.write_gpib(gpib_id, data)[source]

Write data to GPIB link gpib_id.

cmd_gpib.wrnrd_until_gpib(gpib_id, data, eot='\\n', timeout='undef')[source]

Write and read data to and from GPIB link gpib_id.

cmd_gpib.expect_gpib(gpib_id, pattern, timeout='undef')[source]

Read data from GPIB link gpib_id until pattern is found or timeout.