Sine wave 2Hz 4-20mA

emil.wojda

Member
Join Date
May 2012
Location
Aberdeenshire
Posts
5
Hi,

Any idea how can a generate a sine wave signal of 2Hz where the output is an analogue 4-20mA? This is required for a proportional pressure relief valve control. The valve itself can go from fully close to fully open in 60ms.
I am looking for low-cost solution. I don't think a low cost compact PLC with an analogue output card is capable of doing this due to a scan time. Any ideas?
 
I'm a little bit confused on your numbers, but I might simply be unfamiliar with the application. 2Hz is pretty slow, I think almost any low end (micro) PLCs could handle that, depending on the accuracy you need. 60ms is a lot faster. What exactly do you need your output to do?
 
Google
frequency to analog converter

It is a a standard signal conditioning module, lots of manufacturers.

There is some loss of resolution in a conversion to analog/current, but you get a conventional signal out of it.
 
Last edited:
I'm a little bit confused on your numbers, but I might simply be unfamiliar with the application. 2Hz is pretty slow, I think almost any low end (micro) PLCs could handle that, depending on the accuracy you need. 60ms is a lot faster. What exactly do you need your output to do?

I need to build a control panel for my costumer. The panel will control a flushing hydraulic rig, the process is to allow fluid to reach an external unit to be tested (a valve) and flushed.
I just need that valve going the full range twice per second from min to max (4 – 20mA) when it is in auto position.

This is what I need to clarify - this is a low budged project so high spec PLC in not an option. I am wondering if a low cost compact PLC with an analogue card can handle it.
 
I'm reading this as the OP wants a 4 to 20ma analog output to ramp up and down in a sign wave pattern. I could be wrong though.

What triggers the output? Is it continuous or is it stop/start control?

Does it have to be a sign wave, can it be a sawtooth?

Most PLC's can be programmed to ramp a 4 to 20ma output up and down.

https://www.google.com/?gws_rd=ssl#q=4+to+20+ma+ramp+generator

http://www.plctalk.net/qanda/showthread.php?t=86271&highlight=sign+wave

"Ramp generator" - I was always googling for a "sine wave generator" and never managed to get such a promising results. Thank you Mickey!
 
welcome to the forum ...

I'm not sure that this is what you're looking for – but here is a sample of some math which will give you a sine wave with a period of two seconds ...

this is the code from an Add-On Instruction that I use for testing various analog devices ... the output signal could be fed into an analog output module – which (if properly scaled) should give you the 4 to 20 milliamp output that you requested ...

I've chosen the Maximum and the Minimum values based on "best guesses" of what your system will need – but if they're not correct, then post again and we'll help you come up with some numbers which will fit your equipment ...

DISCLAIMER:

I'm just GUESSING at what you're looking for ... the more detail that you put into your questions, the more detail we'll be able to put into our answers ...

I hope that this helps ... good luck with your project ...

PS Edit ...

I just noticed that Mickey seems to have come up with another way of getting the job done ... I'll go ahead and leave my post here in case someone else ever passes this way in search of an actual Sine Wave signal ...

.

Sine_Wave.jpg
 
Last edited:
"I need to build a control panel for my costumer. The panel will control a flushing hydraulic rig, the process is to allow fluid to reach an external unit to be tested (a valve) and flushed.
I just need that valve going the full range twice per second from min to max (4 – 20mA) when it is in auto position. "

Are you sure that a hydraulic valve will be able to stroke the full range twice per second - sounds very fast for what I assume is a mechanical valve?
 
regarding the comment from rdrast:

Verify your times. 2Hz is not 2 cycles per minute.

this brings up a point ...

in my previous post, I had my "period" set for 2000 milliseconds ... oops! ... for 2Hz it should have been 500 milliseconds - as shown below ...

or at least I "think" so - based on the average of about 3-4 hours of sleep I've been getting lately ...

(the earlier trend was 10 seconds long) ...

.

2Hz.jpg
 
Hi,

Any idea how can a generate a sine wave signal of 2Hz where the output is an analogue 4-20mA?
Yes, what is the amplitude?

required for a proportional pressure relief valve control. The valve itself can go from fully close to fully open in 60ms.
A relief valve is not a control device. It is a safety device. 60 milliseconds from fully closed to fully open is slow.

I am looking for low-cost solution. I don't think a low cost compact PLC with an analogue output card is capable of doing this due to a scan time. Any ideas?
I don't think you will find a good cheap solution.
 
regarding the comment from rdrast:



this brings up a point ...

in my previous post, I had my "period" set for 2000 milliseconds ... oops! ... for 2Hz it should have been 500 milliseconds - as shown below ...

or at least I "think" so - based on the average of about 3-4 hours of sleep I've been getting lately ...

(the earlier trend was 10 seconds long) ...

.

Interesting function block. Is this a standard RS Logix 5000 FB?
How would the conversion time from digital to analogue + scan time affect the analogue output?

I need to gather more information from my client in terms of what exactly this machine suppose to do.
You and Mickey provided enough information to keep me busy researching for a while.
Thank you for your help guys!
 
A relief valve is not a control device. It is a safety device. 60 milliseconds from fully closed to fully open is slow.

Peter makes an excellent point. If this is a safety system, then your cost just went up, and you had better know what you are doing.
 
Peter makes an excellent point. If this is a safety system, then your cost just went up, and you had better know what you are doing.

This is what I received from my costumer:

Proportional Relief Valve: This valve has to follow two selectable patterns, both patterns have to be able to be chosen using a 2 position selector labelled as “Auto” and “Manual”. When in “Auto”, the valve shall receive a sine wave signal of full range (4 – 20mA) and at a 2Hz frequency. When in “Manual” the signal of 4 –20mA shall be controlled by a potentiometer installed close by to the selector and be labelled as “Pressure Regulator”. The Real Max value of the output to the valve shall be around the 19.71mA mark as the max desired setting for it shall be 345Bar. It shall be possible to micro limit the max output in order to adjust the max pressure during rig FAT phase.

I've been asked to build the control panel not the machine. I hope my costumer knows what he's doing.
 

Similar Topics

Hello Experts, I am trying to create a SINE Wave generator and i cannot seem to make it smoother. I have done this before but i forgot the exact...
Replies
6
Views
291
Hi dear forum, I need to create a test sine wave that so that I could check settling time in bidirectional inverters. Function that needs to run...
Replies
12
Views
1,168
Hi does any one have or know where I can obtain a function to generate a slow sine wave output of 4-20 ma with variable frequency and amplitude...
Replies
3
Views
3,452
Anyone have an examplen on how to generate a sine wave in Structured text. Help much appreciated, thanks in advance!
Replies
10
Views
6,623
Hi, I am trying to produce a sine wave from an omron plc model : CJ1H I want to do it in ST if possible. I am only learning Structured Text...
Replies
4
Views
2,692
Back
Top Bottom