photons.equipment.widgets.daq_counter module
Widget for a NIDAQ to counts pulse edges.
- class photons.equipment.widgets.daq_counter.DAQCounterWidget(connection, *, parent=None)[source]
Bases:
BaseEquipmentWidgetWidget for a NIDAQ to counts pulse edges.
- notification_handler(**kwargs)[source]
Handle a notification emitted by the NIDAQ Service.
- Return type:
- closeEvent(event)[source]
Override
QtWidgets.QWidget.closeEvent()to stop the QTimer and QThread.- Return type:
- class photons.equipment.widgets.daq_counter.CountEdgesWorker(connection, duration, edge, pfi, nsamples)[source]
Bases:
WorkerCount edges in a worker thread.
- class photons.equipment.widgets.daq_counter.CountEdgesThread(parent)[source]
Bases:
ThreadMoves a
Workerto a newQThread.Parameters
- worker
A
Workersubclass that has not been instantiated.
Example
See
Sleepfor an example of aThread.- error_handler(exception, traceback)[source]
If an exception is raised by the
Workerthen the default behaviour is to show the error message in acritical()dialog window.You can override this method to implement your own error handler.
- Return type:
Parameters
- exception
BaseException The exception instance
- traceback
traceback A traceback object.