From daaf6d93fd470d4e07a47ea97cef75d7c9056120 Mon Sep 17 00:00:00 2001 From: maclariz Date: Mon, 25 Sep 2023 16:01:06 +0100 Subject: [PATCH] Update hallEffect.py added a breakpoint to turn off live plotting --- src/HallPy_Teach/experiments/hallEffect.py | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/HallPy_Teach/experiments/hallEffect.py b/src/HallPy_Teach/experiments/hallEffect.py index bc5144a..7324106 100644 --- a/src/HallPy_Teach/experiments/hallEffect.py +++ b/src/HallPy_Teach/experiments/hallEffect.py @@ -176,7 +176,15 @@ def draw3DHELabGraphs(dataToGraph): plt.show() -def doExperiment(expInsts=None, emVolts=None, supVoltSweep=(), dataPointsPerSupSweep=0, measurementInterval=1, dataFileName=None): +def doExperiment( + expInsts=None, + emVolts=None, + supVoltSweep=(), + dataPointsPerSupSweep=0, + measurementInterval=1, + dataFileName=None, + plot=True +): """Function to perform the Hall Effect experiment For every emVolt from input the experiment will sweep across the hall bar supply voltages provided in the supVoltSweep @@ -374,7 +382,8 @@ def doExperiment(expInsts=None, emVolts=None, supVoltSweep=(), dataPointsPerSupS } clear_output(wait=True) - draw3DHELabGraphs(data) + if plot=True: + draw3DHELabGraphs(data) showLiveReadings(liveReading) curSupVolt += supVoltIncrement