Closed bhemmerling closed 7 years ago
The return of get_parameter is missing the bounds which are used to check the parameter. With the additional False parameter, the return of get_parameter includes the bounds to the scan parameters. Then b can be fed back to set_parameter.
b = pv.get_parameter('VAET', 'detuning_secondary_scan', false)
When trying to set a scanning parameter in the parameter vault, it throws an error. Even when you just reset the parameter that you get with get_parameter. Here an example:
In [79]: b = pv.get_parameter('VAET', 'detuning_secondary_scan') In [80]: b Out[80]: (Value(-6.0, 'kHz'), Value(-4.0, 'kHz'), 9) In [81]: pv.set_parameter('VAET', 'detuning_secondary_scan', b) In [82]: pv.get_parameter('VAET', 'detuning_secondary_scan')
Error: (0) [ParameterVault] Remote Traceback (most recent call last): File "/home/lattice/.virtualenvs/labrad/local/lib/python2.7/site-packages/labrad/server.py", line 232, in request_handler result = yield setting.handleRequest(self, c.data, flat_data) File "/home/lattice/.virtualenvs/labrad/local/lib/python2.7/site-packages/labrad/decorators.py", line 175, in handleRequest return self.func(server, c, *data) File "parameter_vault.py", line 172, in getParameter result = self.check_parameter(key, result) File "parameter_vault.py", line 137, in check_parameter minim,maxim = item[0] File "/home/lattice/.virtualenvs/labrad/local/lib/python2.7/site-packages/labrad/units.py", line 477, in iter raise TypeError("'Value' object is not iterable") exceptions.TypeError: 'Value' object is not iterable