SunSPOT API V3.0


com.sun.spot.sensorboard.io
Class OutputPin

java.lang.Object
  extended by com.sun.spot.sensorboard.io.OutputPin
All Implemented Interfaces:
IOutputPin

public class OutputPin
extends Object
implements IOutputPin

Accessor object for output only GPIO pins.


Constructor Summary
OutputPin(PinDescriptor idx, IGPIOController cntrl)
           
 
Method Summary
 PinDescriptor getIndex()
          Return the PinDescriptor for this pin.
 boolean getState()
          Return the current state of this pin.
 void setHigh()
          Set the value of this pin to high.
 void setHigh(boolean high)
          Set the value of this pin.
 void setLow()
          Set the value of this pin to low.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OutputPin

public OutputPin(PinDescriptor idx,
                 IGPIOController cntrl)
Method Detail

getIndex

public PinDescriptor getIndex()
Return the PinDescriptor for this pin.

Specified by:
getIndex in interface IOutputPin
Returns:
PinDescriptor for this output

setHigh

public void setHigh()
Set the value of this pin to high.

Specified by:
setHigh in interface IOutputPin

setLow

public void setLow()
Set the value of this pin to low.

Specified by:
setLow in interface IOutputPin

setHigh

public void setHigh(boolean high)
Set the value of this pin.

Specified by:
setHigh in interface IOutputPin
Parameters:
high - if true then pin is set to high

getState

public boolean getState()
Return the current state of this pin.

Specified by:
getState in interface IOutputPin
Returns:
current state of this pin

SunSPOT API V3.0


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