Fix warnings
This commit is contained in:
parent
b3364f0b88
commit
727a974504
2
rtc.cpp
2
rtc.cpp
@ -271,7 +271,7 @@ void rtc_run_clock(bool run)
|
||||
else
|
||||
b |= _BV(CH_BIT); // set bit
|
||||
|
||||
rtc_write_byte(b, 0x0);
|
||||
rtc_write_byte(b, 0x0);
|
||||
}
|
||||
|
||||
// DS1307 only
|
||||
|
@ -369,6 +369,7 @@ SIGNAL(TWI_vect)
|
||||
case TW_MR_DATA_ACK: // data received, ack sent
|
||||
// put byte into buffer
|
||||
twi_masterBuffer[twi_masterBufferIndex++] = TWDR;
|
||||
[[fallthrough]];
|
||||
case TW_MR_SLA_ACK: // address sent, ack received
|
||||
// ack if more bytes are expected, otherwise nack
|
||||
if(twi_masterBufferIndex < twi_masterBufferLength){
|
||||
@ -380,6 +381,7 @@ SIGNAL(TWI_vect)
|
||||
case TW_MR_DATA_NACK: // data received, nack sent
|
||||
// put final byte into buffer
|
||||
twi_masterBuffer[twi_masterBufferIndex++] = TWDR;
|
||||
[[fallthrough]];
|
||||
case TW_MR_SLA_NACK: // address sent, nack received
|
||||
twi_stop();
|
||||
break;
|
||||
@ -446,6 +448,7 @@ SIGNAL(TWI_vect)
|
||||
twi_txBuffer[0] = 0x00;
|
||||
}
|
||||
// transmit first byte from buffer, fall
|
||||
[[fallthrough]];
|
||||
case TW_ST_DATA_ACK: // byte sent, ack returned
|
||||
// copy data to output register
|
||||
TWDR = twi_txBuffer[twi_txBufferIndex++];
|
||||
|
Loading…
Reference in New Issue
Block a user