mA output on transducers

moxhamj

New Member
12 metres might be ok but would depend on the cable. What sort of cable are you planning to use?

I would certainly prototype something first before buying lots of sensors. One problem would be voltages spikes and the RC time constant might need adjusting. Indeed, I almost wonder if it is worth going out on site with a prototype and with the machinery running and hook up a CRO on the line and see if there are are any spikes.

Just a thought re twisted pair - I wonder if cat5 would be worth using? You get four pairs that are twisted and it comes in various pre-made lengths eg 10 metres, 20 metres etc with the plugs at the ends. There are joiners available so no soldering out in the field if you want to extend a cable.

You shouldn't need a zener.
 

demonicpicaxeguy

Senior Member
with most of the 4 - 20ma pressure transducers we've used on water mains, the most effective way to keep interference away is to have the adc as close as possible to the transducer,

another thing to consider is an insulated section between the transducer and the "working meduim" eg hydraulic hose


what exactly is this going to be measuring anyway?
 

leftyretro

New Member
An important installation point for pressure sensors is the proper mounting location.

If measuring a gas the sensor must be mounted higher then the process pressure tap location so that liquid condensates will not accumulate in the sensor and effect the measurement due to the 'head pressure' of the liquid.

If measuring a liquid pressure the sensor needs to be mounted below the process pressure tap location so that entrained gas can raise out of the measurement lead and ensure the measurement lead is always liquid packed. Entrained gas being compressible can effect the measurement of liquid pressure and cause a noisy measurement.

Lefty
 

westaust55

Moderator
Loop powered instruments do as standard operate from a 24Vdc supply and the loop must be continuous for the instrument to work. Separately powered instruments can be powered from 110Vac, 240Vac or other but the signal still must have a complete loop for them to operate.
In industry where PLC (and DCS) hardware is used, the 4 to 20mA signal is passed directly into the PLC Analogue input card. Basically the input card has a 250 Ohm resistor across the terminals which converts the current to be in the range 1V to 5Volt. This can then be handled by the PLC or your PICAXE.
A voltage lower than 1V or greater than 5V means there is a loss of power (=0V), out of range (=22mA), fault, etc situation with the field transmitter. Obviously at 22mA the voltage is 5.5V.
The above is a typical industry standard but for a one off, you could always use a 220 Ohm resistor for a peak voltage of 4.84V and the voltage at 4mA = 0.88V and at 20mA = 4.4V.
The use of a 1KOhm resistor and zener diode as shown by Tom2000 is a very good idea.
The whole idea of loop powered instruments is that the volt drop over a long cable length is of little consequence. Most instruments can operate down to around 18Vdc and maybe less so there is at least 6Vdc of volt drop available at 20mA.

Tom2000, there is always something new to learn. My philosophy is:
The first day you do not learn something new is your first day in a wooden box!


Forgot to mention, in industry the method of preventing/minimising interference is to provide a non-magnetic shield (usually aluminium foil) around the cable. This screen is earthed at one end only to avoid circulating currents. Olex and Prysmian are examples of Australian cable manufacturers who specifically make screened instrument cables.
 
Last edited:

Michael V

Senior Member
Good Tips

Hi Guys, Some very good tips here. To answer:
I guess this really is a prototype. Well i have two in service with 0-5V transducers i bought cheap on eBay, and these were 20bar transducers and it turns out the pressure won't go above 3 bar. That's about 45 PSI in old money, so we are talking about between car and bicycle tyre pressure. Its not high. These transmitters are 4 bar, the correct range for the job, and this will be my first signiificant mod to what has been installed.

Using the 4-20 mA transmitter (transducer plus 4-20mA mitter) does seem to be a standard for industrial process control and PLCs. By selecting the appropriate resistor eg 240 ohm i can detect less than 4 mA and greater than 20 mA, therefore open circuit or dead short, the only two options with two wires, and i can flag this up on the LCD and Logomatic data Logger as a maintenance action. (This is for monitoring, not control) Although Westaus, your comment about 22mA has thrown me i naively thought they just went to 20 mA.

These particular Sensors also from Ocean Controls who were best priced http://www.oceancontrols.com.au/Sensors/pressure/pressure_gs4200.htm and cheaper than RS components for the same thing (if anyone knows a cheaper source, tell me) and according to thhe data will operate from 13-36V.

The mining machine has 24V, but who knows how stable and erratic that is, so the idea was to take the 24V, use a 15V 1A fixed regulator ($1.20) and the proper capacitors for filtering, and power the transducers from that. The 15V would also be the Vin for my prebuilt microprocessor module. This is just to make the whole electrical thing more stable. The module and and prototype board from www.modtronix.com.au, and i have added the Picaxe download and reset circuit (have photos). Using Picaxe 28x1 in the SBC28 board, with the protoboard with 24 connecting points, so i can connect all the remote transducers and DS18B20 temp sensors easily. I2C for the LCD is via separate mini match connector, makes it easy and nice and modular.

I have been using screened microphone cable from www.Jaycar.com.au, WB 1540 four wire, but if i only have two wires i was going to use the two wire version. It is tough, and at about $2.50 per metre it is pretty affordable. I tried cat 5 cable for temperature sensors, but is so light it is a pain to work with. The microphone cable is chunky, more mine proof. One benefit of using 4-20 mA rather than voltage signals is meant to be signal stability.

