From 75f6c27763874dc9144c1e52d9ac1bd4969d1ccc Mon Sep 17 00:00:00 2001 From: Jeremy Soller Date: Wed, 21 Oct 2020 09:30:50 -0600 Subject: [PATCH] Fix extra start in i2c_set --- keyboards/system76/launch_beta_1/i2c.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/keyboards/system76/launch_beta_1/i2c.c b/keyboards/system76/launch_beta_1/i2c.c index 7877a2b8bfa..28fc9813fd8 100644 --- a/keyboards/system76/launch_beta_1/i2c.c +++ b/keyboards/system76/launch_beta_1/i2c.c @@ -161,5 +161,10 @@ int i2c_set(uint8_t addr, uint8_t reg, uint8_t* data, int length) { res = i2c_write(®, 1); if (res < 0) return res; - return i2c_send(addr, data, length); + res = i2c_write(data, length); + if (res < 0) return res; + + i2c_stop(); + + return res; }