STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
lc_calibration_gui.LCPlotWindow Class Reference
Inheritance diagram for lc_calibration_gui.LCPlotWindow:
[legend]
Collaboration diagram for lc_calibration_gui.LCPlotWindow:
[legend]

Public Member Functions

 __init__ (self, int port=DEFAULT_PORT, str bind_address="0.0.0.0")
 start_receiver (self)
 on_sensor_data (self, dict header, List[dict] chunks)
 update_statistics (self)
 closeEvent (self, QtGui.QCloseEvent event)

Public Attributes

 port = port
 bind_address = bind_address
 window_seconds = DEFAULT_WINDOW_SECONDS
 test_start_time = None
int sample_count = 0
 stats_start_time = time.time()
 status_label = QtWidgets.QLabel("Starting...")
 chk_autoscale = QtWidgets.QCheckBox("Autoscale Y")
 plot = pg.PlotWidget()
 legend = self.plot.addLegend(labelTextSize="10pt")
dict chk = {}
dict curves = {}
 lbl_sps = QtWidgets.QLabel("Packets/sec: n/a")
dict per_lc = {}
 lbl_status = QtWidgets.QLabel("Idle")
 t0 = None
dict t = {conn: deque(maxlen=MAX_POINTS) for conn in SENSOR_TO_CONNECTOR}
dict v = {conn: deque(maxlen=MAX_POINTS) for conn in SENSOR_TO_CONNECTOR}
 last_sps_time = None
int last_sps_count = 0
bool autoscale = True
 timer = QtCore.QTimer(self)
 receiver = None
 stats_timer = QtCore.QTimer(self)
 update_statistics
 on_sensor_data

Protected Member Functions

 _hline (self)
 _on_toggle (self)
 _update_plot (self)
 _open_settings (self)
 _on_autoscale (self)
 _export_csv (self)

Protected Attributes

 _open_settings
 _export_csv
 _on_autoscale
 _on_toggle
 _update_plot
bool _plot_needs_update = False

Detailed Description

Definition at line 250 of file lc_calibration_gui.py.

Constructor & Destructor Documentation

◆ __init__()

lc_calibration_gui.LCPlotWindow.__init__ ( self,
int port = DEFAULT_PORT,
str bind_address = "0.0.0.0" )

Definition at line 251 of file lc_calibration_gui.py.

References __init__(), and array.resize().

Referenced by __init__().

Member Function Documentation

◆ _export_csv()

lc_calibration_gui.LCPlotWindow._export_csv ( self)
protected

◆ _hline()

lc_calibration_gui.LCPlotWindow._hline ( self)
protected

Definition at line 376 of file lc_calibration_gui.py.

◆ _on_autoscale()

lc_calibration_gui.LCPlotWindow._on_autoscale ( self)
protected

◆ _on_toggle()

lc_calibration_gui.LCPlotWindow._on_toggle ( self)
protected

Definition at line 402 of file lc_calibration_gui.py.

References gui.App._plot_needs_update, and _plot_needs_update.

◆ _open_settings()

lc_calibration_gui.LCPlotWindow._open_settings ( self)
protected

Definition at line 475 of file lc_calibration_gui.py.

◆ _update_plot()

◆ closeEvent()

lc_calibration_gui.LCPlotWindow.closeEvent ( self,
QtGui.QCloseEvent event )

◆ on_sensor_data()

◆ start_receiver()

◆ update_statistics()

lc_calibration_gui.LCPlotWindow.update_statistics ( self)

Member Data Documentation

◆ _export_csv

lc_calibration_gui.LCPlotWindow._export_csv
protected

Definition at line 279 of file lc_calibration_gui.py.

◆ _on_autoscale

lc_calibration_gui.LCPlotWindow._on_autoscale
protected

Definition at line 284 of file lc_calibration_gui.py.

◆ _on_toggle

lc_calibration_gui.LCPlotWindow._on_toggle
protected

Definition at line 318 of file lc_calibration_gui.py.

◆ _open_settings

lc_calibration_gui.LCPlotWindow._open_settings
protected

Definition at line 275 of file lc_calibration_gui.py.

◆ _plot_needs_update

bool lc_calibration_gui.LCPlotWindow._plot_needs_update = False
protected

Definition at line 365 of file lc_calibration_gui.py.

Referenced by _on_autoscale(), _on_toggle(), _update_plot(), and on_sensor_data().

◆ _update_plot

lc_calibration_gui.LCPlotWindow._update_plot
protected

Definition at line 363 of file lc_calibration_gui.py.

Referenced by _on_autoscale().

◆ autoscale

bool lc_calibration_gui.LCPlotWindow.autoscale = True

Definition at line 359 of file lc_calibration_gui.py.

Referenced by _on_autoscale(), and _update_plot().

◆ bind_address

◆ chk

dict lc_calibration_gui.LCPlotWindow.chk = {}

Definition at line 311 of file lc_calibration_gui.py.

Referenced by _update_plot().

◆ chk_autoscale

lc_calibration_gui.LCPlotWindow.chk_autoscale = QtWidgets.QCheckBox("Autoscale Y")

Definition at line 282 of file lc_calibration_gui.py.

Referenced by _on_autoscale().

◆ curves

◆ last_sps_count

int lc_calibration_gui.LCPlotWindow.last_sps_count = 0

Definition at line 358 of file lc_calibration_gui.py.

◆ last_sps_time

lc_calibration_gui.LCPlotWindow.last_sps_time = None

◆ lbl_sps

lc_calibration_gui.LCPlotWindow.lbl_sps = QtWidgets.QLabel("Packets/sec: n/a")

Definition at line 329 of file lc_calibration_gui.py.

Referenced by update_statistics().

◆ lbl_status

lc_calibration_gui.LCPlotWindow.lbl_status = QtWidgets.QLabel("Idle")

◆ legend

lc_calibration_gui.LCPlotWindow.legend = self.plot.addLegend(labelTextSize="10pt")

◆ on_sensor_data

lc_calibration_gui.LCPlotWindow.on_sensor_data

Definition at line 384 of file lc_calibration_gui.py.

◆ per_lc

dict lc_calibration_gui.LCPlotWindow.per_lc = {}

Definition at line 335 of file lc_calibration_gui.py.

Referenced by _update_plot().

◆ plot

lc_calibration_gui.LCPlotWindow.plot = pg.PlotWidget()

Definition at line 294 of file lc_calibration_gui.py.

Referenced by _update_plot().

◆ port

◆ receiver

◆ sample_count

int lc_calibration_gui.LCPlotWindow.sample_count = 0

Definition at line 260 of file lc_calibration_gui.py.

Referenced by on_sensor_data().

◆ stats_start_time

◆ stats_timer

lc_calibration_gui.LCPlotWindow.stats_timer = QtCore.QTimer(self)

Definition at line 372 of file lc_calibration_gui.py.

◆ status_label

◆ t

◆ t0

lc_calibration_gui.LCPlotWindow.t0 = None

Definition at line 352 of file lc_calibration_gui.py.

◆ test_start_time

lc_calibration_gui.LCPlotWindow.test_start_time = None

Definition at line 259 of file lc_calibration_gui.py.

Referenced by _export_csv().

◆ timer

lc_calibration_gui.LCPlotWindow.timer = QtCore.QTimer(self)

Definition at line 362 of file lc_calibration_gui.py.

◆ update_statistics

lc_calibration_gui.LCPlotWindow.update_statistics

◆ v

◆ window_seconds


The documentation for this class was generated from the following file: