Skip to content

Commit

Permalink
Merge pull request #960 from Bastian-Krause/bst/siglent
Browse files Browse the repository at this point in the history
driver/power/siglent: use backend function signatures expected by NetworkPowerDriver
  • Loading branch information
jluebbe authored Aug 22, 2022
2 parents 97dfce7 + 82ca4ab commit f30264b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions labgrid/driver/power/siglent.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,17 @@
import vxi11


def power_set(host, index, value):
def power_set(host, port, index, value):
assert port is None
index = int(index)
assert 1 <= index <= 2
value = "ON" if value else "OFF"
psu = vxi11.Instrument(host)
psu.write(f"OUTPUT CH{index},{value}")


def power_get(host, index):
def power_get(host, port, index):
assert port is None
index = int(index)
assert 1 <= index <= 2
psu = vxi11.Instrument(host)
Expand Down

0 comments on commit f30264b

Please sign in to comment.