Virtual Prox

skeet

Lifetime Supporting Member
Join Date
Jul 2005
Location
Lafayette LA
Posts
57
Hey All,

I've been playing around with the idea of creating a "virtual" prox/starwheel/gear whatever, for times, of course, when I don't have one, nor encoder, etc. Probably not a new idea, just kinda new to me.

For instance, on a rollcase or conveyor, knowing its speed, I could position/place/track things if I had some stable reference to clock a pulse. System clock? Scan time? Last scan time? (That's currently what I'm messing with at the moment.)

Harware is currently ControlLogix, but it prolly wouldn't matter I'd reckon...

Anyone here do this? What's the best method? Thanks!

Mike
 
skeet said:
Hey All,

I've been playing around with the idea of creating a "virtual" prox/starwheel/gear whatever, for times, of course, when I don't have one, nor encoder, etc. Probably not a new idea, just kinda new to me.

For instance, on a rollcase or conveyor, knowing its speed, I could position/place/track things if I had some stable reference to clock a pulse. System clock? Scan time? Last scan time? (That's currently what I'm messing with at the moment.)

Harware is currently ControlLogix, but it prolly wouldn't matter I'd reckon...

Anyone here do this? What's the best method? Thanks!

Mike

Yes. It's called an INTEGRAL. To get your position accurately, you need to integrate your velocity with respect to time. This is Physics 221.

The ControlLogix line has time stamping to the microsecond, so you can get pretty darned accurate if needs be.
 
Alrighty then...

CroCop said:
Yes. It's called an INTEGRAL. To get your position accurately, you need to integrate your velocity with respect to time. This is Physics 221.

The ControlLogix line has time stamping to the microsecond, so you can get pretty darned accurate if needs be.

Well, uh...thanks! But I don't care if any input is timestamped, Central, Mountain, or whatever. I also understand the relationship between time and velocity; it's the stable time-base I was looking for.

Maybe I didn't understand your post.
Thanks for your input though. (THIS is Courtesy and Manners 101)

Mike
 
Stable time base = time stamp between calculations. You can fluctuate slightly as long as you know how much it was with no problems.
No offense meant by INTEGRAL.
 
skeet said:
For instance, on a rollcase or conveyor, knowing its speed.
Well there is the trick. Use a quadrature encoder or absolute SSI encoder to get position. Now you will not need to integrate velocity. BTW, calculating velocity is covered in many threads on this forum.

BTW, this is done all the time.

CroCop said:
Yes. It's called an INTEGRAL. To get your position accurately, you need to integrate your velocity with respect to time. This is Physics 221.
What's that? :)

Seriously, the problem with integrating a tachometer or acceleromter is that there is an offset, that when integrated, provide inaccurate position information. It is best to use a device that provide position directly.

Some motion controllers have the means of using accelerometers to provide acceleration and jerk feedback. However, I don't know of any motion controllers that depend on accelerometers or tachometers to provide position data.
 
In the Allen Bradley 500 series, you can create a 'psuedo pulse train' using the free running clock status bits or using a selectable timed interrupt.

You'll probably have to have some sort of timer to accomodate for the conveyor coasting to a stop if you want your tracking to stay somewhat accurate through a shutdown.

I used this method on a re-write I did this week where there was no encoder for this exact purpose. It works well enough, but ideally, I'll go back and retrofit with a low resolution incremental encoder.
 
monkeyhead said:
In the Allen Bradley 500 series, you can create a 'psuedo pulse train' using the free running clock status bits or using a selectable timed interrupt.

You'll probably have to have some sort of timer to accomodate for the conveyor coasting to a stop if you want your tracking to stay somewhat accurate through a shutdown.

I used this method on a re-write I did this week where there was no encoder for this exact purpose. It works well enough, but ideally, I'll go back and retrofit with a low resolution incremental encoder.

Thanks, yeah I think the clock status bits are the way to go. It'd be nice to have that encoder, but I don't really need the precision.
Mike
 
Virtual Encoder

I use one type when the conveyor is not accessible or there is no room to put a pulse prox wheel on the take-up or non drive pulley. In CX you can put this in a program file that executes say every 30 ms. Use the Aux or coil output of the conveyor to add 1 to an Int each time the file is scanned. Then use bit 1 of this Int as An XIC. This XIC will pulse true every 60ms as long as conveyor is running. Every second scan the bit is true. 2 X 30ms= 60ms. It is not perfect, but works fine.
 
