Skip to content

Commit

Permalink
fix: Zero q-component for rectangular readout pulse
Browse files Browse the repository at this point in the history
  • Loading branch information
stavros11 committed Feb 19, 2024
1 parent 1affed0 commit 4509421
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/qibolab/instruments/qm/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,12 +312,12 @@ def register_waveform(self, pulse, mode="i"):
serial (str): String with a serialization of the waveform.
Used as key to identify the waveform in the config.
"""
# Maybe need to force zero q waveforms
# if pulse.type.name == "READOUT" and mode == "q":
# serial = "zero_wf"
# if serial not in self.waveforms:
# self.waveforms[serial] = {"type": "constant", "sample": 0.0}
if isinstance(pulse.shape, Rectangular):
if pulse.type is PulseType.READOUT and mode == "q":
# Force zero q waveforms for readout
serial = "zero_wf"
if serial not in self.waveforms:
self.waveforms[serial] = {"type": "constant", "sample": 0.0}
elif isinstance(pulse.shape, Rectangular):
serial = f"constant_wf{pulse.amplitude}"
if serial not in self.waveforms:
self.waveforms[serial] = {"type": "constant", "sample": pulse.amplitude}
Expand Down

0 comments on commit 4509421

Please sign in to comment.