How to Measure Pulse Frequency from a Discrete Input for Flywheel Applications

Question:

Subject: Seeking Assistance with Pulse Frequency Detection for Flywheel Application Hello, I'm currently working on an application that involves measuring the frequency of a pulse train generated by an inductive proximity sensor, which detects gaps in the structure of a flywheel. I estimate the frequency to be within the range of 60 Hz to 100 Hz when the flywheel is operational. While this measurement is not critically essential to my process, it serves as a basic protection mechanism for the reversing motor starter and indicates when the flywheel reaches at least 90% of its maximum speed, allowing for full power stroking. In a typical scenario, I would rely on a press control system and utilize an output from that, but since this is a hot-work forging application, OSHA regulations do not mandate a safe press control. I have a proximity sensor with a switching speed of 300 Hz connected to a 1734-IB/8 Point I/O card. Given the hardware I currently possess, is it feasible to implement this functionality? I've searched online for sample code to help me get started, but I haven't found much success with my efforts in navigating Google. Any guidance or suggestions would be greatly appreciated! Best regards, Jim

Top Replies

While the update speed may seem quick for a standard input card, it's essential to review the technical specifications to determine the maximum response time for setting the RPI. Additionally, the performance can vary depending on your PLC's scan rate. An alternative solution is to utilize a High-Speed Counter (HSC) card to measure pulse counts over one second. However, the most effective and cost-efficient approach is to invest in a specialized frequency counter device featuring an adjustable 4-20mA output. I recommend conducting a search for these frequency counters, as there are numerous reliable options available in the market.

Explore these valuable discussion threads for insights and answers: [PLCTalk Thread 98399](http://www.plctalk.net/qanda/showthread.php?t=98399) and [PLCTalk Thread 95153](http://www.plctalk.net/qanda/showthread.php?t=95153). Dive into expert conversations and gain knowledge on PLC topics!

Great research, Tarik! I concur with my past self that opting for the 1734-IK module would be the most suitable choice for this application. The -IJ variant operates at 5V, while the -IK can handle voltage levels between 15V and 24V. A 100 Hz square wave features an ON pulse duration of 5 milliseconds, followed by 5 milliseconds of the OFF state. To accurately capture each pulse, it's crucial to sample the signal twice within each period, which reduces the sampling window to 2.5 milliseconds. The POINT I/O standard DC input modules come with a minimum filter time of 0.5 milliseconds, allowing you to narrow that down to 2 milliseconds. This is likely the fastest you can operate the Raspberry Pi (RPI) through a 1734-AENT POINT I/O adapter, not factoring in the POINT Bus's backplane speed. For optimal performance in this application, I recommend using a dedicated speed relay, a Speed/Analog signal conditioner, or the 1734-IK counter module.

Hi Jim! It sounds like an interesting project you're working on. Given your setup with the inductive proximity sensor and the I/O card, you should be able to implement pulse frequency detection without too much trouble. One approach could be to use a simple interrupt-based reading on the I/O card to count pulses over a set time period, giving you a frequency measurement. You might want to check if there are libraries compatible with your hardware that could streamline this process. Sometimes, looking at forums specific to your I/O card could yield example code or solutions that others have shared. Good luck, and feel free to share updates on your progress!

More Replies →

Streamline Your Asset Management
See How Oxmaint Works!!

✅   Work Order Management

✅   Asset Tracking

✅   Preventive Maintenance

✅   Inspection Report

We have received your information. We will share Schedule Demo details on your Mail Id.

You must be a registered user to add a comment. If you've already registered,
sign in. Otherwise, register and sign in.

Frequently Asked Questions (FAQ)

Ready to Simplify Maintenance?

Join hundreds of satisfied customers who have transformed their maintenance processes.
Sign up today and start optimizing your workflow.

Request Demo  →