MCPcopy Create free account
hub / github.com/SmingHub/Sming / twi_write_byte

Function twi_write_byte

Sming/Core/si2c.cpp:114–121  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

112}
113
114bool twi_write_byte(uint8_t byte)
115{
116 for(unsigned bit = 0; bit < 8; bit++) {
117 twi_write_bit(byte & 0x80);
118 byte <<= 1;
119 }
120 return !twi_read_bit(); //NACK/ACK
121}
122
123uint8_t twi_read_byte(bool nack)
124{

Callers 4

twi_writeToMethod · 0.85
twi_readFromMethod · 0.85
twi_writeToFunction · 0.85
twi_readFromFunction · 0.85

Calls 2

twi_write_bitFunction · 0.85
twi_read_bitFunction · 0.85

Tested by

no test coverage detected