mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-21 23:33:57 -04:00
AVR I2C: bug fix
Fix provided by both Jason Short and lucafedechen independently
This commit is contained in:
parent
e0dcd680f7
commit
b16ce5e523
@ -150,10 +150,6 @@ uint8_t AVRI2CDriver::read(uint8_t addr, uint8_t len, uint8_t* data){
|
||||
stat = 0;
|
||||
stat = _start();
|
||||
if(stat) goto error;
|
||||
stat = _sendAddress(SLA_W(addr));
|
||||
if(stat) goto error;
|
||||
stat = _start();
|
||||
if(stat) goto error;
|
||||
stat = _sendAddress(SLA_R(addr));
|
||||
if(stat) goto error;
|
||||
for(uint8_t i = 0; i < len ; i++) {
|
||||
|
Loading…
Reference in New Issue
Block a user