You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ar...@apache.org on 2022/11/21 09:39:22 UTC

[incubator-nuttx] 10/12: Fix Error: chip/stm32_qencoder.c:989:46: error: format specifies type 'unsigned long' but the argument has type 'uint32_t' (aka 'unsigned int')

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

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

commit a34230c95473a68317ad6b5954e01f13faf6f95b
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Sun Nov 20 14:09:09 2022 +0800

    Fix Error: chip/stm32_qencoder.c:989:46: error: format specifies type 'unsigned long' but the argument has type 'uint32_t' (aka 'unsigned int')
    
    Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
---
 drivers/sensors/mpu60x0.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/sensors/mpu60x0.c b/drivers/sensors/mpu60x0.c
index ff2b45a180..2bc6cb3705 100644
--- a/drivers/sensors/mpu60x0.c
+++ b/drivers/sensors/mpu60x0.c
@@ -576,11 +576,13 @@ static inline int __mpu_write_pwr_mgmt_2(FAR struct mpu_dev_s *dev,
   return __mpu_write_reg(dev, PWR_MGMT_2, &val, sizeof(val));
 }
 
+#ifdef CONFIG_MPU60X0_SPI
 static inline int __mpu_write_user_ctrl(FAR struct mpu_dev_s *dev,
                                         uint8_t val)
 {
   return __mpu_write_reg(dev, USER_CTRL, &val, sizeof(val));
 }
+#endif
 
 /* __mpu_write_gyro_config() :
  *