Mindstorms 3rd Party ROBOTC Drivers RobotC
[Home] [Download] [Submit a bug/suggestion] [ROBOTC Forums] [Blog] [Support this project]
Files | Functions | Variables

Gyroscopic Sensor
[HiTechnic]

Files

file  HTGYRO-driver.h
 

HiTechnic Gyroscopic Sensor driver.


Functions

int HTGYROreadRot (tSensors link)
int HTGYROstartCal (tSensors link)
int HTGYROreadCal (tSensors link)
void HTGYROsetCal (tSensors link, int offset)
int HTGYROreadRot (tMUXSensor muxsensor)
int HTGYROstartCal (tMUXSensor muxsensor)
int HTGYROreadCal (tMUXSensor muxsensor)
void HTGYROsetCal (tMUXSensor muxsensor, int offset)

Variables

int HTGYRO_offsets [][]

Detailed Description

HiTechnic Gyroscopic Sensor


Function Documentation

int HTGYROreadCal ( tSensors  link )

Retrieve the current offset for the gyro

Parameters:
linkthe HTGYRO port number
Returns:
the offset value for the gyro
Examples:
HTGYRO-SMUX-test1.c, and HTGYRO-test1.c.

Definition at line 172 of file HTGYRO-driver.h.

int HTGYROreadCal ( tMUXSensor  muxsensor )

Retrieve the current offset for the gyro

Parameters:
muxsensorthe SMUX sensor port number
Returns:
the offset value for the gyro

Definition at line 183 of file HTGYRO-driver.h.

int HTGYROreadRot ( tMUXSensor  muxsensor )

Read the value of the gyro

Parameters:
muxsensorthe SMUX sensor port number
Returns:
the value of the gyro

Definition at line 87 of file HTGYRO-driver.h.

int HTGYROreadRot ( tSensors  link )

Read the value of the gyro

Parameters:
linkthe HTGYRO port number
Returns:
the value of the gyro
Examples:
HTGYRO-SMUX-test1.c, and HTGYRO-test1.c.

Definition at line 70 of file HTGYRO-driver.h.

void HTGYROsetCal ( tSensors  link,
int  offset 
)

Override the current offset for the gyro manually

Parameters:
linkthe HTGYRO port number
offsetthe new offset to be used

Definition at line 150 of file HTGYRO-driver.h.

void HTGYROsetCal ( tMUXSensor  muxsensor,
int  offset 
)

Override the current offset for the gyro manually

Parameters:
muxsensorthe SMUX sensor port number
offsetthe new offset to be used

Definition at line 161 of file HTGYRO-driver.h.

int HTGYROstartCal ( tMUXSensor  muxsensor )

Calibrate the gyro by calculating the average offset of 5 raw readings.

Parameters:
muxsensorthe SMUX sensor port number
Returns:
the new offset value for the gyro

Definition at line 127 of file HTGYRO-driver.h.

int HTGYROstartCal ( tSensors  link )

Calibrate the gyro by calculating the average offset of 5 raw readings.

Parameters:
linkthe HTGYRO port number
Returns:
the new offset value for the gyro
Examples:
HTGYRO-SMUX-test1.c, and HTGYRO-test1.c.

Definition at line 98 of file HTGYRO-driver.h.


Variable Documentation

int HTGYRO_offsets[][]
Initial value:
 {{620, 620, 620, 620}, 
                          {620, 620, 620, 620},
                          {620, 620, 620, 620},
                          {620, 620, 620, 620}}

Definition at line 60 of file HTGYRO-driver.h.