pyopticon._system._data_logging_widget module

class pyopticon._system._data_logging_widget.DataLoggingWidget(parent_dashboard)

Bases: object

This widget allows a user to choose a data logging location and to start and stop data logging

Parameters:

parent (pyopticon.dashboard.Dashboard) – The dashboard to which this widget will be added.

get_frame()

Get the tkinter frame on which this object is drawn.

Returns:

The widget’s tkinter frame

Return type:

tkinter.Frame

_toggle_logging()

Toggle whether data logging is active. Do the actual logging at regular intervals. Enable/disable buttons accordingly. Some machinery to manage the corner case where you stop logging and then restart logging within a shorter timespan than the data logging interval.

_flip_interlock()

Necessary for toggle_logging to handle a corner case when logging is flipped on and off in quick succession.

_poll_loggable_data()

Prompt every widget to return all of the data that it wants logged. Format that data into .csv append it to the log file.

_choose_destination()

Open a dialog window to let the user select where the logfile should be saved.