This project is read-only.

Toolbox.NETMF.Hardware.IADCPort

This is actually an interface, created so multiple ADC classes can be used. By default, all samples will use the Netduino ADC class, with the classname "Netduino.ADC".
By default, all samples will use the .NETMF built-in network stack, with the classname "Netduino.ADC".

Currently supported ADC controllers

Required methods

  • AnalogRead() Reads a value between 0 and 1
  • RangeSet(Min, Max) Sets the range for RangeRead()
  • RangeRead() Reads a value between RangeMin and RangeMax
  • Dispose() Disposes the ADC object

Required Properties

  • RangeMin The minimal value for RangeRead()
  • RangeMax The maximal value for RangeRead()

Sample code in C#

IADCPort PotentioMeter1 = new Netduino.ADC(Pins.GPIO_PIN_A0);
PotentioMeter1.RangeSet(0, 100);

Sample code in VB

Dim PotentioMeter1 As IADCPort = New Netduino.ADC(Pins.GPIO_PIN_A0)
PotentioMeter1.RangeSet(0, 100)

Last edited Jul 6, 2012 at 11:43 AM by Garrcomm, version 9