Complete Noob - 1-5v/4-20mA input advice

Hi,

I'm after some advice, not the most clued up on electronics so please be patient.

I'm hoping to input either a 1-5v or 4-20mA signal into one of the Arduino boards, as part of a small project I am currently undertaking.

I suppose I need to know:

Is it going to be feasible with either signal?
If so, which type of Arduino am I best off using?

Any and all advice would be most appreciated.

Sam

milliamps doesn't really matter for input since the arduino inputs are high impedance it wont go though the chip, for a voltage that ranges from 1 to 5 volts you would want to use the analog inputs, which any arduino has, its just a question of how many

Thank you for the reply.

There will be 4, 1-5v inputs. I'll be honest I need to do some more research in the capabilities of Arduino, but I hope to use the four inputs within a basic code to produce a value of surface level. i.e. a pair of 1-5v will be used for one axis, with one signal per direction. With the intention of being able to produce a direction and level value for two perpendicular axes. I appreciate that isn't the clearest of descriptions, but I'm just trying to gauge whether Arduino is suitable for this application and how difficult it is to achieve.

Sam

Post more details about the project. How are you getting the 1-5V and how are you measuring the 4-20mA?

Here's a similar thread: http://forum.arduino.cc/index.php/topic,6378.0.html

Judging from what you said, I'd say just get the Uno - it's the standard even though you could probably save a couple $$ by just getting the nano (if it has enough analog pins - I haven't checked). It's also important to figure out how you're going to supply the power for these "5V" signals and how they're going to be grounded. If the 1-5V + 0-20mA are grounded to the Arduino (i.e. sharing a common ground), you'll get usable readings by simply splitting off the input into two wires going to your analog pin and ground pin/rail. Using only wires, you are creating a resistive voltage divider because wires do have a small resistance in them. You may want to add some resistors that are significantly larger than the resistance of the wires to replicate the voltage divider seen here: Voltage divider - Wikipedia. The reason for this is because you will want the effects of the resistance of the wire to be negligible in your calculations. The tradeoff here is that you will have a smaller voltage window and ideally you want your voltage window to be between 0-5V. If you want to do that, you'll have to use an op-amp (advanced).

More on Voltage Dividers: One of the easiest ways for measuring voltage is to use a resistive voltage divider. To do this, you'll have your incoming voltage connected to two different resistors. Those two resistors are then connected to ground and an analog input pin. You should definitely read the Wikipedia articles: Current divider - Wikipedia and Voltage divider - Wikipedia.

Also keep in mind if your sensors are 4-20ma 'loop powered', it will mean you need to provide the loop voltage to develop the loop current, 24vdc is kind of standard but many (most?) will operate down to 12vdc or so. Once you have the current measurement loop working then forcing the loop through a 250 ohm resistor will provide a 1-5vdc voltage drop which is suitable for direct connection to the arduino analog input pins. Note that there must be a connection made from the loop voltage supply's negative terminal and an arduino ground pin.

Lefty

blzalewski, retrolefty, thank you both for your replies.

My apologies, I should have been clearer in my description, but I plan to use either 1-5v OR 4-20mA inputs (depending on which is more straightforward to implement with Arduino, as I know one can be produced from the other with the use of a 250 ohm resistor). Judging by what has been said, and I have read on the the first link, I believe the 1-5v will be the most straightforward.

Currently I can (theoretically) achive 1-5v that is produced from a similar version of the below circuit. The first Vi is fed from an inductive coil and some more signal conditioning. The coil produces an approximate voltage range of 0-50mV, this is amplified to 0-500mV, then rectified; it is this 0-500mV that is input into the below circuit to produce 1-5V. Up to now the entire circuit has been tested in Electronics Workbench and it appears to be feasible. However, only the attached part of the overall circuit has been tested in practice in a previous project and successfully produced 1-5V when input with 0-1V.

So, the overall idea is to produce four, 1-5V inputs that will be used in a small piece of code to display a value between 0-45 degrees (surface level) for two axes in two directions (although I first need to learn how to write Adruino compatible code, but that I will address again).

N.B. The attached circuit has been replicated in form, but some of the resistor values have been tailored to obtain the required gain for this application.

Thanks again,

Sam

The 4-20 mA current loop is a very robust sensor signaling standard. Current loops are ideal for data transmission because of their inherent insensitivity to electrical noise. In a 4-20 mA current loop, all the signaling current flows through all components; the same current flows even if the wire terminations are less than perfect. All the components in the loop drop voltage due to the signaling current flowing through them. The signaling current is not affected by these voltage drops as long as the power supply voltage is greater than the sum of the voltage drops around the loop at the maximum signaling current of 20 mA.

Do 4-20mA whenever you have chance.