HCSR04 Library
distancemeter Class Referenceabstract

Abstract class which is able to measure distance. More...

#include <HCSR04.h>

Inheritance diagram for distancemeter:
hcsr04

Public Member Functions

 distancemeter ()
 Empty constuctor.
 
virtual long long int measure (Unit unit=Unit::Centim)=0
 Virtual function which returns the distance from the sensor to an object in unit defined in parameter. More...
 

Detailed Description

Abstract class which is able to measure distance.

Member Function Documentation

virtual long long int distancemeter::measure ( Unit  unit = Unit::Centim)
pure virtual

Virtual function which returns the distance from the sensor to an object in unit defined in parameter.

The parameter "unit" is for specifying the output unit of this function. For centimeters use "Unit::Centim". For Inches use "Unit::Inch". By default centimeters will be used. Note: Please be aware that enumerations are case sensitive.

Implemented in hcsr04.


The documentation for this class was generated from the following file: