Quick frequency counter with Arduino

Frequency is very important parameter of any signal. No matter if you are generating or synthesizing signals, you most likely need to measure its frequency. When signal frequency is bellow 40kHz and amplitude is near 5V then you can build frequency counter on Arduino with standard LCD screen. If measure signal is 5V (or 3.3V) level then you can feed it directly in to Arduino input. In other cases you need to use limiting circuit like amplifier or voltage divider. But this small project assumes that voltage is fed directly to microcontroller input.


In this example signal comes to digital pin 12 where function pulseIn() counts number of pulses during specified time. Program itself is only few lines of code, and hardware is straight forward so putting it to work condition is only a matter of minutes.

Keep cat away from unwanted areas with cat protector

Cats are sneaky pets that don’t like to obey the rules. If you are nearby, then you can keep an eye and chase away. Normally your voice does the trick. But when you are not at home, cats can do what ever they want. Lucky resistor decided to put end to cats domination at home and started a new project called “Cat Protector”. It’s a device which once placed on some area, prevents it from cats visit. Device simply detects cat movement and then speaks recorded phrases with owners voice.


Before building a final product, he first of all made a prototype, to see if this is efficient way to control the cat. After confirming, this works 100%, he finished it with portable enclosure and other elements. “Cat Protector” is based on Arduino Uno. Cat motion is sensed with Panasonic motion sensor AMN32111 which connects to Arduino with three pins. Masters audio is recorded in to SD card which is accessed with Data-Logging shield. Audio is played back through Microchip MCP4821 DAC interfaced to Arduino via SPI. Audio the is amplified on low power amplifier and then played with small 0.2W speaker. There is also a dual color LED used to indicate operation of device. Once built, it can be placed on any surface and hope that cat obeys voice disapproval commands all the time.

Scanning your vitals with medical tricorder

Smart medical devices are coming closer to our daily lives. Times seems are passing when the only device we used at home was mercury based thermometer or manual blood pressure meter. Those devices are more or less automatic. Things are getting even better with wearable electronics. A simple wrist watch can monitor your pulse, pressure and temperature. MarkusB has been inspired by SciFi movies where heroes from Star Trek could self-diagnoze medical conditions within seconds. So he started a medical tricorder project.

The device he built is able to measure temperature on the forehead with infrared thermometer and PPG (Photoplethysmograph) pulse/heart rate on ear lobe. He found that reading only those two parameters he could read lots of medical parameters. To call a device tricorder there is one more sensor needed. So he intends to add respiration sensor to read breathing rate by using mask and pressure sensor like MPXV4006GP. He built a custom Arduino board with OLED display. Microcontroller does some intense calculations to evaluate medical parameters out of readings. Of course it cannot be considered as reliable medical diagnostic device, but this is great experiment project.

One simple way to build light follower

You can find many ways to use light tracker. It can be a simple toy that drives around and follows light pattern or complex system like solar panel tracker that follows sun path on sky.

In order to build a simple light follower prototype you only need few common components like Arduino, four LDRs (Light Dependent Resistor) and servomotor.


This set up uses four LDRs to gt light intensity readings. Two sensors are positioned at the bottom and two at the top of platform. You could get away with two LDRs but pairing them give more stable and reliable readings. The algorithm is pretty straight forward. Arduino reads LDR values, calculates averages of pairs and then finds a difference between up and down part. And depending on difference it turns servo motor when it reaches equilibrium. Of course it is not possible to get equal readings so there is some threshold allowed when light source is near to perpendicular position. Project is mounted on to cardboard based enclosure that is great for quick demos.