MCPcopy Create free account
hub / github.com/DanielOgorchock/ST_Anything / read

Method read

Arduino/libraries/OneWire/OneWire.cpp:277–285  ·  view source on GitHub ↗

Read a byte

Source from the content-addressed store, hash-verified

275// Read a byte
276//
277uint8_t OneWire::read() {
278 uint8_t bitMask;
279 uint8_t r = 0;
280
281 for (bitMask = 0x01; bitMask; bitMask <<= 1) {
282 if ( OneWire::read_bit()) r |= bitMask;
283 }
284 return r;
285}
286
287void OneWire::read_bytes(uint8_t *buf, uint16_t count) {
288 for (uint16_t i = 0 ; i < count ; i++)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected