Sign in to follow this  
Followers 0
Guest paulatncl

Analogue sinewave generator using flexlogix 5434

9 posts in this topic

Hi everyone, I'm an intern student new to the world of plc programming using rslogix 5000 (2 weeks and not what I should be doing?). I'm working on a simulation project for resonance testing of wind turbine blades and so far using this site and documentation managed to produce a PID control loop for the actuators and position feedback but I'm having problems with using a separate flexlogix to produce the sinusoidal references. I began by using an timer and using that infomation in the form of sin(wt) where the w was a predetermined value (simple but it worked). However, since the introduction of pots to control frequency (max 3Hz) and magnitude, I am getting distortion introduced in the analogue output randomaly, however the period and magnitued are ok. So a few questions (tell me I'm an arsehole if not relavant!), I think its possibly to do with updating the i/o and timing issues: Is there an internal clock that the I/O can sync to, and if so how? Would using periodic tasks help correct the issue and how does the conectivity work between them and the main program? I'm mainly looking for ideas, suggestions, examples and anything to read primarily for my own self development since this stuff is useful and interesting; since I cannot provide what I've done due to company bollocks and access. Any pointers or comments would be very much appreciated since I'm at a loss! Cheers to you all for the information you've already provided indirectly, Paul.

Share this post


Link to post
Share on other sites
Paul: If I am not mistaken the Flexlogix can support motion modules of Logix 5000. An imaginary axis would allow you to with the aid of a cam function create a true sine signal. You might even be able to feed you Freq and Ampl signals into to motion block logic. THis might improve performance. Don't know about the other questions.

Share this post


Link to post
Share on other sites
You are using the wrong tools for the job. What you need is a motion controller that can connect to the flex logic but in reallity you need a motion controller that can connect to a data acquisition computer. Generating a position sine wave is not enough. You should also generate the velocity, acclerations and maybe even the jerk motion profile so you can use feed forwards. PLCS do not have deterninistic control loops. They have a lot of jitter which you have noticed. A motion controller does all of its I/O in a FPGA which is very deterministice. Also, you need something that can acquire data at deterministic intervals too.

Share this post


Link to post
Share on other sites
Cheers for the response, all is worth a try. I'll check it out tomorrow and see if it I can make sense of it. Paul.

Share this post


Link to post
Share on other sites
ftp://ftp.deltacompsys.com/public/jpg/sinewave.png I did this in the time between the posts. If you have the right tools it is easy. This is a graph of a motion ocntroller generating a target velocity and position profile and controlling a load. Notice how well the actual position and velocity track the target position and velocity. The two position and velocity lines are almost on top of each other which is good. The lines are color coded. The fuzzy green line is the control output. It is fuzzy because of quantizing errors due to low resolution feedback. The load has a natural frequency of 10Hz and a damping factor of 0.1. It is almost like a slinky.

Share this post


Link to post
Share on other sites
You definately would want to use a periodic task to schedule your update Maybe I missed it in your post but what are you planning on actually generating the sine wave with? I am toying with the idea of doing something similar with a 1756-IF4FXOF2F. I have no clue how this will work but I am thinking about setting up a test.

Share this post


Link to post
Share on other sites
Cheers for the info, new to this game so useful arguments if (when?) it goes pear shape for report! Basically I'm using what I've been given and to a certian extent it does works but still plenty of issues.

Share this post


Link to post
Share on other sites
OK, just realize that in real life there is a trade off that must always be made between having the right tools and doing on the cheap. I have spent just as much time typing these posts as getting that example program to go. That include the sine wave generation and tuning to control the load so it follows the sine wave.

Share this post


Link to post
Share on other sites
Peter, Appologies if I came across a little abrupt since I know your right! I already had issues when I started but did'nt understand or know how to articulate them, just a feeling. You've gave me ammunition for my argument so thankyou. I don't under stand why the don't let me use a couple of calibrated HP signal generators with triggering or the NI data acquistion kit that they have sat outside my room, but I'm pretty much in the dark? Possibly trying to either push me or the technology to see what they get! Anyway cheers again of the advice, Paul

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0