BL4S200 User’s Manual
92
4.4.3 High-Current Outputs
digOutConfig_H
int digOutConfig_H(char configuration);
FUNCTION DESCRIPTION
Sets the configuration of a high-current output to be a sinking or sourcing type output.
Upon configuration, the output will be set initially to a high-impedance tristate.
NOTE:
Configuring a given output channel for tristate operation using the
digOut-
TriStateConfig()
function call will temporarily override the configuration set by
the
digOutConfig_H()
function call as long as it is kept a tristate channel. This
configuration can also be overridden by setting the channel as a PWM or PPM output.
PARAMETER
configuration
configuration byte to configure output channels HOUT0–
HOUT7 as sinking or sourcing outputs.
Each bit corresponds to one of the following high-current outputs.
Bit 7 = high-current output channel HOUT7
Bit 6 = high-current output channel HOUT6
Bit 5 = high-current output channel HOUT5
Bit 4 = high-current output channel HOUT4
Bit 3 = high-current output channel HOUT3
Bit 2 = high-current output channel HOUT2
Bit 1 = high-current output channel HOUT1
Bit 0 = high-current output channel HOUT0
The high-current outputs are configured to be sinking or sourcing
outputs by setting the corresponding bit to 0 or 1: 0 = sinking,
1 = sourcing.
EXAMPLE
RETURN VALUE
0 — success.
-EINVAL
— board initialization not performed.
SEE ALSO
brdInit, digOut_H, digOutTriStateConfig_H
configuration = 0x26;
// 0 0 1 0 0 1 1 0
// HOUT7–HOUT6 = Sinking
// HOUT5 = Sourcing
// HOUT4–HOUT3 = Sinking
// HOUT2–HOUT1 = Sourcing
// HOUT0 = Sinking