HC-SR04 ultrasonic Arduino library

Davide GombaOctober 20th, 2011

This is nice. I hope Carl posted the library in the Census

Carl Nobile has developed and released an Arduino library covering the HC-SR04 ultrasonic sensor. He writes: “It features timing, metric conversion, and standard deviation methods, plus a few support methods. It is written in C++ to conserve the namespace. The conversion formula can be easily modified to optimize the accuracy of conversion at different distances for inches and centimeters. Multiple buffers of different lengths can be created for determining standard deviation.

Look at the code and examples to understand how the library works. The standerd deviation code can be removed from the compilation resulting in a significant savings of resources. To do this comment the #define COMPILE_STD_DEV definition in the header file.”

via [dangerousPrototypes] downlaod the library from [FreshMeat]

Leave a Reply

You must be logged in with your Arduino account to post a comment.

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy