Commit a8a0c4e0 authored by Oscar Gargiulo's avatar Oscar Gargiulo
Browse files

let's pray it works forgot what i changed anyway

parent 95279ef0
...@@ -37,4 +37,5 @@ IPList = {'SCOPE': '192.168.0.99', ...@@ -37,4 +37,5 @@ IPList = {'SCOPE': '192.168.0.99',
'SA2': '192.168.0.140', 'SA2': '192.168.0.140',
'XXF1': '138.232.183.115', # Running on Windows machine 'XXF1': '138.232.183.115', # Running on Windows machine
'NI6020': '138.232.183.115' # Running on Windows machine 'NI6020': '138.232.183.115' # Running on Windows machine
#'DA': '192.168.0.119' #does not work with vxi, use socets instead
} }
# -*- coding: utf-8 -*-
"""
Created on Mon May 6 14:01:41 2019
@author: User
"""
import vxi11
class dig_at_mc(vxi11.Instrument):
def __init__(self,ip='192.168.0.119'):
super(dig_at_mc, self).__init__(ip)
def com(self, command, arg="?"):
"""Function to communicate with the device. Gives the current status
if no arg is given
Parameters
-----------
command : str
Command/Query string for device
arg : str, int, float
Argument for command
"""
if arg == "?":
try:
return float(self.ask("{}?\n".format(command)))
except:
return self.ask("{}?\n".format(command))
else:
self.write("{} {}\n".format(command, arg))
return None
'''
def reset(self):
self.com('*RST', '')
def connect(self,board_num=1):
'''
\ No newline at end of file
This diff is collapsed.
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