#include <DigitalInOut.h>
Public Member Functions | |
DigitalInOut (PinName pin) | |
DigitalInOut (PinName pin, PinDirection direction, PinMode mode, int value) | |
void | write (int value) |
int | read () |
void | output () |
void | input () |
void | mode (PinMode pull) |
int | is_connected () |
DigitalInOut & | operator= (int value) |
DigitalInOut & | operator= (DigitalInOut &rhs) |
operator int () | |
Protected Attributes | |
gpio_t | gpio |
A digital input/output, used for setting or reading a bi-directional pin
|
inline |
Create a DigitalInOut connected to the specified pin
pin | DigitalInOut pin to connect to |
|
inline |
Create a DigitalInOut connected to the specified pin
pin | DigitalInOut pin to connect to |
direction | the initial direction of the pin |
mode | the initial mode of the pin |
value | the initial value of the pin if is an output |
|
inline |
Set as an input
|
inline |
Return the output setting, represented as 0 or 1 (int)
|
inline |
Set the input pin mode
pull | PullUp, PullDown, PullNone, OpenDrain |
|
inline |
A shorthand for read()
|
inline |
A shorthand for write()
|
inline |
A shorthand for write()
|
inline |
Set as an output
|
inline |
Return the output setting, represented as 0 or 1 (int)
|
inline |
Set the output, specified as 0 or 1 (int)
value | An integer specifying the pin output value, 0 for logical 0, 1 (or any other non-zero value) for logical 1 |