ADwin-Gold II
, Manual February 2013
163
RSxxx interface
Read_FIFO
ADwin
Read_FIFO
Read_FIFO
reads a value from the input FIFO of a specified RSxxx interface.
Syntax
#Include
ADwinGoldII.inc / GoldIITiCo.inc
ret_val
=
Read_FIFO
(
interface
)
Parameters
Notes
- / -
See also
,
Valid for
Gold II-CAN
Example
Rem Please select the appropriate include for ADbasic /
TiCoBasic
#Include
ADwinGoldII.inc / GoldIITiCo.inc
Init:
RS_Reset
()
RS_Init
(
1
,
9600
,
0
,
8
,
0
,
1
)
'Initialization of RSxxx
'interface 1
'with 9600 Baud, without parity,
'8 data bits, 1 stop bit and
'hardware handshake.
Event:
Par_1
=
Read_FIFO
(
1
)
'Get a value from the FIFO. If
'the FIFO is empty, -1 is
'returned.
T11 TiCo
interface
Number (1, 2) of the RSxxx interface that is to be
read out.
LONG
ret_val
Contents of the input FIFO:
-1: FIFO is empty.
≥
0:Transferred value.
LONG