Skip to content

Commit d7d433d

Browse files
avg-Izeising
authored andcommitted
i2c_sendbyte: pulse SCL to request ACK/NACK bit from slave (#51)
(cherry picked from commit 6a3d6e6)
1 parent 3c49876 commit d7d433d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

linuxkpi/gplv2/src/linux_i2c.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -302,6 +302,9 @@ i2c_sendbyte(struct i2c_algo_bit_data *adap, unsigned char data)
302302
}
303303
}
304304

305+
sdahi(adap);
306+
if (sclhi(adap) < 0)
307+
return (-ETIMEDOUT);
305308
ack = (getsda(adap) == 0);
306309
scllo(adap);
307310
return ack;

0 commit comments

Comments
 (0)