Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i2c_scanner does not work on olimexino_stm32 #22027

Closed
boonpin1975 opened this issue Jan 18, 2020 · 4 comments
Closed

i2c_scanner does not work on olimexino_stm32 #22027

boonpin1975 opened this issue Jan 18, 2020 · 4 comments
Labels
Enhancement Changes/Updates/Additions to existing features platform: STM32 ST Micro STM32

Comments

@boonpin1975
Copy link

building the i2c_scanner on olimexino_stm32 , with the sht3xd sensor connected to i2c1 , I keep getting this error when running i2c_scanner

[00:00:00.051,000] i2c_ll_stm32_v1.msg_end: stm32_i2c_msg_write: NACK

is there need extra kernel config when using the i2c API in stm32 ?

Starting i2c scanner...

 0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f

00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

0 devices found on I2C_1
prj.conf
CONFIG_I2C=y
CONFIG_LOG=y
CONFIG_STDOUT_CONSOLE=y
CONFIG_PRINTK=y
CONFIG_I2C_LOG_LEVEL_DBG=y

@boonpin1975 boonpin1975 added the bug The issue is a bug, or the PR is fixing a bug label Jan 18, 2020
@jfischer-no jfischer-no changed the title [00:00:00.051,000] <dbg> i2c_ll_stm32_v1.msg_end: stm32_i2c_msg_write: NACK i2c_scanner does not work on olimexino_stm32 Jan 18, 2020
@boonpin1975
Copy link
Author

I have tested another eeprom , at24c02 , address is 0x50 , but there is nothing in the i2c_scanner console .

@erwango
Copy link
Member

erwango commented Jan 20, 2020

Cf #20325:
"
[...] the test doesn't work because the ST I2C driver doesn't handle the SMBUS command that's used to detect a NAK on the address for an absent subordinate device. It reports all addresses as being associated with devices."

Moving this to enhancement.

@erwango erwango added Enhancement Changes/Updates/Additions to existing features platform: STM32 ST Micro STM32 and removed bug The issue is a bug, or the PR is fixing a bug labels Jan 20, 2020
@pabigot
Copy link
Collaborator

pabigot commented Aug 25, 2020

#20560 fixed the I2C scanner on STM32, so if this is reproducible there's something else going on. Possibly scanning the wrong I2C bus.

@nashif
Copy link
Member

nashif commented May 28, 2021

please file a bug if this still occurs.

@nashif nashif closed this as completed May 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Changes/Updates/Additions to existing features platform: STM32 ST Micro STM32
Projects
None yet
Development

No branches or pull requests

4 participants