Classes | Public Member Functions | Protected Member Functions | Private Member Functions | Static Private Attributes | List of all members
XSHPulser Class Reference

My pulser driver. More...

#include <pulserdriversh.h>

Inheritance diagram for XSHPulser:
Inheritance graph
[legend]

Classes

struct  Payload
 

Public Member Functions

 XSHPulser (const char *name, bool runtime, Transaction &tr_meas, const shared_ptr< XMeasure > &meas)
 
virtual double resolution () const
 time resolution [ms]
 
- Public Member Functions inherited from XCharDeviceDriver< XPulser >
 XCharDeviceDriver (const char *name, bool runtime, Transaction &tr_meas, const shared_ptr< XMeasure > &meas)
 
- Public Member Functions inherited from XPulser
 XPulser (const char *name, bool runtime, Transaction &tr_meas, const shared_ptr< XMeasure > &meas)
 
virtual void showForms ()
 shows all forms belonging to driver
 
const shared_ptr< XBoolNode > & output () const
 
const shared_ptr< XComboNode > & combMode () const
 
const shared_ptr< XComboNode > & rtMode () const
 
const shared_ptr< XComboNode > & numPhaseCycle () const
 How many cycles in phase cycling.
 
const shared_ptr< XDoubleNode > & rtime () const
 Repetition/Rest Time [ms].
 
const shared_ptr< XDoubleNode > & tau () const
 [us]
 
const shared_ptr< XDoubleNode > & combPW () const
 PulseWidths [us].
 
const shared_ptr< XDoubleNode > & pw1 () const
 PulseWidths [us].
 
const shared_ptr< XDoubleNode > & pw2 () const
 PulseWidths [us].
 
const shared_ptr< XDoubleNode > & combPT () const
 Comb pulse periodic term [us].
 
const shared_ptr< XDoubleNode > & combP1 () const
 P1 and P1 alternative.
 
const shared_ptr< XDoubleNode > & combP1Alt () const
 P1 and P1 alternative.
 
const shared_ptr< XDoubleNode > & aswSetup () const
 Analog switch setting, setup(proceeding) time before the first spin echo.
 
const shared_ptr< XDoubleNode > & aswHold () const
 Analog switch setting, hold time after the last spin echo.
 
const shared_ptr< XDoubleNode > & altSep () const
 Separation time in DSO record, cause a shift of trigger of DSO in alternatively mode.
 
const shared_ptr< XDoubleNode > & g2Setup () const
 Setup time of pre-gating port and QPSK.
 
const shared_ptr< XUIntNode > & combNum () const
 

of comb pulses


 
const shared_ptr< XUIntNode > & echoNum () const
 

of Spin echoes (i.e. pi pulses)


 
const shared_ptr< XBoolNode > & drivenEquilibrium () const
 polarize spins after pulse sequence or not
 
const shared_ptr< XDoubleNode > & combOffRes () const
 off-resonance comb pulses
 
const shared_ptr< XComboNode > & combFunc () const
 Pulse Modulation.
 
const shared_ptr< XComboNode > & p1Func () const
 Pulse Modulation.
 
const shared_ptr< XComboNode > & p2Func () const
 Pulse Modulation.
 
const shared_ptr< XDoubleNode > & combLevel () const
 [dB], Pulse Modulation
 
const shared_ptr< XDoubleNode > & p1Level () const
 [dB], Pulse Modulation
 
const shared_ptr< XDoubleNode > & p2Level () const
 [dB], Pulse Modulation
 
const shared_ptr< XDoubleNode > & masterLevel () const
 [dB]
 
const shared_ptr< XBoolNode > & induceEmission () const
 
const shared_ptr< XDoubleNode > & induceEmissionPhase () const
 
const shared_ptr< XDoubleNode > & qamOffset1 () const
 
const shared_ptr< XDoubleNode > & qamOffset2 () const
 [F.S.]
 
const shared_ptr< XDoubleNode > & qamLevel1 () const
 
const shared_ptr< XDoubleNode > & qamLevel2 () const
 < Quadrature Amplitude Modulation. Amplitude compensation factor.
 
const shared_ptr< XDoubleNode > & qamDelay1 () const
 
const shared_ptr< XDoubleNode > & qamDelay2 () const
 < Delaying compensation [us].
 
const shared_ptr< XDoubleNode > & difFreq () const
 [MHz]
 
const shared_ptr< XDoubleNode > & qswDelay () const
 Q-switch setting, period after the end-edge of pulses [us].
 
const shared_ptr< XDoubleNode > & qswWidth () const
 Q-switch setting, width of suppression [us].
 
const shared_ptr< XDoubleNode > & qswSoftSWOff () const
 Q-switch setting, second pulse [us].
 
const shared_ptr< XBoolNode > & qswPiPulseOnly () const
 Q-switch setting, use QSW only for pi pulses.
 
const shared_ptr< XBoolNode > & invertPhase () const
 
const shared_ptr< XBoolNode > & conserveStEPhase () const
 
