Skip to content

Commit

Permalink
Merge pull request #99 from alexsludds/patch-1
Browse files Browse the repository at this point in the history
Add marker configuration capabilities
  • Loading branch information
astafan8 authored Dec 7, 2021
2 parents 238f4f7 + 77b7cab commit a71565e
Showing 1 changed file with 29 additions and 1 deletion.
30 changes: 29 additions & 1 deletion qcodes_contrib_drivers/drivers/Keysight/SD_common/SD_AWG.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import logging
from functools import partial
from threading import RLock
from typing import List, Union, Optional, Dict
from typing import List, Union, Optional, Dict, Any
from qcodes import validators as validator

from .SD_Module import SD_Module, result_parser, keysightSD1, is_sd1_3x
Expand Down Expand Up @@ -317,6 +317,34 @@ def set_trigger_io(self, value: int, verbose: bool = False) -> None:
value_name = f'set io trigger output to {value}'
result_parser(result, value_name, verbose)

def set_marker_config(self, channel_number: int, markerMode: int,
trgPXImask: int, trgIOmask: int, markerValue: int, syncMode: int, length: int,
delay: int) -> Any:
"""
Configures the marker output from the trigger port
Args:
channel_number : trigger channel number
markerMode : 0 disabled, 1 on start event, 2 On first sample of waveform (after starting delay), 3 on every cycle
trgPXImask : Mask to select PXI triggers to use
trgIOmask : Mask to select front panel triggers to use
markerValue : 0 = marker signal is default low, pulses high. 1 = marker signal is default high, pulses low
syncMode : 0 = syncronized to CLKsys. 1 = syncronized to 10MHz clock
length : Marker pulse length (length * clock period * 5)
delay : Delay to add before pulse (delay * clock period * 5)
"""
result = self.awg.AWGqueueMarkerConfig(
nAWG=channel_number,
markerMode=markerMode,
trgPXImask=trgPXImask,
trgIOmask=trgIOmask,
value=markerValue,
syncMode=syncMode,
length=length,
delay=delay
)
return result

#
# The methods below are useful for controlling the device, but are not
# used for setting or getting parameters
Expand Down

0 comments on commit a71565e

Please sign in to comment.