Retro, good points about transducer placement, thanks. The fluid is hydraulic oil, and the purpose of the whole project is measurement in a fluctuating flow condition. It is possible for air to get in the system because the measurement is all on the low pressure side of the hydraulic circuit so i take the point about positioning the transducers so there are no air bubbles caught in there. On one of the machines it is upside down, (correctly) because that's how it turned out on the day, but the second is definitely catching air bubbles which will be dampening the pressure response. Need to fix that.

Hope that answers the questions. Advice welcome.

Forum seems to be 50-50 on whether the zener should be there or is optional. I'm still having trouble seeing if it is necessary. Even in dead short at 24V, only a couple of milliamps could squeeze through a 10K resistor prior to the ADC input. Is a few milliamps going to be a problem on this Picaxe input?

This "high " voltage is going to be the "Short Circuit" indicator ( if volts greater than 4.8 then alarm) so putting the zener there will take away this desirable feature. Zeners are not that precise that i can rely on the voltage (learned this from previous thread). I want this high voltage indicator without losing significant range on the adc input.

I do plan on pressure testing (with a bike pump) before the thing is installed next week.

Regards,
Michael
 

moxhamj

New Member
Sounds like you have it almost working. I can't see any major problems.

Re the zener, the standard dowload circuit to a picaxe allows RS232 +12V and -12V to be applied to a pin via a 22k resistor. I am presuming that a picaxe can handle that on any pin. I have taken the 10k/22k picaxe download circuit and applied RS232 voltages to the input of a 74HC04 chip and have been using that every day for the last two years and it hasn't blown up the input to that chip either. So maybe change your 10k to 22k which shouldn't affect the ADC (I've used 100k as an ADC protection resistor and the range seems unaffected). If you were being really paranoid about 24V getting in, maybe use a zener of 12V or so - well above the 5V of the picaxe yet enough to clamp the volts to RS232 levels which we know ought to be safe.
 

Michael V

Senior Member
That Makes sense

That makes sense, of course it can handle it via a resistor it the RS232 is 12V.

Since i'm going to power the transducers and sub board with 15V anyway, the 2 x transducer wires will just run to my box, there is no risk of 24V. a 22K resistor should do it, The Ocean Controls "protects" it's op amp with a 50K, and that will be expecting 24V on the input.


Thanks.
 

Michael V

Senior Member
Success and more challenges

Well, lots of field work for me. To Interface with my expensive $400 Industrial strength 4-20mA transmitter i have the attached circuit (diagram attached)

The 4-20 mA supply of 15 v goes through a high watt 100 ohm current limiting resistor before going into the transmitter. This is in case there is a short circuit in the transducer cable it doesn't blow a fuse or shut the unit down.

The 4-20 mA across the 240ohm resistor gives a voltage of 0.96 to 4.8 V over the 0-4 bar range of the transmitter. I found out in the field that if there is a vacuum applied (on a maintenance day) that i get a voltage of 0.84 V.

On the Picaxe 28X1 adc inputs i use readadc10 , and get a word variable from 0 to 1023. The pressure range is at 172 for vacuum, 193 for 0, 983 for full range of the transducer. Using code and Picaxe maths (max about 65000 in integers) i can record and display, Open circuit, Vacuum, the pressure, and Short circuit between the supply and the loop wire. Big improvement in functionality and reliability on the plain voltage transducer, for a really simple interface circuit (and a lot of $$, but will be worth it).

I have also used a 10K/47K voltage divider on the 15V so that i can measure if it fails, and record that and save the integrity of my data recording. . The picaxe has a battery backup prior to the 5V regulator This voltage reads 2.5V on the multimeter, and 450 on readadc10.

Machine no 1 is working perfectly, displaying and recording data, paying off already, so thanks again to great forum advice

So?

So, i duplicated the circuit again for machine no 2. The voltages measured at the input pins are exactly as described above. However, instead of reading a variable result from readadc10 i get either zero when there is no circuit, or 1023 when there is no pressure and 0.96V showing on my multimeter on the ADC input pins. This happens on ADC0 and ADC1. ADC3 has 2.5V on the pin and returning 0. Output is via SERTXD and via I2C to the LCD display..

This second picaxe could have been exposed to high voltage on the input pins in a former project. I am coming to the conclusion that this picaxe is fried. Is there any other explanation?

If it has been fried why is it doing all the things like distinguishing between open circuit and closed circuit, and outputting to the computer and LCD. If it fried why would it even be talking?

Hope you can help? Any other Advice?

I can see myself calling in at Microzed in the morning.

Michael
 

Attachments

hippy

Ex-Staff (retired)
Failure modes are a bit of a mystery. It's quite possible to burn out one part of a chip and have the rest work perfectly well.

I blew an 18X by mis-wiring an LCD contrast pot to an output line and shorted it to 0V. It worked fine apart from not being able to download anything ever again. Erased it and used it as a PICmicro and it's been 100% reliable ever since, all functionality passed testing. Things don't fix themselves and PICAXE firmware is no more succeptible than anything else but something I did confused something.
 
Top