0

Raspberry Pi cannot find accelerometer sensor at I2C address
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Raspberry Pi cannot find accelerometer sensor at I2C address

by sdl5384 on Sat Feb 20, 2021 1:00 pm

Hello:

I just had a couple questions for all of you. As of right now I have my Adafruit accelerometer (LIS3DH) hooked up to my Raspberry 4B. I installed CircuitPython as well as the Adafruit packages necessary for the two to communicate. But every time I try to run the code, it tells me nothing cannot be found at either I2C address 0x18 or 0x19. Everything is color coded and hooked up to the proper input and outputs both on the Pi and the breadboard. So I don't understand how it can't be found.

Could any of you please help direct or guide me in terms of what I could possibly be doing wrong? If necessary, I can send you pics on how they're hooked up as well as the source code. I am just trying to use the simpletest python code as a starting point so I can customize it to what I need to do for my project.

Thank you so much all!

S.D.L.

sdl5384
 
Posts: 7
Joined: Fri Feb 19, 2021 10:48 am

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by dastels on Sat Feb 20, 2021 4:19 pm

Is I2C enabled? Does i2cdetect see it?

Dave

dastels
 
Posts: 5394
Joined: Tue Oct 20, 2015 3:22 pm

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by sdl5384 on Sat Feb 20, 2021 4:23 pm

It is enabled but it doesn’t see it. Everything is wired correctly.

sdl5384
 
Posts: 7
Joined: Fri Feb 19, 2021 10:48 am

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by dastels on Sat Feb 20, 2021 5:58 pm

You mean i2cdetect doesn't see it?

Can you post clear photos of your wiring? Especially any soldering.

Dave

dastels
 
Posts: 5394
Joined: Tue Oct 20, 2015 3:22 pm

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by sdl5384 on Sat Feb 20, 2021 6:30 pm

Sure thing.
Should be two photos. Please let me know if I need to send them again in case they didn’t go through.
Attachments
IMG-3045.jpg
IMG-3045.jpg (440.53 KiB) Viewed 61 times
IMG-3044.jpg
IMG-3044.jpg (192.47 KiB) Viewed 61 times

sdl5384
 
Posts: 7
Joined: Fri Feb 19, 2021 10:48 am

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by dastels on Sat Feb 20, 2021 7:38 pm

How about a shot of the soldering on the back of the sensor board?

Dave

dastels
 
Posts: 5394
Joined: Tue Oct 20, 2015 3:22 pm

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by sdl5384 on Sat Feb 20, 2021 7:45 pm

I haven’t soldered it yet. I don’t want to solder anything unless I know it works. Otherwise I may not be able to savage the sensor after soldering it.
Once it works then I will solder it to make the circuit permanent

sdl5384
 
Posts: 7
Joined: Fri Feb 19, 2021 10:48 am

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by dastels on Sun Feb 21, 2021 12:28 am

That's your problem. You need to solder the header in. If you don't there's no reason to think it will work.

Dave

dastels
 
Posts: 5394
Joined: Tue Oct 20, 2015 3:22 pm

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by sdl5384 on Sun Feb 21, 2021 12:32 am

Ok. Once the header is soldered in, do I connect the wires the same way or is there a different way to do it so the circuit is complete?

sdl5384
 
Posts: 7
Joined: Fri Feb 19, 2021 10:48 am

Re: Raspberry Pi cannot find accelerometer sensor at I2C add

by dastels on Sun Feb 21, 2021 3:41 pm

Your wiring looked ok. You just need to have a solid, reliable electrical connection, and soldering is the best (often only) way to get it. Especially with relatively high speed data lines like I2C or SPI.

Dave

dastels
 
Posts: 5394
Joined: Tue Oct 20, 2015 3:22 pm

Please be positive and constructive with your questions and comments.