Analog output with proportional or some control using Arduino

Hi.
I am designing a compression testing machine for my last year of the mechanical engineering course. For the machine to work without much human interference, I need to use a numpad, an lcd display, one pressure sensor, a gate valve, and one pressure reducing valve (the link for the pressure reducing valves is here ). I was initially trying to use a PLC with some assistance of a friend pursuing electronics engineering, but she advised me that an arduino would be a better option. The valves are to be mounted for the hydraulic circuit which I will be using to compress a metal block.

What I want to do is for the arduino to be able to control the analog output(4 to 20mA) to be given to the PRV by comparing a set value given by the user using the numpad and the analog input(4 to 20mA) from the pressure sensor. The value needs to be displayed on the lcd as it is being typed. The the arduino must close the gate valve and lock the pressure for 30 minutes after the above set pressure is achieved.

I have no idea how to compare these two values (proportional control maybe?) or how send an analog signal to the PRV. Please help.

update: Another friend suggested using SCADA and control the machine using a PC but the shop floor guys who will be using it are not so comfortable with a delicate PC in their already congested and messy factory floor.

My background: As I said above, I will be completing my Bachelors in mechanical engineering this year. I am completely new to Arduino, and have completed the led blink and servo motor sweep tutorials using 123d Circuits , but nothing more. I do not own an aduino, but am planning on buying one.

as far as the arduino is concerned, here is what you have'

keypad input
LED display, 2 or 4 line
analog input for pressure sensor
analog output for 4-20 - proportioning vale
?? output to close valve - gate valve

all this is possible for an Arduino UNO or NANO.
I prefer the NANO because of the screw shield. you do not want to use the UNO plug in headers.

the 4-20 output needs more details. the valve is offered in 0-10VDC by the way
but for 4-20 you will need a separate circuit. preferably a 0-5 in an 4-20mA out. an alternative is a serial in and 4-20mA output.

another option is to use a DIN controller. as a set-pont controller, you can menu-select the setpoint
tell it to run or not. and with the arduino, you can tell the DIN controller to run, pause, go hi or low, etc.
the Arduino options you did not mention

data logging for decay of pressure.
start stop sequence
countdown timer
other LED's to indicate other things.

Thank you for the reply. I wasn't aware of the arduino being capable of sending out analog signals. I was under the impression that the arduino could only accept analog signals and input as well as output only digital signals. Thank you for clearing that up.

The valve in the above link has both versions- 0 to 10V and 4 to 20mA (pg 8 in the linked PDF). I read on many websites that the 4-20mA option is more reliable than the 0-10V one. Is this true, and if it is, is the extra circuitry worth the advantages?

The 'mechanism' in the question is just half the story. Two such 'mechanisms' will be required, the second one getting activated after the 30 minutes of the 1st one end. I also need the arduino to take a signal from a two hand safety kind of switch (two pushbuttons) and start two induction motors as well as start the first 'mechanism'.
In total, there are two analog inputs, four analog outputs, seven digital outputs (two LCDs, two direction control valves with two solenoids each, and another dcv with a single solenoid) and two pushbutton inputs from the two hand safety switch.

Would a megarduino suffice for this project?

Sorry for this massive letter. I tend to type as I think.

4-20mA, to do it well, requires some additional circuity.
0-10V is a bit easier as all you would need is to use an FET with some simiple circuityry.

the Analog out is PWM, in one sense, it is just digital, but PWM can be filtereed to be varialbe.

4-20 is imune to noise that is typical in an industrial enviroment, radio frequence signals, other generatted EMF, etc.
but you pay for it by my design costs up-front.

if your panel is more than 50 feet from the valve, you might want to use twisted shield wire or hard pipe (metal conduit)

sujit1618:
Thank you for the reply. I wasn’t aware of the arduino being capable of sending out analog signals. I was under the impression that the arduino could only accept analog signals and input as well as output only digital signals. Thank you for clearing that up.

The valve in the above link has both versions- 0 to 10V and 4 to 20mA (pg 8 in the linked PDF). I read on many websites that the 4-20mA option is more reliable than the 0-10V one. Is this true, and if it is, is the extra circuitry worth the advantages?

The ‘mechanism’ in the question is just half the story. Two such ‘mechanisms’ will be required, the second one getting activated after the 30 minutes of the 1st one end. I also need the arduino to take a signal from a two hand safety kind of switch (two pushbuttons) and start two induction motors as well as start the first ‘mechanism’.
In total, there are two analog inputs, four analog outputs, seven digital outputs (two LCDs, two direction control valves with two solenoids each, and another dcv with a single solenoid) and two pushbutton inputs from the two hand safety switch.

Would a megarduino suffice for this project?

Sorry for this massive letter. I tend to type as I think.

I would say that no matter what platform, you should create a list of I/O pins for your own reference.
the simple NANO/UNO have about 20 pints you can use, but you loose some when you add displays.
the MEGA offers so many pins that it becomes moot. and offers more programming memory.

as I understand, you would press and the menu would pop-up.
you would input your desired setpoint, and possibly test duration, and possibly ramp up speed.
you would watch the for the settings.
then press to get things moving. the RUN switches could be wired in series, no need to 2 inputs.
to solenoid to open
<2 OUTPUTs> to two induction motors

get your list of the pins you expect to use.
figure I2c for the display, that is simple enough.
the ARDUINO has limited, or more correctly dedicated, PWM pins for PWM output.

but, the whole project does sound like it would work.

I would highly recommend a screw terminal board for connections. not sure who offers screw terminal boards for the mega…