Hello.
In this tutorial Vivillon, learn how can we use that force of encoder and how can we calculate r.p.m.
of the motor?
I will create a new project and this device type.
This tool is OK for me, for the simulator.
And let's create any program.
And there's going to be little diagram is OK for me.
Then firstly, we need to define our counter.
Let's start with the L.D and one thousand and I will reset em one thousand two hundred thirty five.
Why this is counter 235.
This is the high speed counter count on or.
Up and down what I mean, if this is on, if I said this and 1235, it will count down or if I resisted
or if it is off, it will count up.
This is the first thing.
And another thing I will write my coat to here, double counter.
Then that means I spit counter as you know that counter 235.
And let's skew it data to here.
For example, randomly this one, this is the first thing.
And the second thing we need to calculate and r.p.m..
What is r.p.m. revolution?
Per minute.
And each time this input is connected to, for example, it's zero.
This is my sensor.
Input.
OK.
And then if I use normally normal input to zero.
What will happen because of the very high speed, for example, your motor is turning one thousand four
hundred r.p.m..
It is not going to be count or it may gear and not a correct result.
So we need to use double counter.
That means high speed counter.
Then we will catch each pulse from zero.
The sensor input, OK, and each one minute.
So this is a minute.
So each pulse, for example, one pulse and how many time and for example, in minute 60 seconds each
second or in one one minute how many pulses came to us, then that will be resolved and that will be
our r.p.m..
So let's start with the gain.
LDM one thousand, OK, and let's define the timer and this timer is going to count.
One minute, OK, this is the first thing.
And each time I will move a double move, we start to counter that talked to, for example, the five
hundred and five.
OK, this is my roommate area.
And also, let's continue with the LDP or against start with and one thousand each.
One minute, OK, one minute is done.
What will happen?
I will reset timer first, the reset timer zero because of why the second one minute time is going to
be count again.
This is the first thing and I will reset my counter also.
And also, I will move my five hundred and five data to, for example, randomly this data.
So what is that means?
We are counting, OK?
And each this is that fast.
Is connected through, for example, to zero what we hear A and B and Z for us right into encoder,
then Z Force is going to give.
One term.
And one pulse and one pulse is going to be counted by counter two hundred and thirty five and one.
This is counting.
It is moving with the W instruction to the 505 in one second and timer is done when the time when it's
done, just that condition in just one pulse.
We are resetting timer, we are resetting countdown.
Also, we are moving the 505 to the 510.
And this is our r.p.m. of motor.
I will try once to simulator and there is no high speed pulse input from the sensor, but I will try
once to created.
OK.
And now it's stop, and I will say run.
And this is running and the timer is counting and how we can activate this one.
OK.
And maybe.
It's zero we can create into device winter table, and it's put here, it's zero.
And I will try to enable or sit on and set of and sit on and set of.
Can we see it in here?
No, for example, I will change this data.
Imagine this is just.
Counted and 50 times, OK, and you will see this is now moving to here, but r.p.m. data is zero.
After one minute.
It is counting and counting and counting.
Imagine this is 50 times it's counted.
And then you will see my r.p.m. is 50.
And this is again, it's counting the motor speed is increased by you, by the operator.
For example, this is now one hundredth and I will change it to like that.
And that r.p.m. is then imagine again, somebody is increasing the speed of the motor and then after
one minute later.
What will happen to our data is going to be changed like that, OK?
This is the easiest way.
How come use that force of the encoder and just the high speed control?
We need to use that.
And how can we calculate r.p.m.?
They can calculate and r.p.m. of the motor according to sensor or according to our encoder or according
to our pulse input.
OK for Estoril and finished.
You see your next tutorial.