Qcodes example with Aviosys IP Power 9258S

[1]:
from qcodes_contrib_drivers.drivers.Aviosys.IP_Power_9258S import Aviosys_IP_Power_9258S

Initialize instrument

In order to initialize the instrument, we need to provide the http address, the login name and the login password.

[2]:
ip_power = Aviosys_IP_Power_9258S(name="IP Power 9258S", address='http://192.168.1.100',
                                  login_name='admin', login_password='12345678')
Connected to: Aviosys IP Power 9258S (serial:None, firmware:None) in 0.00s

Read the power status

We read the status of all sockets on the instrument.

[3]:
print(ip_power.A.power.label, ': ', ip_power.A.power.get(), ip_power.A.power.unit)
print(ip_power.B.power.label, ': ', ip_power.B.power.get(), ip_power.B.power.unit)
print(ip_power.C.power.label, ': ', ip_power.C.power.get(), ip_power.C.power.unit)
print(ip_power.D.power.label, ': ', ip_power.D.power.get(), ip_power.D.power.unit)
power A :  0
power B :  0
power C :  0
power D :  0

Set the power status

We set the status of two of the instrument sockets and repeat the status reading.

[4]:
ip_power.B.power.set(True)
ip_power.C.power.set(True)
[5]:
print(ip_power.A.power.label, ': ', ip_power.A.power.get(), ip_power.A.power.unit)
print(ip_power.B.power.label, ': ', ip_power.B.power.get(), ip_power.B.power.unit)
print(ip_power.C.power.label, ': ', ip_power.C.power.get(), ip_power.C.power.unit)
print(ip_power.D.power.label, ': ', ip_power.D.power.get(), ip_power.D.power.unit)
power A :  0
power B :  1
power C :  1
power D :  0

Turn of all sockets

[6]:
ip_power.A.power.set(False)
ip_power.B.power.set(False)
ip_power.C.power.set(False)
ip_power.D.power.set(False)

Close instrument

[7]:
ip_power.close()