Commit e6a85ee5 authored by Matthieu Cattin's avatar Matthieu Cattin

Change parameter order for select_output_ch and set to 100mV range by default, comment out prints

parent 6d0bd8f1
......@@ -43,12 +43,12 @@ class CCalibr_box:
# Select which channel is connected to AWG
# others are set to Vref for the selected range
# !! ONLY FOR BOX V2 !!
def select_output_ch(self, out, channel):
def select_output_ch(self, channel, out='100mV'):
if channel >= 1 and channel <= 4:
value = ((channel-1)<<2)
else:
raise Exception('Invalid channel number, must be [1..4]!')
print hex(value)
#print hex(value)
if('10V' == out):
value += 0x3
elif('1V' == out):
......@@ -57,7 +57,7 @@ class CCalibr_box:
value += 0x0
else:
raise Exception('Invalid output selection!')
print hex(value)
#print hex(value)
self.cp210x.gpio_set(value)
def get_config(self):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment