Calculating rate/velocity with speed and position

_Dock_

Member
Join Date
Sep 2015
Location
KY
Posts
508
Seems like this should be a simple thing but I’m struggling with it.

The basis is that I am trying to detect if a linear assembly is stopped or obstructed when the motor is being commanded to run.

I have the speed data using the output frequency of the drive and the gearbox ratio.

I have position of the assembly using a laser time of flight sensor through I/o link.

So I have speed, I have position, how do I get rate or velocity? This doesn’t need to be super accurate. I’m just trying to throw an alarm if the position of the assembly is not keeping up with what the speed should be.

I’ve tried several things but I can’t get a constant variable at a set speed I can compare to.

I’m using a compactlogix, any suggestions to a down and dirty simple way to accomplish this?
 
Do you have role diameter?
ExpectedLinSpd = Mspd(rev/min) * (1/GearRatio) * ( 2* pi() * Radius(in)) * (1/60(sec/min)

And you have instantaneous (or so) linear position of something.
For actual Linear speed, you would setup a timed interval (either a timer, or interrupt or somehing) to trigger a calculation at a specified interval.

Exampl psuedo code assuming 1 second time interval for calculation:

DeltaPos = LinearPos - LastLinearPos
LinearSpdAct = DeltaPos / TimeSec
LastLinearPos = LinearPos

The trick is to be sure and get the units correct. Ie. if you want to do the caluclation every second, but calculate IN/MIN you need to do the units conversion.
60sec=1min
LinearSpdAct = DeltaPos / (TimeSec * (1/60))


Once you then have estimated linear spd and actual you can do with what you want.




So you need to get your calculated speed ref into units of linear distance/time (ie. in/sec).

You then
 
velocity = distance divided by time interval

you have a speed reference, not the speed !
just because you tell the drive to go 60 rpm at the gear box output, doesn't mean that is what you get.
we have to go to each vfd here with a tach to determine the actual rpm speed out of the gear box.

what is the motor / gearbox driving?
even if the conveyor(for example) jams, the gearbox may still turn.

james
 
velocity = distance divided by time interval

you have a speed reference, not the speed !
just because you tell the drive to go 60 rpm at the gear box output, doesn't mean that is what you get.
we have to go to each vfd here with a tach to determine the actual rpm speed out of the gear box.

what is the motor / gearbox driving?
even if the conveyor(for example) jams, the gearbox may still turn.

james

This is exactly what I’m trying to detect. The laser sensor is mounted on the gantry to a fixed flag. If the motor is running at x speed the linear distance measurement should increase or decrease at a rate based on what the speed should be. If the linear measurement isn’t keeping up with what the commander speed is then alarm. There is a torque limiter on the drive so slip won’t hurt it I’d just like to detect it so it doesn’t sit there and slip until a time out occurs. The gantry is 50 feet long. If it starts slipping at the start of either end that’s a long time to sit there and slip before a timeout.
 
Speed is the same as velocity and it looks like you have this from the drive. You would need to calculate the speed/velocity from the laser. Speed is the distance traveled for a unit of time. Calculated these from the laser position values at even intervals making sure units are the same in the end and then compare the difference. If your speed isn't linear (like during accel or decel) you will need to account for the average speed of the motor during the same time period

Ken

Ken
 

Similar Topics

My application includes positive displacement gear type flow meter (500 pulses per liter). PLC is ML1400 I need to totalize the fluid being...
Replies
12
Views
2,864
I have a vibratory conveyor that is being fed from another conveyor. The feeding conveyor does not always deposit a consistant flow of "product"...
Replies
14
Views
5,231
Hi All novice question. Using RSLogix 5000. If rate is (quantity/time) in real format. I want to calculate the time left (Min:Sec format) to...
Replies
5
Views
2,402
This application has a motor with encoder feedback that drives a linear actuator that moves in/out, and is at roughly 45 degs from horiz. As the...
Replies
19
Views
1,296
I need to keep a running pass/fail yield of the previous 5,000 parts produced. I have used this formula before to calculate average: AvgValue =...
Replies
6
Views
2,114
Back
Top Bottom