Abt High Speed Counters and programming it

Weivreif

Member
Join Date
Nov 2010
Location
Manila
Posts
17
Hi, im using the built in high speed counter of omron cj1m cpu22. I will be connecting a rotary encoder to the high speed counter. The rotary encoder is connected to a screw and we need to determine the screw position real time using the encoder pulses. I know how to compute the pulses and convert it to distance but one thing im having a hard time to figure out is getting the present value of the high speed counter and retaining it.

i know we can use the instruction PRV or read the value from the auxilliary bit but since PRV depends on the scan time of the program will it be accurate in determining the position of the screw. And one more thing, the manual said that after power is turned off the present value of the counter resets to zero. so, what if my screw is in the middle position and power was turned off? the counter value will be back to zero and in the program it would indicate that the screw is on zero position even if its not. Just need help on this, I dont have the PLC yet so im just programming in advance. Any help will be appreciated. Thanks a lot.
 
With the arrangement you are describing you will need a home position sensor AND a homing routine to establish your 0 position each time the system is powered up.

For the CJ1M-CPU22 you can use the "REGISTER COMPARISON TABLE:CTBL(882)" instruction to establish actions you need to take at different positions or ranges. This will trigger one or more interrupt routines that are independent of program scan time.

Make sure to select an encoder with Quadrature output [Dual channel 90deg apart] and configure the H[igh] S[peed] C[ounter] inputs in the PLC for "Differential Phase Mode". With this arrangement the HSC will capture the position as the screw rotates in either direction.

See this excellent post by Jay Anthony for help.
http://forums.mrplc.com/index.php?app=downloads&showfile=268
 

Similar Topics

If I Have a computer running Hyperterminal, and it's connected to the controller using serial commport-1. How can I use hyperterminal to test and...
Replies
2
Views
1,645
can anybody tell me how to read data from PLC using hyperterminal and which type of data i will get i m a beginner for plc so please help me
Replies
6
Views
2,327
hello all i m a student from INDIA i want to do data exchenge between two serial ports using PLC SOFTWARE(SIMULATOR) by using com port...
Replies
5
Views
2,017
sir,im going to do project in plc based bottle filling module that fills 5 bottles automatically.can u plz give the tips to construct ladder...
Replies
2
Views
1,741
Good Afternoon, I Am Parag From Mumbai, Like This Plc Site , Is There Any Site For Dcs Is Available. Thanks In Advance. Best Regards...
Replies
0
Views
1,691
Back
Top Bottom