4-20mA pressure sensor keeps reading -75PSI output

Sensor = variable resistor

No. The signature of a current loop device is to produce current, 4 - 20 mA. The voltage across the sensor is uninteresting as I'm used to handle such devices.

Sensor cannot produce itself current, you have a loop , 24V power supply applied to resistor divider = sensor + resistor L and measure the current in the loop which can vary 2-20 mA depends to resistance of sensor ?
Screen Shot 2021-06-02 at 12.39.46 PM

my measurements i mentioned before was with the 24V supply voltage.

Why not? No problem at all. Current lop sensors contain much more than a simple resistor. Therefor a supply voltage higher then some 5 volt is needed. The logic/amplifier/..... needs fuel....

Go on with Your work. This extra discussion likely brings more confusion then help.

Getting into this question late. So you noted that -75 means basically 0 volts. Assuming your power supply is of a high enough voltage (from the spec sheet and the requirements at the Arduino analog input you need at least 8.5+5 = 13.5 VDC) the sensor should at that point be passing 4mA at 0PSI, or 250*.004 = 1 volt.

Since you aren't seeing 1 volt, either the resistor is wrong, the power supply voltage is inadequate, or the sensor isn't working correctly. If you have a DVM you can measure that the current is (or isn't) 4ma, check the power supply voltage and check the resistor value.

(FYI, for 8 years prior to my retirement I worked as an electrical engineer for a company that makes current-loop (and other) sensors, so was dealing with this sort of thing at least from the design side on a daily basis.)

on 250 Ohm = 316 uA (microamps) = very small current = sensor not good

Try this

and voltage is ?

thank you for the respond, you aren't late at all. i just measured my resistor and turned out it's a 150 instead of 250. my question is, is my problem really just at the resistor? would my output voltage be way higher than what i've been getting if i had a lower resistor than i was supposed to have?

i measured the input voltage and it was at 24V, my output amp from my sensor was 0.001 so 1mA. is it my sensor problem then? it's brand new so i don't know why it would be. and all of these measurements were taken place outside of the circuit board (so not resistors or anything yet).

@79galinakorczak i'm gonna update you what it is once i have a 250 ohm resistor. as i mentioned before in this comment, i just realized my resistor is 150..

do with 150

so i looked up my sensor diagram and realized i had been using the wrong wires (bc it has four), i fixed it and got 599.8mV, which should give me a 0.6V output when i use my 150 ohm resistor, still not 0V output though. but it is something.

do you guys have any idea on why it is 0.6V instead of 0V?

4mA x 150 Ohms = 600mV, minimum is 4 m, not a 0 mA

so my circuit works, i just need the right resistor then hopefully my arduino will start giving me right number, right..?

also, this might be a very dumb question. i have my code scale to 1-5V, does it need to be 0-5V? i saw online that people want to scale theirs at 0-5V and it needs other electrical components but i don't know why they do so.

It should never be 0V because that would be zero current. There is always an offset with 4-20mA current loop, 4mA. Your code in the first post is fine for handling this.

600mV through a 150Ω resistor is 4mA so it seems to be running perfectly now!

However your original code is only correct with a 250Ω resistor so you either need to recalculate the constants pressureZero and pressureMax or switch to a 250Ω resistor.

i think i will wait and switch to 250 ohm resistor just because i don't want to accidentally ruin my analog pin. i will keep you guys updated. thank you for everything!

For that you need 5V zener diode A0 - gnd, so 24V never get to arduino.

The 150Ω resistor won't ruin anything. What it does do is lower the voltage on the pin so you get less resolution of the pressure.

I suggest you output raw counts while troubleshooting. It will make things clearer that with post measurement calculations.

Your circuit in post #3 is correct. However the 250 ohms in series with A0 should be more like:
(24-5)/0.01 = a numimum of 2k , I suggest 5k. (to limit the current into A0 if the 250 opens up)

I would also put a 0.1µF cap from A0 to Gnd.

I have to second JohnRob.
When troubleshooting hardware.
Use raw values in software.

Further as a rule of thumb....
When troubleshooting hardware. Schematics and wiring diagrams are key.

When trouble shooting software, the raw inputs are key and schematics and wiring diagrams are unimportant.

The output A0 is 0 to 1023.
It cannot be negative.

4-20mA with the proper resistor shoud yield 204 on A0 with " zero." Output of the device.

If not then it is a hardware or wiring problen.

If you want to protect your pin do all testing with a multimeter.

And the device ground should not be connected to the signal lines or the arduino.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.