Host Engineering Forum
General Category => Do-more CPUs and Do-more Designer Software => Topic started by: ERokc on November 14, 2012, 10:03:35 PM
-
I think I want a closed loop control using H2-CTRIO2 and GS2 VFD. I plan to use a quadrature encoder with the CTRIO2 and a Do-More CPU of course. I will use the CTRIO2 preset table for row positions and a drum for column points to fire for each row. Please don't suggest a stepper motor. They have there place but I don't want to use one here.
Let me back up and ask, will the CTRIO2 produce pulses to ramp up/down to a position having been given the count value for the position? I believe the axis control of the CTRIO2 is what I need. My application does not need speed variation within the cycle beyond ramping up, level off and ramping down and stopping at a specified position (hopefully a variable in memory). An emergency stop is needed if something wrong is detected and would be nice to ramp down as quick as possible, position irrelevant.
Jumping to the GS2 VFD, it takes discrete commands and has profiles within but I don't think there is a way to control where it stops. It has serial input but again I don't know how to translate a position from the CTRIO2 to serial data. GS2 has analog inputs with discrete direction but still the CTRIO's output is pulses.
I think a frequency to analog converter could do it. Is this the way to go or is there a better way?
Anyone know of a converter available? I could build one but it's always cheaper and much quicker to buy.
Is there a better way to control an AC motor. It needs to reverse and soft start/stop.
Give me your thoughts, am I on the right track?
Thanks, Dave
-
I think I want a closed loop control using H2-CTRIO2 and GS2 VFD. I plan to use a quadrature encoder with the CTRIO2 and a Do-More CPU of course. I will use the CTRIO2 preset table for row positions and a drum for column points to fire for each row. Please don't suggest a stepper motor. They have there place but I don't want to use one here.
Don't really know, we aren't apps guys. Pulse outputs are generally used with either steppers or servos, how it would integrate with a VFD is not something that I can answer.
Let me back up and ask, will the CTRIO2 produce pulses to ramp up/down to a position having been given the count value for the position? I believe the axis control of the CTRIO2 is what I need. My application does not need speed variation within the cycle beyond ramping up, level off and ramping down and stopping at a specified position (hopefully a variable in memory). An emergency stop is needed if something wrong is detected and would be nice to ramp down as quick as possible, position irrelevant.
Yes, CTRIO2 axis mode will do this.
Jumping to the GS2 VFD, it takes discrete commands and has profiles within but I don't think there is a way to control where it stops. It has serial input but again I don't know how to translate a position from the CTRIO2 to serial data. GS2 has analog inputs with discrete direction but still the CTRIO's output is pulses.
Again, not sure how you will get from pulses to analog.
Give me your thoughts, am I on the right track?
At first blush it feels like you are shoehorning the VFD when a servo might be a better choice. But again, nobody here at Host is an apps guys. Perhaps some of the real controls guys will chime in and offer some thoughts.
-
It sounds like you need a servo. A VFD is not a motion controller, but, depending on the speed and precision you need, it may be able to do the job. You cannot send a position signal to a VFD and have it go there, all you can do is tell it what direction to go, and how fast you want it to run (then you have ramps etc.). This can all be done easily with the serial port. There are sample programs for doing this over at AD's forum. Bcarlton has a really good sample for an 06 with stages that can be adapted to DoMore. Hope this helps...
-
BobO, is there a register in the CTRIO2 that represents the frequency of the output and can be read by the CPU?
Where I'm headed with this is scaling it in software to represent voltage then use an analog module in the PLC.
This is for the application folks. What I like about using a three phase motor and VFD is the cost is low. I will limit the motor speed to 2X normal hoping not to need an inverter grade motor.
Dave
-
Yeah. I'm guessing it is .OutputFrequency in the pulse output structure, but I'm not in front of a PC to confirm the name.
If you take the frequency and scale into an analog, I'm sure that it will kinda work. The question is how fast it will respond and whether the resulting slop is tolerable. Axis closed loop mode is not designed to handle wide disparities between target and actual position, but it will try real hard to get there.
Another possibility would be to run a PID loop on the target position and the encoder...encoder is PV and pulse output position is the SP. Scale the output into the analog driving the VFD...but trust me, I have no clue whether that would work. Like the previous example, I'm sure it would kinda work, the question is how fast and whether the slop was tolerable.
But I guess if you wanna get by on the cheap, you must be willing to compromise performance.
-
BobO, you must love your job to be working this late. Did you refrain from working on vacation?
I love my job too. The PLC part of my project gets attention at night.
After my last post I went looking for the answer to my question, found it! I use the full name to help me learn this stuff, $CTRIO_000_Out0.OutputVelocity. It's pulses per second.
I'm still learning the syntax of ladder logic and have not started learning Stage programming. What would scaling code look like to read the velocity, multiply by a factor then add or subtract an offset?
You answered another question I have about CTRIO adjusting to error in position as it ramps down. My app is NOT like a CNC mill that uses ball screws for +- 0.0002" accuracy with wide variations in speed, direction and load. It is much simpler. With the exception of needing to back out of a jam condition it will run one direction, conveyor style, and position accuracy is something like +- 1/16". The load variation should be slight. My encoder resolution is considerably better than required at 0.001" per pulse. My target speed is 12"/sec which is 12kHz pulse rate. That's what directed me to CTRIO, then I learned about preset tables, I can use that!
A question while I'm thinking about it, is $Main being scanned when $Programs are running?
Tell me more about PID. I know what PID is having used temperature controls that use PID. I don't know how they are implemented in the Ladder Logic or Stage programming. Do you mean the PID is used with the CTRIO axis control? Can you give me an example? I understand much better when I see examples.
I will know if this works only after putting it together and seeing what it does. I am never discouraged when something doesn't work on the first try. One of my virtues is patience and not giving up easy.
Thanks for your help. Dave
-
Actually, positioning using induction motors is very common in lower bandwidth high-hp applications like automated warehousing or automated rigid cranes and so on. When done properly, you'd never know looking at one of these applications except for the bandwidth that you're not looking at a servo app.
Now, "done properly" tends to mean vector grade drives running in torque mode with encoder feedback and not chintzing out on motor hp, but it does work and it works very well.
I've actually taken a motor elevating a load, and just let it hang there stalled without the brake engaged to see how it would do and it would hold position withing an encoder count or so for hours.
-
What would scaling code look like to read the velocity, multiply by a factor then add or subtract an offset?
Use the SCALE instruction.
A question while I'm thinking about it, is $Main being scanned when $Programs are running?
Everything is scanned every scan. Some things won't execute if disabled or not due, but yes, $Main runs all the time.
Tell me more about PID. I know what PID is having used temperature controls that use PID. I don't know how they are implemented in the Ladder Logic or Stage programming. Do you mean the PID is used with the CTRIO axis control? Can you give me an example? I understand much better when I see examples.
That one was a long shot. If you don't have specific experience with PID, I would not go there. The built-in closed loop behavior should be fine. It implements simple proportional control (defined by the Scale Factor) with a bit of real time fudge. The real time adjustments will clean up small amounts of slop on the fly, but even if it can't completely fix it, it will reverse to the target if needed. So you will hit your spot eventually, to within the specified encoder deadband. The only fear is that your control of the VFD isn't tight enough and you will end up oscillating.
-
...I'm guessing it is .OutputFrequency in the pulse output structure, but I'm not in front of a PC to confirm the name...
It's actually .OutputVelocity. erokc, there is an FAQ showing all the CTRIO structure members here: http://www.hosteng.com/FAQFiles/Do-more.htm#FAQ0028 (http://www.hosteng.com/FAQFiles/Do-more.htm#FAQ0028)
-
After my last post I went looking for the answer to my question, found it! I use the full name to help me learn this stuff, $CTRIO_000_Out0.OutputVelocity. It's pulses per second.
He had found it, Greg.
-
He had found it, Greg.
Yeah, totally missed that. ;D Ha! But the FAQ is useful. 8) Which reminds me, I need to make that available from the CTRIO FAQ page as well. Oops. :-\
-
I feel confident enough to give it a try. BobO, confirm for me, if the motor position stops within the dead band that satisfies the move? I would start with my tolerance of +- 1/16" or 63 counts. Don't know if dead band is entered plus/minus but will find out. As for your suggested SCALE instruction, of course! I previously printed the Do-More instruction set, I need to use it!
Controls Guy, explain bandwidth. Would that relate to the range of motor speed? Unlike your example my application will start with 3/4 hp, I'm expecting 1/2 will do it. I can set the VFD for 1/2 hp or less current and see where it fails to drive the machine.
Greg, I bookmarked the FAQ you mentioned. I am so new at this EVERYTHING is helpful. I am impressed with Designers HELP. Host has put a ton of information in it. The technical writers are good. Easy to understand and complete without extra unnecessary detail. I don't have to re-read statements, I get it the first time!
The machine is not ready for the drive so I'm having to wait for the trial.
-
BobO, confirm for me, if the motor position stops within the dead band that satisfies the move?
In closed loop, the output is computed off of the distance to target. Each time it needs to compute the next portion of the move it checks to see if the position is within the deadband and the frequency is at the minimum. If both conditions are true, the move is complete. If not, it computes the next movement that will get closer to the goal of not moving and within the deadband. So the short answer is 'yes'.
-
For crude positioning using a VFD I always start with the square root of the distance left to travel. That times an empirically determined constant gives me a nice smooth deceleration. To determine the constant I adjust between 'too fast, overshooting' and 'too slow, stalling before the end'. It gives acceptable performance with minimal math.
-
Controls Guy, explain bandwidth. Would that relate to the range of motor speed? Unlike your example my application will start with 3/4 hp, I'm expecting 1/2 will do it. I can set the VFD for 1/2 hp or less current and see where it fails to drive the machine.
The technical definition is if you were to feed the positioner a sinusoidal command, what is the maximum frequency command that it can follow to a certain degree of compliance.
In practice you can relate it to the ratio of positioning tolerance to top-end velocity.
-
I definitely have a low bandwidth application. That should work to my advantage using this method.
In an attempt to understand the CTAXTRAP instruction in Designer I discovered the yellow Instruction Help window has the description for CTAXLIMT instead. I'm guessing it was copied and pasted but not edited for the differences.
b_carlton, I don't understand how to apply your modified "distance left to travel". Is that applied using the CTAXTRAP instruction? I'm interested because I expect my control problems are going to be in hitting the target. My limitation is I can't reverse the machine and maintain correct material alignment. Material on the conveyor will always travel in one direction (except for un-jamming). I want maximum acceleration but hitting the target is a must. I can't know how hard that will be until I put the drive together and run it. I'm a few weeks away for that. If I have the option for a different slope on deceleration that's good.
OK, I had a thought, CTAXCFG might let me set acceleration, yes it does. Can I use variables or constants, YES. The green/red dots (GO/NO-GO) great feature in Designer. I'm liking Do-More, More and More.
I ran across the article that turned me on to CTRIO2. Automation NOTEBOOK issue 24, Tech Brief by Jason Horine. Jason says "When a servo is too much and a stepper is not enough, simple closed loop control might do the trick."That caught my attention but Jason didn't suggest what to use for driving the load. I think an AC induction motor and VFD might just work. I intend to find out.
-
I was using a counter card for position but then an analog output as a speed command to the VFD. I've even send the speed reference using relatively higher speed communication connection and achieved good results.
Get current position, subtract from destination, derive absolute value.
Take square root of the result.
Multiply by empirically determined constant.
Out to analog card (or communication instructions).
When within final 'good enough' window then stop. Our positioning mechanical system had enough friction and a high ratio worm gear that 'holding' was not necessary.
-
In an attempt to understand the CTAXTRAP instruction in Designer I discovered the yellow Instruction Help window has the description for CTAXLIMT instead. I'm guessing it was copied and pasted but not edited for the differences.
Yes, likely a cut and paste bug. Thanks for reporting it.
b_carlton, I don't understand how to apply your modified "distance left to travel". Is that applied using the CTAXTRAP instruction? I'm interested because I expect my control problems are going to be in hitting the target. My limitation is I can't reverse the machine and maintain correct material alignment. Material on the conveyor will always travel in one direction (except for un-jamming). I want maximum acceleration but hitting the target is a must. I can't know how hard that will be until I put the drive together and run it. I'm a few weeks away for that. If I have the option for a different slope on deceleration that's good.
You wouldn't use his concept with the CTRIO's pulse output. He is describing an alternative method of controlling the motor that is used in lieu of the the CTRIO's output. I would suggest that you start with the CTRIO's output, and then only get into rolling it yourself if it doesn't give you the desired result.
-
In an attempt to understand the CTAXTRAP instruction in Designer I discovered the yellow Instruction Help window has the description for CTAXLIMT instead. I'm guessing it was copied and pasted but not edited for the differences.
Fixed. This will show up in the next maintenance release of Designer.
-
Actually, positioning using induction motors is very common in lower bandwidth high-hp applications like automated warehousing or automated rigid cranes and so on. When done properly, you'd never know looking at one of these applications except for the bandwidth that you're not looking at a servo app.
Now, "done properly" tends to mean vector grade drives running in torque mode with encoder feedback and not chintzing out on motor hp, but it does work and it works very well.
I've actually taken a motor elevating a load, and just let it hang there stalled without the brake engaged to see how it would do and it would hold position withing an encoder count or so for hours.
Do you have a example of how you did this?
-
Do you have a example of how you did this?
Did what? Servoish motor control or one count accuracy?
If you mean that application in general, one example would be a Control Logix with motion control cards receiving the encoder signal and controlling AB 1336-FORCE drives in either torque or velocity mode (and with no direct encoder feedback). We had 5hp horizontal axes moving approx 2,000 lbs at 300-400ft/min and stopping smoothly +/- 1/4". Don't remember the hoist axis hp or speed, probably also about 5hp and say 100ft/min. You could do the same with any appropriate VFD and a standalone motion controller if the PLC you want to use doesn't have a motion controller card that will work for your app.
As far as the one-count goes, that was part good design / commissioning and part luck / random chance. It was well tuned, but even so it was a little better behaved than other supposedly identical axes. I actually just left it there for hours with the brake off just to see how long it could do that. So, while it's not literally representative, my point in saying that was to show that positioning with induction motors is very practical.
-
Do you have a example of how you did this?
Did what? Servoish motor control or one count accuracy?
If you mean that application in general, one example would be a Control Logix with motion control cards receiving the encoder signal and controlling AB 1336-FORCE drives in either torque or velocity mode (and with no direct encoder feedback). We had 5hp horizontal axes moving approx 2,000 lbs at 300-400ft/min and stopping smoothly +/- 1/4". Don't remember the hoist axis hp or speed, probably also about 5hp and say 100ft/min. You could do the same with any appropriate VFD and a standalone motion controller if the PLC you want to use doesn't have a motion controller card that will work for your app.
As far as the one-count goes, that was part good design / commissioning and part luck / random chance. It was well tuned, but even so it was a little better behaved than other supposedly identical axes. I actually just left it there for hours with the brake off just to see how long it could do that. So, while it's not literally representative, my point in saying that was to show that positioning with induction motors is very practical.
I'm looking at an elevator appilication that uses induction motors that I need to hold position till the brake can set. I looking at using a Do-More, CTRIO-2 and a GS3 drive with encoder feed back. it the hold till the brake can set and realse that I not quite sure of.
-
I hear the word "elevator" and it makes me nervous! ;D
You're not elevating people, are you? Or elevating stuff over space where people could be? If so, beware of liability. For the VFD companies for which I know one way or the other, they have special drives with special firmware for crane apps (and that's not even for elevating people). ABB ACS-800's (the generic ones, though I don't doubt the crane ones have it too) have a torque proving feature so you can guarantee you have torque before releasing the brake.
-
I hear the word "elevator" and it makes me nervous! ;D
You're not elevating people, are you? Or elevating stuff over space where people could be? If so, beware of liability. For the VFD companies for which I know one way or the other, they have special drives with special firmware for crane apps (and that's not even for elevating people). ABB ACS-800's (the generic ones, though I don't doubt the crane ones have it too) have a torque proving feature so you can guarantee you have torque before releasing the brake.
Its a material lift that is part of a convoyor system so using lift may be a better way of talking about it. Hitachi SJ300 and a Siemen Micromater 440 have that featrure.