mirror of
https://github.com/nqrduck/nqrduck-spectrometer.git
synced 2024-11-09 12:30:01 +00:00
Implemented change of duration length.
This commit is contained in:
parent
c3248aec0d
commit
8a1fdb99db
1 changed files with 7 additions and 0 deletions
|
@ -1,5 +1,8 @@
|
|||
import logging
|
||||
from collections import OrderedDict
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
class PulseSequence:
|
||||
"""A pulse sequence is a collection of events that are executed in a certain order."""
|
||||
def __init__(self, name) -> None:
|
||||
|
@ -20,6 +23,10 @@ class PulseSequence:
|
|||
def add_parameter(self, parameter) -> None:
|
||||
self.parameters.append(parameter)
|
||||
|
||||
def on_duration_changed(self, duration: float) -> None:
|
||||
logger.debug("Duration of event %s changed to %s", self.name, duration)
|
||||
self.duration = duration
|
||||
|
||||
def dump_sequence_data(self):
|
||||
"""Returns a dict with all the data in the pulse sequence"""
|
||||
data = {
|
||||
|
|
Loading…
Reference in a new issue