Sun SPOT API
Green Release  


com.sun.spot.sensorboard.hardware
Class AbstractADT7411RangeInput

java.lang.Object
  extended by com.sun.spot.sensorboard.hardware.AbstractADT7411RangeInput
All Implemented Interfaces:
IScalarInput
Direct Known Subclasses:
ADT7411InternalTemperatureInput, ADT7411RangeInput

public abstract class AbstractADT7411RangeInput
extends Object
implements IScalarInput

Abstract class providing a basis for sub-classes accessing the ADT7411 a-to-d converter

Author:
jn151271

Field Summary
protected  IADT7411 adt7411
           
protected  byte lsbAddress
           
protected  int lsbBitShift
           
protected  byte msbAddress
           
 
Constructor Summary
AbstractADT7411RangeInput(IADT7411 adt74112)
           
 
Method Summary
 int getRange()
           
 int getValue()
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

msbAddress

protected byte msbAddress

lsbAddress

protected byte lsbAddress

lsbBitShift

protected int lsbBitShift

adt7411

protected IADT7411 adt7411
Constructor Detail

AbstractADT7411RangeInput

public AbstractADT7411RangeInput(IADT7411 adt74112)
Parameters:
adt74112 -
Method Detail

getRange

public int getRange()
             throws IOException
Specified by:
getRange in interface IScalarInput
Returns:
maximum value that could be returned by the a-to-d converter; actual reading will be in the range 0 to getRange()
Throws:
IOException
See Also:
IScalarInput.getRange()

getValue

public int getValue()
             throws IOException
Specified by:
getValue in interface IScalarInput
Returns:
current value for the a-to-d converter
Throws:
IOException
See Also:
IScalarInput.getValue()

Sun SPOT API
Green Release  


Copyright © 2006 Sun Microsystems, Inc. All Rights Reserved.