public class GyroAngleSensor extends Sensor
Constructor and Description |
---|
GyroAngleSensor()
Creates a sensor instance connected to port S1.
|
GyroAngleSensor(SensorPort port)
Creates a sensor instance connected to the given port.
|
Modifier and Type | Method and Description |
---|---|
lejos.hardware.sensor.EV3GyroSensor |
getLejosSensor()
Returns the reference of the the underlying
lejos.hardware.sensor.EV3GyroSensor.
|
int |
getValue()
Returns the orientation of the sensor in repect to
its start orientation.
|
void |
reset()
Resets the start orientation to the current orientation.
|
getLejosPort
public GyroAngleSensor(SensorPort port)
port
- the port where the sensor is plugged-inpublic GyroAngleSensor()
public lejos.hardware.sensor.EV3GyroSensor getLejosSensor()
public int getValue()
public void reset()