![]()  | 
     BALTECH Docs | 
    C API for BALTECH SDK
   
    
   
   | 
   
| brp_errcode brp_Sys_ConfigPort | ( | brp_protocol | protocol, | 
| brp_IoPortBitmask | InpOutp, | ||
| brp_IoPortBitmask | DefaultState | ||
| ) | 
Configures generic I/O ports for input/output.
Some ports are unidirectional (only usable either as an input or as an output). Only bidirectional ports can be reconfigured via this command.
I/O Port configuration can also be performed via scripts in the configuration editor. See the__ BaltechScript documentation__ for further details.
| [in] | protocol | used to execute the command | 
| [in] | InpOutp | Bit mask describing if I/O pins should be configured for input or output use: * Logical '1': pin used as output * Logical '0': pin used as input | 
| [in] | DefaultState | Bit mask describing the initial state of I/O pins. The specified values have to be interpreted in combination with the I/O pins' direction (according to the InpOutp variable). * When a port is configured as input: * '0': Port is configured as tri-state * '1': port is pulled up at 5V * When a port is configured as output: * '0': 0V * '1': 5V (default state, corresponds to the initial state of the output port) |