upm  0.4.1
Sensor/Actuator repository for libmraa (v0.8.0)
Public Member Functions | List of all members

API for the Loudness Sensor. More...

Detailed Description

This sensor family returns an analog voltage proportional to the loudness of the ambient environment. It's output does not correspond to a particular sound level in decibels. The higher the output voltage, the louder the ambient noise level.

This device uses an electret microphone for sound input.

This driver was developed using the DFRobot Loudness Sensor V2 and the Grove Loudness sensor.

groveloudness.jpg

Public Member Functions

synchronized void delete ()
 
 Loudness (int pin, float aref)
 
 Loudness (int pin)
 
float loudness ()
 

Constructor & Destructor Documentation

Loudness ( int  pin,
float  aref 
)

Loudness constructor

Parameters
pinAnalog pin to use
arefAnalog reference voltage; default is 5.0 V

Member Function Documentation

float loudness ( )

Returns the voltage detected on the analog pin

Returns
The detected voltage

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