50 Software Library Reference Manual for VME 429
Section 3 - System Functions
3.8 Api429CmdInitDiscretes
P
P
r
r
o
o
t
t
o
o
t
t
y
y
p
p
e
e
:
:
AiUInt8 Api429CmdInitDiscretes( AiUInt8 uc_Module, AiUInt32 ul_DiscreteSetup );
D
D
r
r
i
i
v
v
e
e
r
r
C
C
o
o
m
m
m
m
a
a
n
n
d
d
:
:
API429_INIT_DISCRETES (0x47)
P
P
u
u
r
r
p
p
o
o
s
s
e
e
:
:
This command is used to configure the discretes. An APM429 board provides 8
discretes where each of the discretes can be initialized as Input or Output.
Note: This function is only valid for APM429 boards!
I
I
n
n
p
p
u
u
t
t
A
A
i
i
U
U
I
I
n
n
t
t
3
3
2
2
u
u
l
l
_
_
D
D
i
i
s
s
c
c
r
r
e
e
t
t
e
e
S
S
e
e
t
t
u
u
p
p
Bit 31 Bit 30 Bit 29 Bit 28 Bit 27 Bit 26 Bit 25 Bit 24
Reserved (0)
Bit 23 Bit 22 Bit 21 Bit 20 Bit 19 Bit 18 Bit 17 Bit 16
Reserved (0)
Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8
Reserved (0)
Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0
IN/OUT IN/OUT IN/OUT IN/OUT IN/OUT IN/OUT IN/OUT IN/OUT
IN/OUT
Each of the 8 discretes can be programmed to Input or Output
Value Description
0
Discrete is used as Input
1
Discrete is used as Output
O
O
u
u
t
t
p
p
u
u
t
t
None
R
R
e
e
t
t
u
u
r
r
n
n
V
V
a
a
l
l
u
u
e
e
Value Constant Description
0 API429_CMD_OK
Execution success
1 API429_CMD_ERR
Execution error