Bruce,

Yes! This is along the lines I was thinking, thanks! My scan times don't seem stable enough for this though. I thought using scans to trigger a counter would be good, but I'm missing something in this picture so far:)

Mike
 
skeet said:
Bruce,

Yes! This is along the lines I was thinking, thanks! My scan times don't seem stable enough for this though. I thought using scans to trigger a counter would be good, but I'm missing something in this picture so far:)

Mike

You are on the CLX line, right?
Create a task specifically for this.
Make it a timed task.
Give it a high priority.
The CLX will interrupt the task going and execute this task very quickly.

Should be a piece of cake with the CLX line.
 
Skeet, make sure that your "every X milliseconds" program file is in a Periodic Task. These can get very precise repeatability in ControlLogix. Your Continuous Task scantime is always going to vary a little.

I realize this is a project to make a virtual version of a "quick and dirty" feedback device. I wish I had a dollar for every time I had to make up another analogy to explain control accuracy to salesmen. "It's like typing with mittens"... "it's like sewing with a samurai sword".... "it's like measuring toothpicks with a yardstick"....

If you're running genuine ControlLogix motion, look into the virtual axis feature. A lot of systems use them to stand-in for absent or hypothetical machine elements.
 
Go with CroCop's idea to create a timed task. CLX is way fast, so even a high speed conveyor should be no problem. Just figure out what resolution you want/need and set it up based on that.

I used a timed interrupt on my project (SLC 5/05) and it was much more reliable than the clock bits. I was using a bit shift to track packages and I couldn't get the timing down. My STI routine was simple. A flip flop and a bitshift triggered every other time the routine ran (every 10ms) giving me a 20ms resolution. It's very predictable and works great.

And total sidenote: CLX blows me away. We have a system that uses encoder tracking and shifts 3000 16 bit words at every pulse of the encoder (roughly 65 pps) and it has no problem keeping up with scan times still under 1ms. That includes all the other silly stuff the program does.
 
CroCop said:
You are on the CLX line, right?
Create a task specifically for this.
Make it a timed task.
Give it a high priority.
The CLX will interrupt the task going and execute this task very quickly.

Should be a piece of cake with the CLX line.
Yup, CLX at the moment.
Ya know? I knew of this timed tasking, but didn't hook it in to this. I will now....Thanks again!

Bear with me and my at-times-stupid-questions. I gotta million of 'em:)

Mike
 
Ken Roach said:
Skeet, make sure that your "every X milliseconds" program file is in a Periodic Task. These can get very precise repeatability in ControlLogix. Your Continuous Task scantime is always going to vary a little.

I realize this is a project to make a virtual version of a "quick and dirty" feedback device. I wish I had a dollar for every time I had to make up another analogy to explain control accuracy to salesmen. "It's like typing with mittens"... "it's like sewing with a samurai sword".... "it's like measuring toothpicks with a yardstick"....

If you're running genuine ControlLogix motion, look into the virtual axis feature. A lot of systems use them to stand-in for absent or hypothetical machine elements.

Periodic Tasking. New concept for me, but hey.... I'm onnit now:)
"Virtual axis feature". Now, why does that sound intriguing? Ha!
I hear ya on the salesmen topic. Mine said that "all ya gotta do is use some timers, right?"

Uh....

Thanks, Ken. I gots homework to do:)

Skeet
 

Similar Topics

...and I agree. Context: TIA Portal/HMI = KTP1200 (12" screen) In the attached redacted image, the values in the white boxes are entered by the...
Replies
10
Views
602
Is there any way to use a Virtual HMI (running on a PC) with CCW? This is for an application where there will be an actual HMI (PV800) connected...
Replies
4
Views
381
i have a dell laptop with a real com port host OS is windows 10. Running VB 6.1.42 I cannot get the serial port to configure in VB. Please Help...
Replies
10
Views
989
My main laptop operating system is windows10. I have concept2.6 offline version. Since concept2.6 comply with windows xp, so i using vm...
Replies
2
Views
687
Hello !!! I'm commissioning a system that has two Kinetix 5700 Drives/motors going to driven wheels on the same physical axis. To keep them...
Replies
3
Views
1,686
Back
Top Bottom