MonoBrick EV3 Firmware
Public Member Functions | Properties | List of all members
MonoBrickFirmware.Sensors.EV3GyroSensor Class Reference

Class for the EV3 Gyro sensor More...

Inheritance diagram for MonoBrickFirmware.Sensors.EV3GyroSensor:
MonoBrickFirmware.Sensors.UartSensor MonoBrickFirmware.Sensors.ISensor

Public Member Functions

 EV3GyroSensor (SensorPort port)
 Initializes a new instance of the Gyro sensor. More...
 
 EV3GyroSensor (SensorPort port, GyroMode mode)
 Initializes a new instance of the Gyro sensor. More...
 
override string ReadAsString ()
 Reads the sensor value as a string. More...
 
new void Reset ()
 Reset the sensor More...
 
int RotationCount ()
 Get the number of rotations (a rotation is 360 degrees) - only makes sense when in angle mode More...
 
int Read ()
 Read the gyro sensor value. The returned value depends on the mode. More...
 
override string GetSensorName ()
 Gets the name of the sensor. More...
 
override void SelectNextMode ()
 Selects the next mode. More...
 
override void SelectPreviousMode ()
 Selects the previous mode. More...
 
override int NumberOfModes ()
 Numbers the of modes. More...
 
override string SelectedMode ()
 .m.-, More...
 
- Public Member Functions inherited from MonoBrickFirmware.Sensors.UartSensor
 UartSensor (SensorPort port)
 

Properties

GyroMode Mode [get, set]
 Gets or sets the Gyro mode. More...
 
- Properties inherited from MonoBrickFirmware.Sensors.UartSensor
UARTMode uartMode [get, set]
 
SensorPort Port [get]
 
- Properties inherited from MonoBrickFirmware.Sensors.ISensor
SensorPort Port [get]
 Sensor port More...
 

Additional Inherited Members

- Protected Member Functions inherited from MonoBrickFirmware.Sensors.UartSensor
void Reset ()
 
byte[] GetSensorInfo ()
 Gets the sensor info based on the mode More...
 
bool Initialise (UARTMode mode)
 
bool SetMode (UARTMode mode)
 
byte ReadByte ()
 
byte[] ReadBytes (int length)
 
- Protected Attributes inherited from MonoBrickFirmware.Sensors.UartSensor
const int NumberOfSensorPorts = SensorManager.NumberOfSensorPorts
 
SensorPort port
 

Detailed Description

Class for the EV3 Gyro sensor

Constructor & Destructor Documentation

MonoBrickFirmware.Sensors.EV3GyroSensor.EV3GyroSensor ( SensorPort  port)
inline

Initializes a new instance of the Gyro sensor.

MonoBrickFirmware.Sensors.EV3GyroSensor.EV3GyroSensor ( SensorPort  port,
GyroMode  mode 
)
inline

Initializes a new instance of the Gyro sensor.

Parameters
modeMode.

Member Function Documentation

override string MonoBrickFirmware.Sensors.EV3GyroSensor.GetSensorName ( )
inlinevirtual

Gets the name of the sensor.

Returns
The sensor name.

Implements MonoBrickFirmware.Sensors.UartSensor.

override int MonoBrickFirmware.Sensors.EV3GyroSensor.NumberOfModes ( )
inlinevirtual

Numbers the of modes.

Returns
The number of modes

Implements MonoBrickFirmware.Sensors.UartSensor.

int MonoBrickFirmware.Sensors.EV3GyroSensor.Read ( )
inline

Read the gyro sensor value. The returned value depends on the mode.

override string MonoBrickFirmware.Sensors.EV3GyroSensor.ReadAsString ( )
inlinevirtual

Reads the sensor value as a string.

Returns
The value as a string

Implements MonoBrickFirmware.Sensors.UartSensor.

new void MonoBrickFirmware.Sensors.EV3GyroSensor.Reset ( )
inline

Reset the sensor

int MonoBrickFirmware.Sensors.EV3GyroSensor.RotationCount ( )
inline

Get the number of rotations (a rotation is 360 degrees) - only makes sense when in angle mode

Returns
The number of rotations
override string MonoBrickFirmware.Sensors.EV3GyroSensor.SelectedMode ( )
inlinevirtual

.m.-,

Returns
The mode.

Implements MonoBrickFirmware.Sensors.UartSensor.

override void MonoBrickFirmware.Sensors.EV3GyroSensor.SelectNextMode ( )
inlinevirtual

Selects the next mode.

Implements MonoBrickFirmware.Sensors.UartSensor.

override void MonoBrickFirmware.Sensors.EV3GyroSensor.SelectPreviousMode ( )
inlinevirtual

Selects the previous mode.

Implements MonoBrickFirmware.Sensors.UartSensor.

Property Documentation

GyroMode MonoBrickFirmware.Sensors.EV3GyroSensor.Mode
getset

Gets or sets the Gyro mode.

The mode.


The documentation for this class was generated from the following file: