From af8cc28a57a144e338be822c2f9c43b730dfaba5 Mon Sep 17 00:00:00 2001 From: su530201 <olivier.kaufmann@umons.ac.be> Date: Thu, 19 Oct 2023 17:57:25 +0200 Subject: [PATCH] Updates config --- ohmpi/hardware_system.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ohmpi/hardware_system.py b/ohmpi/hardware_system.py index 1b49bb51..51a8440e 100644 --- a/ohmpi/hardware_system.py +++ b/ohmpi/hardware_system.py @@ -356,7 +356,7 @@ class OhmPiHardware: def _compute_tx_volt(self, pulse_duration=0.1, strategy='vmax', tx_volt=5., vab_max=voltage_max, iab_max=current_max, vmn_max=None, vmn_min=voltage_min, polarities=(1, -1), delay=0.05, - diff_vab_lim=2.5, n_steps=4): + p_max=None, diff_vab_lim=2.5, n_steps=4): # TODO: Optimise how to pass iab_max, vab_max, vmn_min """Estimates best Tx voltage based on different strategies. At first a half-cycle is made for a short duration with a fixed @@ -398,12 +398,12 @@ class OhmPiHardware: """ if self.tx.pwr.voltage_adjustable: + print(f'Vmn max: {vmn_max}') if vmn_max is None: vmn_max == self.rx._voltage_max / 1000. - p_max = vab_max * iab_max - - # define a sill - + print(f'Vmn max: {vmn_max}') + if p_max is None: + p_max = vab_max * iab_max # Set gain at min self.rx.reset_gain() -- GitLab