2 proxs on gear to increase resolution

What I have done for a similar situation as add a sprocket in the shaft with a chain going to a sprocket 1/4 the size. Watch the teeth on the smaller sprocket and you have 4 times the resolution. If you need higher then change the ratio of the 2 sprockets. If the chain is taught there won't be any play or slack in the reading.
Even mounting a finer pitch gear or sprocket to the shaft will work also.
To over-engineer it add a resolver on the shaft and you will precisely know the speed.

Yes. This would be the ideal solution but would require a mechanic. I may eventually go this route depending on time and mechanic availability.
Thanks
David
 
I thought about adding another prox to increase the resolution but couldn't figure how to adjust the HSC function file MOD.


pulse multiplier via phase-locked loop might be simpler.


or run the prox to an either-edge detector for the HSC to count both falling and rising edges, but that only doubles the count.
 
Why not count motor revolutions
1 pulse per motor revolution or even 2 or 4 PPR
to use 2 channels of the HSC they should be 90 deg apart to accurate
what you need to count is more pulses on the same channel even on a 2pole motor it would still only be 3600 per min. The HSC is capable of reading many times that

I have an adjustable gearbox between the motor and drive GaryS.
Thanks.
David
 
Use the Event Input Interrupt (EII) Function File (cf. this link) to execute a Program File on every rising edge of the prox. Have N255 as a 43-element Data File. Store the time (10kHz Free-Running Clock (FRC) count) of each prox edge. This is what the Program file could do:

MOV S:4 N255:41 ### Measure 10kHz FRC count
MOV N255:[N255:40] N255:42 ### Restore count of previous edge of prox for this tooth
MOV N255:41 N255:[N255:40] ### Store count of current edge of prox for this tooth
ADD N255:40 1 N255:40 ### Increment tooth index
GRT N255:40 39 CLR N255:40 ### Rollover tooth index
LES N255:41 N255:42 BST OTU N255:41 NXB OTL N255:42 BND ### Handle FRC count rollover.
SUB N255:41 N255:42 F254:0 ### Calculate clock count difference
DIV 600000.0 F254:0 F254:0 ### Convert to RPM in F254:0

The interrupts can only occur at the start of a rung (of the continuous task, or any lower-priority task, presumably), or any time during End of Scan (cf. this link). At 500RPM, the number of FRC counts per revolution is 1200 (60*10000/500), so the resolution is about 0.08%, or about half an RPM, per wobble bit in the interrupt timing; at 200RPM it's about 0.03% or a sixth of an RPM. Increasing the size of the data file by a multiple of 40 drops those numbers by that multiple.

drbitboy. Thanks for your very detailed posts. I've not messed with an EII yet. I had something like that in mind when I started this thread.
Let me digest everything here.
Thanks.
David
 
Ideally I would like to get the RPM to +/- .1 RPM


Running the S:4-based (10kHz FRC) approach out to six cycles (240 FRC count entries in N255) may get you to this level at 500RPM.

That assumes the S:4 measurement resolution (EII) is ±1 count, which may be a bit ambitious (continuous scan times on my MicroLogix 1100 are typically 7-12 S:4 counts), but filtering should get you the rest of the way there.


Also, I think the code suggested has a problem with integer overflow when speeds go below ~110RPM (500RPM * 7200 / 32k) for the six-revolution time base.
 
Ideally I would like to get the RPM to +/- .1 RPM
Thanks Peter.
David


I have worked on conveyor spray lines that had a small 10V generator on the far end from the driven shaft, wire that to an analog input and that should get your 0.1% tolerance easily. If it's a reversible drive make sure the input is +/-10V.


Also in the Downloads section here is a RSL program to calculate speed between 2 sensors. It is written to calculate MPH between sensors 8.8" apart, but can easily be modified for different distances and speeds, even RPM of a known circumference.



Also in my experience relying on a mechanic in the PLC field is not normal unless it's a union shop. I have had to design and modify many components to get the PLC running as the customer wanted - if it wasn't running the cause was the PLC regardless of what needed to be done to the equipment, and a lot of the time their maintenance staff was not made available. Plus, if it's your employer, get them in the habit of allowing physical changes to accommodate updates.
 
Last edited:
An equivalent what OP probably has now:

TON the_ton 0.001 1000 0 ### 1s timer

XIC T4:0/DN BST MUL HSC:0.ACC 1.5 F254:0 ### RPM
NXB RES T4:0 ### Restart timer
NXB RAC HSC:0 0 ### Reset HSC
BND


A similar approach with 0.1RPM resolution down to around 200RPM:

XIC S:1/15 BST RAC HSC:0 0 ### Reset HSC (First-pass)
NXB FLL 0 #L255:0 16 ### Initialize array
NXB CLR N7:0 ### Initialize index
BND

TON T4:0 0.001 1000 0 ### 1s timer

XIC T4:0/DN MOV HSC:0.ACC L255:16 ### Get current count

XIC T4:0/DN BST XIC L255:[N7:0]/31 ### Lo is negative
NXB XIO L255:16/31 ### or Hi is positive
BND
SUB L255:16 L255:[N7:0] L255:17 ### Calculate difference (Hi - Lo)

XIC T4:0/DN XIO L255:[N7:0] XIC L255:16/31 ### Lo is positive and Hi is negative (rollover)
BST ADD L255:16 L255:[N7:0] L255:17 ### Calculate difference-2
NXB ADD L255:17 2 L255:17 ### Complete difference
BND

XIC T4:0/DN BST MOV L266:16 L255:[N7:0] ### Save current count
NXB ADD N7:0 1 N7:0 ### Increment index
NXB AND N7:0 15 N7:0 ### Wrap index
NXB MUL L255:17 3.75 F254:0 ### RPM
BND

XIC T4:0/DN RES T4:0 ### Restart timer

 
When you say an adjustable gearbox do you mean you have set ratios like a manual transmission or is it an infinitely variable pitch drive
they had them like 30 years ago everybody changed them to a VFD a long time ago
(if you ever worked on one of those you would soon see why)
if it just multiple ratios then use the motor rpm's and multiply by the current gear ratio
this would be far more accurate than trying to have multiple sensors on a single gear
Each counter on an HSC can only read 1 input, you can set up to count both the Rising edge and the falling edge of the same sensor, that would double the counts
 

Similar Topics

Has someone tried MC_TorqueLimiting along with MC_GearIn , on a Siemens S120 axis , controlled by an S7-1500T plc ? If we limit the torque ...
Replies
7
Views
1,598
Hello Everybody, Recently we changed the gearbox which has different ratio than the original one on a motor which is controlled by Micromaster...
Replies
3
Views
1,901
Hello, Does anyone know the preset thermal limits for SEW Movigear SNI B drives. Randomly experience overtemperatures of the heatsink of the...
Replies
0
Views
720
Gents, We have several machines where we use 1 till 25 baseplates to make products. Depending on the type of product, we use more or less...
Replies
2
Views
1,410
I have a virtual master that drives all servos. How do I make Virtual Master or any Servo to follow regular encoder which is driven by Regular...
Replies
5
Views
3,172
Back
Top Bottom