-1

Is it possible to use the pressure sensor to act as a weight sensor?

In my understanding, the pressure sensor works on the amount of pressure put it to it, if the pressure is coming from the weight of an object, will it produce an output that is almost the same with the weighing scale?

I am working on a project right now and it involves sensor programming on Raspberry pi.

If this is possible can you help me on python coding of the pressure sensor?

Thanks in advance.

1 Answer 1

2

You measure the force with your pressure sensor. Force is mass times acceleration. (f = m \times a). The gravitational acceleration on earth is ~ 9.80665 m/s². To get the mass of your object you need to calculate:

m = \frac{f}{a}

with a = 9.80665 m/s² and f is your sensor reading. Assuming that your sensor delivers values in Newtons (thanks Mark Perryman), then you have the mass in kg.

7
  • 1
    Note that this assumes that the pressure sensor returns a value for the Force in Newtons. Commented Jan 4, 2017 at 13:44
  • Also worth noting (see en.wikipedia.org/wiki/Gravity_of_Earth) that the acceleration due to gravity varies between 9.77 to 9.83 depending on where you are in the world. 9.80665 is "Standard Gravity", but the implied extra precision might mislead. (I would use 9.8 or 9.81 as the calculated mass will only be accurate to 2 or 3 significant figures anyway.) Commented Jan 4, 2017 at 13:55
  • Thanks for this very helpful information @Sender9. I am not yet acquainted with this formula. Is it safe to say that the pressure sensor measures the force with mass while the weight sensor is measuring the mass of an object without any force?
    – al123
    Commented Jan 4, 2017 at 14:02
  • @Mark Perryman. I am not sure yet if the pressure sensor that Im looking for will return in Newtons. I haven't figure out yet which one to buy, Im still checking out Sparkfun for the best sensor that I need. Thanks for the link you have provided. This makes sense. So gravity is not constant anyway in all part of the world. Does this mean that, my weight may be different if I go to a place where gravity is 9.83 and 9.77?
    – al123
    Commented Jan 4, 2017 at 14:06
  • 1
    @al123: Yes, the weight is different but the mass is the same. What you want is the mass (in kg). Weight (also called weight force) is measured in Newton.
    – senden9
    Commented Jan 4, 2017 at 14:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.