pt.citar.diablu.nxt.brick
Class NXTButtonSensor

java.lang.Object
  extended by pt.citar.diablu.nxt.brick.NXTComponent
      extended by pt.citar.diablu.nxt.brick.NXTButtonSensor

public class NXTButtonSensor
extends NXTComponent

Author:
Jorge Cardoso

Constructor Summary
NXTButtonSensor(NXTBrick brick, byte portAttached)
          Coonstructs a new NXTButtonSensor object given the NXTBrick and the port number the sensor is connected to.
 
Method Summary
 int getValue()
           
 boolean isButtonPressed()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NXTButtonSensor

public NXTButtonSensor(NXTBrick brick,
                       byte portAttached)
Coonstructs a new NXTButtonSensor object given the NXTBrick and the port number the sensor is connected to.

Parameters:
brick - The NXTBrick.
portAttached - The port to which the sensor is attached. (0 - 3).
Method Detail

getValue

public int getValue()

isButtonPressed

public boolean isButtonPressed()


Processing library NXTComm by Jorge C. S. Cardoso. (c) 2014