Digital Inputs and Outputs
Get_Digout_Word1
ADwin
108
ADwin-Gold II
, Manual February 2013
Get_Digout_
Word1
Get_Digout_Word1
returns the register contents of the digital outputs
DIO00…DIO15.
Syntax
#Include
ADwinGoldII.inc / GoldIITiCo.inc
ret_val
=
Get_Digout_Word1
()
Parameterss
Notes
The return value represents the status of the output register only. A read
back of physical output status is technically impossible.
For any digital channel configured as input
Get_Digout_Long
will re-
turn an undefined value.
Conf_DIO
configures digital channels as in-
puts or outputs in groups of 8.
See also
,
,
,
Valid for
Gold II
Example
Rem Please select the appropriate include for ADbasic / TiCoBasic
#Include
ADwinGoldII.inc / GoldIITiCo.inc
Init:
REM Configure inputs and outputs
Conf_DIO
(
0011b
)
Event:
Par_1
=
Get_Digout_Word1
()
'read back bits 15:00 from register
T11 TiCo
ret_val
Bit pattern that corresponds to the TTL-levels at
the digital outputs (see table).
1: Set to TTL-level high.
0: Set to TTL-level low.
LONG
Bit no. in
r e t _
val
31 …
16
15
14
…
1
0
Channel
–
DIO15 DIO14
…
DIO01 DIO00