const shared_ptr< XComboNode > & portSel (unsigned int port) const
 
const shared_ptr< XBoolNode > & pulseAnalyzerMode () const
 
const shared_ptr< XDoubleNode > & paPulseRept () const
 
const shared_ptr< XDoubleNode > & paPulseBW () const
 
const shared_ptr< XUIntNode > & firstPhase () const
 0-3, selects the first phase of QPSK.
 
- Public Member Functions inherited from XPrimaryDriver
 XPrimaryDriver (const char *name, bool runtime, Transaction &tr_meas, const shared_ptr< XMeasure > &meas)
 
- Public Member Functions inherited from XDriver
 XDriver (const char *name, bool runtime, Transaction &tr_meas, const shared_ptr< XMeasure > &meas)
 
- Public Member Functions inherited from XNode
 XNode (const char *name, bool runtime=false)
 
template<class T >
shared_ptr< T > create (const char *name)
 
template<class T , typename... Args>
shared_ptr< T > create (const char *name, bool runtime, Args &&...args)
 
template<class T >
shared_ptr< T > create (Transaction &tr, const char *name)
 
template<class T , typename... Args>
shared_ptr< T > create (Transaction &tr, const char *name, bool runtime, Args &&...args)
 
XString getName () const
 
virtual XString getLabel () const
 
XString getTypename () const
 
shared_ptr< XNodegetChild (const XString &var) const
 
shared_ptr< XNodegetParent () const
 
void setUIEnabled (bool v)
 Enables/disables controls over scripting/GUI.
 
void disable ()
 Disables all scripting/GUI operations on this node hereafter.
 
- Public Member Functions inherited from Transactional::Node< XNode >
bool insert (Transaction< XNode > &tr, const shared_ptr< XNode > &var, bool online_after_insertion=false)
 
void insert (const shared_ptr< XNode > &var)
 
bool release (Transaction< XNode > &tr, const shared_ptr< XNode > &var)
 
void release (const shared_ptr< XNode > &var)
 
void releaseAll ()
 
bool swap (Transaction< XNode > &tr, const shared_ptr< XNode > &x, const shared_ptr< XNode > &y)
 
void swap (const shared_ptr< XNode > &x, const shared_ptr< XNode > &y)
 
XNodeupperNode (Snapshot< XNode > &shot)
 Finds the parent node in shot.
 
Snapshot< XNodeiterate_commit (Closure)
 
Snapshot< XNodeiterate_commit_if (Closure)
 
void iterate_commit_while (Closure)
 
void print_ () const
 
 Node (const Node &)=delete
 
Nodeoperator= (const Node &)=delete
 

Protected Member Functions

virtual void changeOutput (const Snapshot &shot, bool output, unsigned int blankpattern)
 Sends patterns to pulser or turns off.
 
virtual void createNativePatterns (Transaction &tr)
 Converts RelPatList to native patterns.
 
virtual double resolutionQAM () const
 
virtual double minPulseWidth () const
 minimum period of pulses [ms]
 
virtual bool hasQAMPorts () const
 existence of AO ports.
 
- Protected Member Functions inherited from XCharDeviceDriver< XPulser >
const shared_ptr
< XCharInterface > & 
interface () const
 
virtual void open () throw (XKameError &)
 Be called just after opening interface. Call start() inside this routine appropriately.
 
virtual void close () throw (XKameError &)
 Be called during stopping driver. Call interface()->stop() inside this routine.
 
void onOpen (const Snapshot &shot, XInterface *)
 
void onClose (const Snapshot &shot, XInterface *)
 
virtual void closeInterface ()
 
- Protected Member Functions inherited from XPulser
unsigned int selectedPorts (const Snapshot &shot, int func) const
 
virtual void start ()
 Starts up your threads, connects GUI, and activates signals.
 
virtual void stop ()
 
virtual void analyzeRaw (RawDataReader &reader, Transaction &tr) throw (XRecordError&)
 
virtual void visualize (const Snapshot &shot)
 
tpulsefunc pulseFunc (int func_no) const
 
int pulseFuncNo (const XString &str) const
 
- Protected Member Functions inherited from XPrimaryDriver
void finishWritingRaw (const shared_ptr< const RawData > &rawdata, const XTime &time_awared, const XTime &time_recorded)
 
- Protected Member Functions inherited from XDriver
void record (Transaction &tr, const XTime &time_awared, const XTime &time_recorded)
 

Private Member Functions

int setAUX2DA (Transaction &tr, double volt, int addr)
 
int insertPreamble (Transaction &tr, uint16_t startpattern)
 
int finishPulse (Transaction &tr)
 
int pulseAdd (Transaction &tr, uint64_t term, uint32_t pattern, bool firsttime, bool dryrun)
 

Static Private Attributes

static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_END = 0
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_COPY_HBURST = 1
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_LSET_LONG = 2
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_LSET_START = 0x10
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_LSET_END = 0xffu
 
static const unsigned char PATTERN_ZIPPED_COMMAND_END = 0
 
static const unsigned char PATTERN_ZIPPED_COMMAND_WAIT = 1
 
