BL4S200 User’s Manual
83
digOutBank
int digOutBank(char bank, char data);
FUNCTION DESCRIPTION
Sets the state (logic 0 or logic 1) of a bank of 8 digital output pins within one of 4 banks
to the states contained in the
data
parameter. This function only updates the channels
that are configured to be sinking digital outputs by the
setDigOut()
function call.
Channels configured for other functionality will not be affected.
PARAMETERS
bank
digital output bank pins:
0 — DIO0–DIO7
1 — DIO8–DIO15
2 — DIO16–DIO23
3 — DIO24–DIO31
data
data value to be written to the specified digital output bank; the
data format and bitwise value are as follows:
Bitwise value:
0 — connects the load to GND
1 — puts the output in a high-impedance tristate.
RETURN VALUE
0 — success.
-EINVAL
— invalid parameter value or board not initialized.
SEE ALSO
brdInit, digOut, setDigOut
Data Bits
Bank 0
Bank 1
Bank 2
Bank 3
LSB
D0
DIO0
DIO8
DIO16
DIO24
D1
DIO1
DIO9
DIO17
DIO25
D2
DIO2
DIO10
DIO18
DIO26
D3
DIO3
DIO11
DIO19
DIO27
D4
DIO4
DIO12
DIO20
DIO28
D5
DIO5
DIO13
DIO21
DIO29
D6
DIO6
DIO14
DIO22
DIO30
MSB
D7
DIO7
DIO15
DIO23
DIO31
electronic components distributor