tatobari / hx711py

HX711 Python Library for Raspberry Pi.
Apache License 2.0
206 stars 154 forks source link

Is it possible to connect multiple sensors to a single pi with this code? #37

Closed ronanb95 closed 3 years ago

ronanb95 commented 3 years ago

Hi,

The code works great for a single hx711 connected to one pi.

I am trying to connect multiple load sensors to a single pi and I am just wondering is it possible to do this by changing part of this code?

I have tried creating a new instance like hx711(8,9) where 8 and 9 are the corresponding pins connecting to the hx711 but this does not seem to be working. I am very new to all of this so I could be doing it completely wrong.

Ideally I would like to be able to connect 4+ sensors but even if I could connect 2 simultaneously then that would be great.

Thanks

Janik-97 commented 3 years ago

Until now I have connected 4 hx771 to one RPi 3 B+ and they work perfectly. Just use different pins and wire them correctly (pinout.xyz). My goal is to run 12 hx711 simultaneously. Should be no problem in theory.

ronanb95 commented 3 years ago

Hey Janik,

I have since connected another unit with no problems at all.

As far as I can tell the maximum number of units that can be connected at any one time would be 4 because each unit must be connected to one of the 4 power pins on the pi. I could be wrong with that theory though.

Thanks for the reply anyway :)

NeonSpork commented 3 years ago

I'm fairly sure you could piggyback some of the power from the pins with some creative wiring to run even more in that case, I doubt the hx7711 need an immense amount of juice. :)

On Thu, Nov 12, 2020, 19:05 Ronan Byrne notifications@github.com wrote:

Hey Janik,

I have since connected another unit with no problems at all.

As far as I can tell the maximum number of units that can be connected at any one time would be 4 because each unit must be connected to one of the 4 power pins on the pi. I could be wrong with that theory though.

Thanks for the reply anyway :)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/tatobari/hx711py/issues/37#issuecomment-726244485, or unsubscribe https://github.com/notifications/unsubscribe-auth/AH5V4JOYUWAYKYT6QXLYFMLSPQPV5ANCNFSM4SV7K4MA .

NeonSpork commented 3 years ago

I guess this issue can be closed since the question has been answered.