static const unsigned char PATTERN_ZIPPED_COMMAND_WAIT_LONG = 2
 
static const unsigned char PATTERN_ZIPPED_COMMAND_WAIT_LONG_LONG = 3
 
static const unsigned char PATTERN_ZIPPED_COMMAND_AUX1 = 4
 
static const unsigned char PATTERN_ZIPPED_COMMAND_AUX3 = 5
 
static const unsigned char PATTERN_ZIPPED_COMMAND_AUX2_DA = 6
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DO = 7
 
static const unsigned char PATTERN_ZIPPED_COMMAND_LOOP = 8
 
static const unsigned char PATTERN_ZIPPED_COMMAND_LOOP_INF = 9
 
static const unsigned char PATTERN_ZIPPED_COMMAND_BREAKPOINT = 0xa
 
static const unsigned char PATTERN_ZIPPED_COMMAND_PULSEON = 0xb
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_SET = 0xc
 
static const unsigned char PATTERN_ZIPPED_COMMAND_DMA_HBURST = 0xd
 
static const unsigned char PATTERN_ZIPPED_COMMAND_SET_DA_TUNE_OFFSET = 0xe
 
static const unsigned char PATTERN_ZIPPED_COMMAND_SET_DA_TUNE_LEVEL = 0xf
 
static const unsigned char PATTERN_ZIPPED_COMMAND_SET_DA_TUNE_DELAY = 0x10
 

Additional Inherited Members

- Public Types inherited from XPulser
enum  { N_MODE_NMR_PULSER = 0, N_MODE_PULSE_ANALYZER = 1 }
 driver specific part below More...
 
enum  { N_COMB_MODE_OFF = 0, N_COMB_MODE_ON = 1, N_COMB_MODE_P1_ALT = 2, N_COMB_MODE_COMB_ALT = 3 }
 
enum  { N_RT_MODE_FIXREP = 0, N_RT_MODE_FIXREST = 1 }
 
enum  { MAX_NUM_PHASE_CYCLE = 16 }
 
enum  { NUM_DO_PORTS = 16 }
 

of digital-pulse ports.


 
enum  {
  PAT_DO_MASK = (1 << NUM_DO_PORTS) - 1, PAT_QAM_PHASE = (1 << NUM_DO_PORTS), PAT_QAM_PHASE_MASK = PAT_QAM_PHASE * 3, PAT_QAM_PULSE_IDX = PAT_QAM_PHASE * 4,
  PAT_QAM_PULSE_IDX_P1 = PAT_QAM_PULSE_IDX * 1, PAT_QAM_PULSE_IDX_P2 = PAT_QAM_PULSE_IDX * 2, PAT_QAM_PULSE_IDX_PCOMB = PAT_QAM_PULSE_IDX * 3, PAT_QAM_PULSE_IDX_INDUCE_EMISSION = PAT_QAM_PULSE_IDX * 4,
  PAT_QAM_PULSE_IDX_MASK = PAT_QAM_PULSE_IDX * 15, PAT_QAM_MASK = PAT_QAM_PHASE_MASK | PAT_QAM_PULSE_IDX_MASK
}
 for RelPatList patterns. More...
 
- Static Public Member Functions inherited from XNode
template<class T__ >
static shared_ptr< T__ > createOrphan (const char *name)
 
template<class T__ , typename... Args_>
static shared_ptr< T__ > createOrphan (const char *name, bool runtime, Args_ &&...args)
 
- Protected Types inherited from XPulser
enum  {
  PORTSEL_UNSEL = -1, PORTSEL_GATE = 0, PORTSEL_PREGATE = 1, PORTSEL_GATE3 = 2,
  PORTSEL_TRIG1 = 3, PORTSEL_TRIG2 = 4, PORTSEL_ASW = 5, PORTSEL_QSW = 6,
  PORTSEL_PULSE1 = 7, PORTSEL_PULSE2 = 8, PORTSEL_COMB = 9, PORTSEL_COMB_FM = 10,
  PORTSEL_QPSK_A = 11, PORTSEL_QPSK_B = 12, PORTSEL_QPSK_OLD_NONINV = 13, PORTSEL_QPSK_OLD_INV = 14,
  PORTSEL_QPSK_OLD_PSGATE = 15, PORTSEL_PULSE_ANALYZER_GATE = 16
}
 indice for return values of portSel().
 
typedef FFT::twindowfunc tpulsefunc
 

Detailed Description

My pulser driver.

Definition at line 19 of file pulserdriversh.h.

Member Function Documentation

int XSHPulser::pulseAdd ( Transaction tr,
uint64_t  term,
uint32_t  pattern,
bool  firsttime,
bool  dryrun 
)
private

Add 1 pulse pattern

Parameters
terma period to next pattern
patterna pattern for digital, to appear

Definition at line 249 of file pulserdriversh.cpp.

References resolution().

Referenced by createNativePatterns().


The documentation for this class was generated from the following files:

Generated for KAME4 by  doxygen 1.8.3