From d39c7abb4d618b817e8ae0bd77eb54c7ba3a61bb Mon Sep 17 00:00:00 2001 From: Ayke van Laethem Date: Sun, 27 Sep 2020 14:39:39 +0200 Subject: [PATCH] nrf: fix double stop signal in I2C --- src/machine/machine_nrf.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/machine/machine_nrf.go b/src/machine/machine_nrf.go index 506f134e..39743bf5 100644 --- a/src/machine/machine_nrf.go +++ b/src/machine/machine_nrf.go @@ -260,10 +260,6 @@ func (i2c I2C) Configure(config I2CConfig) { // bytes and stores them in r, and generates a stop condition on the bus. func (i2c I2C) Tx(addr uint16, w, r []byte) (err error) { i2c.Bus.ADDRESS.Set(uint32(addr)) - defer func() { - i2c.signalStop() - i2c.Bus.SHORTS.Set(nrf.TWI_SHORTS_BB_SUSPEND_Disabled) - }() if len(w) != 0 { i2c.Bus.TASKS_STARTTX.Set(1) // start transmission for writing