Hello. 1
In this video you are going to learn how to read revolution with a encoder left side. 2
You can see applicable software high speed counters and applicable hardware. 3
High speed counters in this table for example. 4
X0 input of plc. 5
You can use c235 as up and down counter for example if you want to use 6
your X7 input of your plc. 7
You can use C242 and you can use this counter as up and down in here. 8
You can see auxiliary relays M bits in plc for 2 phase 2 input counters. 9
You can use counter two hundred thirty two thirty three and two hundred thirty four counters and you 10
can use for example two hundred thirty two counter as A phase input or phase A input and this can be 11
connected. 12
This can connect just x 0 so you can use phase B input for c232 and you can connect 13
it to X2 input of your plc for hardware high speed counters you can use x 0 for example with X0 14
you can use counter two hundred forty three just up counter it will just count up and X1 for counter 15
two hundred forty three will be reset signal input and dir means direction and U and D means up 16
and down counter so A phase A input and phase B input counters then you can select your counter according 17
to these tables for example you are just turning one direction and you can you just want to read a revolution 18
or pulses from your encoder with one direction you can use one phase input or you can use. 19
Okay I'm going to count up and also I will give a direction to my motor so you can use one phase and 20
two input for your application and also you can say Okay I will go count up and I will 21
count down and go forward and backward and I need to know exact pulses or position in my application 22
then you can use 2 phase 2 input counters for example pulse signals received from the encoder connected 23
to the shaft of the motor and these are going to be counted and the speed of the motor is going to be 24
measured in your application an example let's say this is an example the motor needs to stop for five 25
seconds after every five turns. 26
Let's take a look it in our solution. 27
It was determined from the table that the input point of the pulse signal to be counted is the x 0 input 28
of the counter 235 to be used. 29
Let's go here counter235 is here and we are going to use software high speed counter 30
and for the up-downcounter of counter 235. 31
We need to use x 0 and all other speed counter could also be used for the encoder the a phase of the 32
2 phase encoder used can be connected to X0 input if desired and also B phase if desired. 33
While feeding the encoder it should be paying attention to its direction we need to paid attention 34
to encoder direction since the encoder used produces 100 pulse signals in 1 turn 500 pulse signals should 35
be counted for 5 turns. 36
So in here. 37
Always on contact and then we are going to start our counters and we will count up. 38
OK. 39
And this value is the maximum value is counters can count this value but this is just a random value 40
then 41
We will reset each time our counters before this value so M1000 always on contact that we put here 42
and first we are moving our counter value to D0 data registers and D0 data register is comparing 43
in here with K 500 because our encoder. 44
Let's imagine our encoder is producing 100 pulse each turn that moment 500 is going to be equals to 5 45
turn and in our example we said okay after 5 turn after every 5 turn Motor needs to stop. 46
Just 5 seconds in here 47
our data registers 0 is less than five hundred. 48
So the motor is turning. 49
This is motor forward. 50
Output. 51
Imagine like this. 52
Y0 is our motor forward. 53
Output than motor is turning forward when the pulses reached 2500 in D0 will be equal or greater 54
than 500. 55
That moment this timer is going to be activated in this line. 56
So that moment our counter is going to count always but our timer is going to be active and 57
that moment motor is going to stop. 58
Just five seconds and when timer's came OK our counter is going to be resetted after five seconds and 59
this loop is going to start again. 60
And we are going to transfer our counter value D0 always in this line after timer is goes high. 61
We will move zero to D0 and this time motor is going to turn forward again. 62
And with this loop each time we will wait five turn and we will wait five seconds. 63
We will wait five turn five turn later. 64
We will wait five seconds and with like this we can use our encoder. 65
We can use our counter in this page. 66
You can see complete outputs and the counter 67
maximum kilohertz So what is the meaning of the maximum Khz. 68
We can count a pulses from coming encoder. 69
That's OK but our counters has limited. 70
For example for dvpss2 one phase one simple counter can connect to x 0 x1 x2 and X3 terminals. 71
And this input terminals can read a pulses as maximum 20 kilohertz and in here you can see our counters 72
maximum input frequencies. 73
And in here you can see it is really different. 74
Each other counter233 is 5Khz has maximum input frequency but counters two hundred forty 75
nine is 20kHz 76
So in here we have calculation motor rotation speed per second multiply by encoder resolution must 77
be less than this maximum input frequency for example encoder resolution is 1000 pulses 78
pulses. 79
Let's say like this and your motor rotation speed per second for example let's say 10. 80
So this is ten thousand and that moment ten thousand value is c235 can maximum 81
according to these maximum input frequency table it can be read these value from the encoder. 82
So this is just an example. 83
And 10 kilohertz means ten thousand Hz 84
So according to this calculation you can select your encoders in this video. 85
I'm finished. 86
See you in the next video.