Newport XPS-Q8 Users Manual, Software Tools And Tutorial page 150

Universal high-performance motion controller/driver
Hide thumbs Also See for XPS-Q8:
Table of Contents

Advertisement

XPS-Q8 Controller
XPSDocumentation V1.4.x (EDH0301En1060 — 10/17)
Example:
EventExtendedConfigurationActionSet
(GPIO1.DO.DOToggled, 4, 0, 0, 0)
In this case the actor is the digital output GPIO1.DO and the action is to toggle the
output. The value 4 refers to bit #3, 00000100. Hence, this action toggles the value of
bit 3 on the digital output GPIO.DO.
EventExtendedConfigurationActionSet (ExecuteTCLScript,
Example.tcl, 1, 0, 0)
The action ExecuteTCLScript has no preceding actor. This action will execute the TCL
script "Example.tcl". The task name is 1 and the TCL script has no arguments (a zero
for the third parameter means there are no arguments).
EventExtendedConfigurationActionSet (GatheringRun, 1000, 8, 0, 0)
The action GatheringRun has no preceding actor. This action will start an internal data
gathering. It will gather a total of 1000 data points, one data point every 8th servo cycle,
meaning one data point for every 8/8000 s = 1 ms.
It is also possible to trigger several actions with the same event. To do so, just define
another action in the SAME function. Several actions must be separated by a comma (,).
Example:
EventExtendedConfigurationTriggerSet
(MyGroup.MyPositioner.PositionerError, 2, 0, 0, 0)
EventExtendedConfigurationActionSet (ExecuteTCLScript,
ShutDown.tcl, 1, 0, 0, ExecuteTCLScript, ErrorDiagnostic.tcl, 2, 0, 0)
EventExtendedStart ()
In this example, the TCL scripts ShutDown.tcl and ErrorDiagnostic.tcl are executed
when a fatal following error is detected on the positioner MyGroup.MyPositioner.
The exact meaning of the different actions and action parameters is as follows:
DOToggle: This action is used to reverse the value of one or many bits of the
Digital Output. When using this action with an event that has some duration (for
example motion state) the value of the bits will be toggled at each profiler cycle as
long as the event occurs.
Action Parameter #1 – Mask
Action Parameter #2 to #4
DOPulse: This action is used to generate a positive pulse on the Digital Output. The
duration of the pulse is 1 microsecond. To function, the bits on which the pulse is
generated should be set to zero before. When using this action with an event that has
some duration (for example motion state), a 1 µs pulse will be generated at each
cycle of the motion profiler (or every 400 µs) as long as the event occurs.
Action Parameter #1 – Mask
Action Parameter #2 to #4
138
Motion Tutorial
The mask defines which bits on the GPIO
output will be toggled (change their value).
For example, if the GPIO output is an 8 bit
output and the mask is set to 4 then the
equivalent binary number is 00000100. So as
an action, bit #3 will be toggled.
These parameters are 0 by default.
The mask defines on which bits on the GPIO
output the pulse will be generated. For
example, if the GPIO output is an 8 bit output
and the mask is set to 6 then the equivalent
binary number is 00000110. So as an action,
a 1 µs pulse will be generated on bit #2 and
#3 of the GPIO output.
These parameters are 0 by default.

Advertisement

Table of Contents
loading

Table of Contents