Closed mvbnano closed 6 years ago
When using the obis laser, the com port used for USB communication is hard coded into the hardware module.
In on_activate.
on_activate
Obis hardware module.
You cannot guarantee that the obis will always connect to COM3
COM3
Read which com port to connect to from the config file.
def on_activate(self): """ Activate module. """ self.obis = serial.Serial('COM3', timeout=1) connected = self.connect_laser() if not connected: self.log.error('Laser does not seem to be connected.') return -1 else: self._model_name = self._communicate('SYST:INF:MOD?') return 0
branch dev_obis_laser restarted for this issue
dev_obis_laser
this fix is complete, however, i'd like to have another look through obis before putting another pull request in
PR submitted.
What is affected by this bug?
When using the obis laser, the com port used for USB communication is hard coded into the hardware module.
When does this occur?
In
on_activate
.Where on the platform does it happen?
Obis hardware module.
How do we replicate the issue?
You cannot guarantee that the obis will always connect to
COM3
Expected behavior (i.e. solution)
Read which com port to connect to from the config file.
Other Comments