MCPcopy Create free account
hub / github.com/RobTillaart/Arduino / read

Method read

libraries/PCF8574/PCF8574.cpp:99–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97
98
99uint8_t PCF8574::read(const uint8_t pin)
100{
101 if (pin > 7)
102 {
103 _error = PCF8574_PIN_ERROR;
104 return 0;
105 }
106 PCF8574::read8();
107 return (_dataIn & (1 << pin)) > 0;
108}
109
110
111void PCF8574::write(const uint8_t pin, const uint8_t value)

Callers 2

read8Method · 0.45
unittestFunction · 0.45

Calls

no outgoing calls

Tested by 1

unittestFunction · 0.36