RTC6 boards
Doc. Rev. 1.0.21 en-US
9 Programming Peripheral Interfaces
293
Regular (Periodic) External Starts
By set_control_mode and set_control_mode_list
(Bit #10), equidistant External Starts can be created
that are independent of the time point of the start
trigger as long as they occur within the specified
track delay.
This strongly periodic list processing is –
independently of a list’s actual duration of execution
and the exact time point of the External Start – exactly
synchronized to the 10 µs clock of the
RTC6 PCIe Board.
If desired, set Bit #10 = 1 (
Mode|Bit #10
) to
configure the internal encoder-counter’s processing
so that the track delay of an External Start is not
counted only beginning with the time point of the
triggering external start signal or simulate_ext_start
(Bit #10 = 0) but already beginning with the most
recently executed External Start (also executed by an
external start signal or simulate_ext_start), see
Figure 70. This makes the distance between
consecutive External Starts (in encoder pulses)
constant.
For activation of this mode, an External Start must
have successfully occurred (only one-time) in mode
Bit #10=0 (
Mode &~Bit #10
). Each subsequent
External Start must be requested within the specified
track delay.
Example in Pascal of a typical command sequence
without use of an external start signal:
set_control_mode(Mode &~Bit #10);
// (one-time) reset (disable) Bit #10
// (initialization)
set_start_list_pos(ListNo, Pos);
// open some list
// afterward: some commands
simulate_ext_start(Delay,EncoderNo);
// first time start in mode Bit #10 = 0,
// otherwise in mode Bit #10 = 1
set_control_mode_list(Mode|Bit #10);
// set Bit #10 = 1
// afterward: further commands
set_end_of_list;
// close the list
execute_list_pos(ListNo,Pos);
// (one-time) start the list
If the first start is to be triggered externally (for
example, by /START or by simulate_ext_start_ctrl)
rather than by an execute_list_pos command, but all
subsequent starts triggered by simulate_ext_start,
then set_control_mode_list in the above example
must be called before simulate_ext_start.
After setting set_control_mode(
Bit #1
= 1 ), the
external start queue entries get explicitly canceled
upon an External Stop (thereby, External Starts can be
permanently stopped by an External Stop).
For set_control_mode(
Bit #1
= 0 ) (default setting)
– after an otherwise infinitely repetitive series has
been stopped (for example, by
set_contr
ol_mode(
Bit #0
= 0 ) –
you should
deactivate the track delay and cancel the queue of
not-yet-executed External Starts by
set_ext_start_delay(
Delay
= 0 ). Otherwise, the
next “equidistant“ External Start does not have the
correct gap. set_control_mode(
Bit #2
= 1 ) alone
is not sufficient for termination, because the track
delay is reactivated by any not-yet-executed
simulate_ext_start calls.