Syntax
public class SoundSensor : AnalogSamplingBase, IObservable<IChangeResult<Voltage>>, ISamplingSensor<Voltage>, ISensor<Voltage>
Constructors
SoundSensor(IAnalogInputPort)
Creates a new SoundSensor driver
Declaration
public SoundSensor(IAnalogInputPort port)
Parameters
Type | Name | Description |
---|---|---|
IAnalogInputPort | port |
SoundSensor(IPin, int, TimeSpan?, Voltage?)
Creates a new SoundSensor driver
Declaration
public SoundSensor(IPin pin, int sampleCount = 5, TimeSpan? sampleInterval = null, Voltage? voltage = null)
Parameters
Type | Name | Description |
---|---|---|
IPin | pin | AnalogChannel connected to the sensor. |
int | sampleCount | |
TimeSpan? | sampleInterval | |
Voltage? | voltage |