AnalogSensor Class

Definition

A generic Analog Sensor class

C#
public class AnalogSensor : Iot.Device.GoPiGo3.Sensors.ISensor
Inheritance
AnalogSensor
Derived
Implements

Constructors

AnalogSensor(GoPiGo, GrovePort)

Constructor for the generic Analog Sensor

Properties

MaxAdc

The maximum ADC value 4095 for GoPiGo3

Port

Get the Grove Port

SensorName

Get the sensor name "Analog Sensor"

SupportedPorts

List the supported Grove ports for the sensor

Value

Get the value of the sensor from 0 to MaxAdc

ValueAsPercent

Get the read value as a percentage from 0 to 100

Methods

ToString()

Get the value as a string

Applies to

Product Versions
.NET IoT Libraries 1.0.0, 1.1.0, 1.2.0, 1.3.0, 1.4.0, 1.5.0, 2.0.0, 2.1.0, 2.2.0