5/4/2017 3:02 AM  
Joined: 4/26/2017 Last visit: 10/17/2019 Posts: 40 Rating: (0) 
Working on windows 10 and LOGO! Soft v 8.1, LOGO 8.FS4 and LOGO! TD. I'm using a Counter to control certain process on a machine. The input is digital 01. Right now i need a RPM value attached on this procces, by the same digital input to count and get RPM value. Researching on this forum i found how can i obtain the rpm using a pulse generator and Arithmetic Instruction and it works fine on the simulator, but when i tried to implement it on the machine, something happens and does not calculate the RPM value but the counter is still working well. my suspicion is that i am trying to use 2 counters on the same digital input and something crashes on the way. 
5/4/2017 6:07 AM  
Joined: 12/18/2014 Last visit: 5/31/2020 Posts: 18302 Rating: (1929)

Since you do not describe exactly what input it is, so I can only make assumptions. Also, you have not written how high the speed is (rpm). For normal digital inputs, Siemens only guarantees a frequency of 4Hz, which corresponds to 240 rpm. For higher frequencies, you Need a LOGO! which can only be supplied with pure DC voltage. These LOGO!s have fast inputs, in which Siemens guarantees a frequency of 5kHz, which corresponds to a speed of 30,000 rpm. From these fast inputs the corresponding LOGO! has each 4 (I3I6). Digital expansion modules do not have these fast inputs. In addition I would program the speed evaluation differently, see attachment. AttachmentSpeed_0BA8.Standard.zip (434 Downloads) 
This contribution was helpful to1 thankful Users 
5/4/2017 2:43 PM  
Joined: 4/26/2017 Last visit: 10/17/2019 Posts: 40 Rating: (0) 
Sorry for not being clear. It is strange to me that even in the simulator the RPM program is working well, but when i put it on the logo and start the AC motor, just the Counter is working and the RPM does not. EDIT: I am going to work and i will try your RPM program. 
Last edited by: Walter Jacquet at: 5/4/2017 2:52:18 PM 

5/4/2017 8:16 PM  
Joined: 4/26/2017 Last visit: 10/17/2019 Posts: 40 Rating: (0) 
Thanks for your solution. It works perfectly fine. Just a question: there is a way to make the RPM more accurate? the machine works arround 80300 rpm and i need it to be more precise. 
5/4/2017 9:52 PM  
Joined: 12/27/2006 Last visit: 5/30/2020 Posts: 1116 Rating: (97) 
Can you give us the type of your sensor, or better a .pdf document of it. Maby the input resistance of the LOGO is to High (!) for the sensor. Have you triad a resistor between the digital input on the LOGO and  power? 
5/4/2017 11:50 PM  
Joined: 4/26/2017 Last visit: 10/17/2019 Posts: 40 Rating: (0) 
the sensor is the most common one that you can get. PNP source 24VDC. It does not work faster than 4HZ (or 4 inputs signals per second). As i said, the counter is working as spected, but the other counter i used to calculate RPM does not. 
5/5/2017 7:34 AM  
Joined: 12/18/2014 Last visit: 5/31/2020 Posts: 18302 Rating: (1929)

The precision of the display depends on the number of measured pulses, the measurement period and the factor.
For a measuring period of one second, the speed is updated every second, with a measuring period of 10 seconds, the update takes place every 10 seconds. In attachment there is a new example. In this you can for testing in the simulation changing the measuring period over TDE Display. AttachmentSpeed_V2_0BA8.Standard.zip (241 Downloads) 
5/5/2017 9:50 PM  
Joined: 4/26/2017 Last visit: 10/17/2019 Posts: 40 Rating: (0) 
Seems like LOGO! does not work using 2 counters on the same digital input. I created a solution, not the best one, but it works. While i am counting the numbers of digital inputs, a chronometer starts counting the time at the same time. Then i do a simple math (COUNT/TIME)X60 to get the rpm. On the first 5 seconds it is not exact as i expected, but on 20 seconds or more it is. 
5/5/2017 10:18 PM  
Joined: 12/27/2006 Last visit: 5/30/2020 Posts: 1116 Rating: (97) 
There are 2 ways to perform a speed measurement. 1: measure the number of revolutions with a fixed interval Calculate: 60 divided by the interval X number of revolutions = speed If the interval time is 1 second then you multiply the number of revolutions by 60 to obtain the speed. No time measurement is exact, so you can always have 1 revolution more or 1 revolution less than you've measured.Each digital speed measurement has a bearing on it.And because you multiply the result by 60, your speed can also be 60 more or less than it really is. The longer the measurement interval, the smaller the error.It is becoming increasingly narrow, but also slower. With a 1 minute measurement interval, your error is only 1 more or less, but your measurement will be very slow. 2: measure the time of 1 revolution Calculate: 60 divided by time (in sec) = speed The accuracy of this measurement is determined by the accuracy of the time measurement. Especially at high speeds you get short turnaround times and the measurement of time is less accurate. The speed of measurement is maximum !, faster can not. The LOGO is just a simple PLC and has some effort to measure short times, also think that your digital input can not officially handle more than 4 Hz. The fast inputs on some LOGOs are with this measurement method All 2 measurement methods are good at making a LOGO. What you make depends on your preference 
5/6/2017 6:55 PM  
Joined: 12/18/2014 Last visit: 5/31/2020 Posts: 18302 Rating: (1929)

Here is an example of how to calculate the speed by measuring the period between 2 signals of the speed sensor.
AttachmentSpeed.zip (236 Downloads) 
Follow us on