Keywords
Keywords are words reserved by PPL for special purposes and must not be used as identifiers or pulse command names.
asm
Reserved for future use.
bool
Use bool and the literals false and true to perform Boolean logic tests.
The bool keyword represents a type that can take only the value false or true. The keywords false and true are Boolean literals with predefined values. false is numerically zero and true is numerically one. These Boolean literals are rvalues; you cannot make an assignment to them.
You can convert an bool rvalue to an rvalue that is int type. The numerical conversion sets false to zero and true becomes one.
See also
Ppl Const
Use the const modifier to make a variable value unmodifiable.
else
Supplementary keyword used in conditional operator
See also:
end
Supplementary keyword used to define the end of action of statements.
See also
false
Boolean value false.
See also
frequency
Use the frequency type specifier to define an identifier to be a frequency type.
Frequency identifier can be assigned by frequency constant or compared with frequency only.
Frequency type identifier can be added or subtracted. Frequency can be multiplied and divided by real or int.
Example:
frequency f f = 10MHz f = f-0.5kHz
Legend: PPL keywords; PPL pulse commands; comments.
See also
if-else-end
Use if to implement a conditional statement. The condition expression must be bool type. Otherwise, the condition is ill-formed.
When <condition> evaluates to true, <statement1> executes. If <condition> is false, <statement2> executes.
Example:
if tau>45ns mwpulse t180 else wait t180 end
Legend: PPL keywords; PPL pulse commands; comments.
Note that else keyword is necessary even if there is no <statement2>.
Example:
if use_pulse mwpulse 200 ns else end
Legend: PPL keywords; PPL pulse commands; comments.
int
Use the int type specifier to define an integer data type.
See also
parallel-end
Defines a new timeline that is valid within the parallel - end scope. Time is starting from the current value of the internal time counter.
Internal time counter after the end of statement returns to the state it was before parallel statement. Parallel statements can be nested.
Example:
%% Davies ENDOR sequence mwpulse 200ns %% Inversion pulse parallel %% Preserve time counter rfpulse 8us %% RF pulse end %% Return time counter to the preserved position wait 10us %% Wait until the detection sequence mwpulse 100ns %% Between this pulse and the first one - 10us wait 500ns mwpulse 200ns wait 500ns detect a %% Detect signal 'a'
Legend: PPL keywords; PPL pulse commands; comments.
Use this statement to send to log results of the expression during the execution of ppl.
Example:
frequency f time t signal a AB = f*t print AB detect a
Legend: PPL keywords; PPL pulse commands; comments.
Result (f=1MHz, t=1us):
PPL: 360 deg (phase)
See also
phase
Use the phase type specifier to define an identifier to be a frequency type.
Phase type identifier can be added or subtracted. Phases can be multiplied and divided by real or int.
Example:
phase f f = 45deg f = f/5.0
Legend: PPL keywords; PPL pulse commands; comments.
See also
reference
For digital detection reference is a frequency that in combination with timezero defines the phase of the detect statement. Phase is calculated as reference*(detect_time - t0) where t0 set by timezero statement.
Example:
reference 23MHz
Legend: PPL keywords; PPL pulse commands; comments.
See also
$timezero$
repeat-end
Use the repeat keyword to iterate a statement. The expression should result in the integer number. Use round() function to convert real expression into integer.
| Parameter | Type | Description |
| expression | int | Number of iterations |
Example:
%% make series of pulses for 100us t = 100us repeat round(t/(t90+10us)) mwpulse t90 wait 10us end
Legend: PPL keywords; PPL pulse commands; comments.
hrepeat-end
Hardware version of repeat-end command. Use the hrepeat keyword to iterate a statement on hardware. This statement may not be compatible with all pulse generators.
| Parameter | Type | Description |
| expression | int | Number of iterations |
Example:
%% make 10 acquisitions separated by 10us hrepeat 10 detect a wait 10us end
Legend: PPL keywords; PPL pulse commands; comments.
real
Use the real type specifier to define an identifier to be a floating-point data type. real type corresponds to double type in C.
See also
round
Rounding down a value. Returns an integer less or equal to the value.
signal
Use the signal type specifier to define the acquisition channels. The name of the channel is a special object with signal data type. Declaration of signals has to be done after the declaration of external variables. Variables of signal data types are used as arguments of the detect command. Declared acquisition channels appear in the Experiment Axis Setup.
Example:
signal a,b detect a,-b
Legend: PPL keywords; PPL pulse commands; comments.
Assigning of real value to signal leads to modification of the detection coefficient. Multiplication and division of signals result in signal variable type. By default signal is equal to 1.
Example:
signal a,b detect 5*a,-2*b
Legend: PPL keywords; PPL pulse commands; comments.
In the above example all value taken from signal 'b' will be multiplied by -1 (signal sign inversion).
time
Use the time type specifier to define an identifier representing physical value time.
According to SI standard time is measuring in seconds (s). Smaller units than the second produced by attaching power-of-10 Prefixes.
Example:
time t, tau
Legend: PPL keywords; PPL pulse commands; comments.
See also
timezero
This statement is used by AWG engine and digital detection engine.
Many pulse commands use waveforms modulating a carrier frequency. The phase of this frequency relative to the beginning of the pulse is calculated as frequency*(current_time - t0). t0 starts at the beginning of pulse sequence. Use the timezero statement to set t0 to internal time counter at the moment of statement effectively zeroing the phase at this time.
For digital detection engine timezero defines the phase of the detect statement calculated as frequency*(detect_time - t0) where frequency is defined by reference statement and t0 set by timezero statement.
Note: Statement has no effect on pulse patterns and AWG commands with Global phase switched off.
Example:
set1 = [1.0, 10MHz, 0deg] timezero mwpulse 300ns, set1
Legend: PPL keywords; PPL pulse commands; comments.
See also
true
Boolean value true.
See also
wait
Wait command adds time to the internal time counter. Use wait to space pulses from each other. Note that the expression might be negative.
| Parameter | Type | Description |
| expression | time | Time to wait between pulses or events |
Example:
mwpulse 45ns %% make a pulse wait tau %% wait time defined by tau variable mwpulse 90ns %% make another pulse
Legend: PPL keywords; PPL pulse commands; comments.
See also:

