You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by je...@apache.org on 2021/05/20 05:24:05 UTC

[incubator-nuttx] 08/21: arch: cxd56xx: Update i2c register initialization

This is an automated email from the ASF dual-hosted git repository.

jerpelea pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit ade26c17d23c8d0b57e7e2e4c44ef06b569bff11
Author: SPRESENSE <41...@users.noreply.github.com>
AuthorDate: Wed May 19 17:04:13 2021 +0900

    arch: cxd56xx: Update i2c register initialization
    
    Enable RX_FIFO_FULL_HLD_CTRL and RESTART of i2c control register in
    i2c initial settings for transfer by SCU sequencer.
---
 arch/arm/src/cxd56xx/cxd56_i2c.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/arm/src/cxd56xx/cxd56_i2c.c b/arch/arm/src/cxd56xx/cxd56_i2c.c
index 5b0d29a..eb7ea61 100644
--- a/arch/arm/src/cxd56xx/cxd56_i2c.c
+++ b/arch/arm/src/cxd56xx/cxd56_i2c.c
@@ -1028,7 +1028,9 @@ struct i2c_master_s *cxd56_i2cbus_initialize(int port)
   i2c_reg_write(priv, CXD56_IC_SDA_HOLD, 1);
 
   i2c_reg_write(priv, CXD56_IC_CON,
-                (IC_SLAVE_DISABLE | IC_MASTER_MODE | IC_TX_EMPTY_CTRL));
+                (IC_RX_FIFO_FULL_HLD_CTRL | IC_RESTART_EN |
+                 IC_SLAVE_DISABLE | IC_MASTER_MODE | IC_TX_EMPTY_CTRL));
+
   cxd56_i2c_setfrequency(priv, I2C_DEFAULT_FREQUENCY);
 
   leave_critical_section(flags);