Inertial#
Introduction#
The VEX GO Brain includes a built-in Inertial Sensor for measuring acceleration and detecting changes in motion.
Below is a list of all available blocks:
calibrate gyro – Calibrate the Brain’s Inertial Sensor.
set heading – Manually sets the robot’s heading value.
set drive rotation – Manually sets the robot’s cumulative rotation value.
heading – Returns the robot’s heading angle (0 to 359.99 degrees).
rotation – Returns how much the robot has turned since the project started.
detected crash? – Returns a Boolean indicating if a crash is detected.
acceleration – Returns the acceleration along on axis detected by the Inertial Sensor.
calibrate gyro#
The calibrate gyro block calibrates the Brain’s Inertial Sensor. All subsequent blocks will wait for the calibration to complete before executing. Calibration is an internal procedure that measures and compensates for sensor noise and drift over a specified period. During this time, the Brain must remain completely still (i.e., on a stable surface without any external movement). Movement during calibration will produce inaccurate results.
calibrar el giroscopio
Parameters |
Description |
---|---|
This block has no parameters. |
Example
Example coming soon!
set heading#
The set heading block sets the Inertial Sensor’s current heading to a specified value.
establecer rumbo a (0) grados
Parameters |
Description |
---|---|
heading |
The heading value to assign, in degrees. |
Example
Example coming soon!
set rotation#
The set rotation block sets the Inertial Sensor’s current cumulative rotation value.
establecer la rotación a (0) grados
Parameters |
Description |
---|---|
rotation |
The cumulative rotation value to assign, in degrees. |
Example
Example coming soon!
heading#
The heading block returns the robot’s heading angle in a range from 0 to 359.99 degrees.
(rumbo en grados)
Parameters |
Description |
---|---|
This block has no parameters. |
Example
Example coming soon!
rotation#
The rotation block returns how much the robot has turned since the project started, in degrees: positive for clockwise, negative for counterclockwise.
(rotación en grados)
Parameters |
Description |
---|---|
This block has no parameters. |
Example
Example coming soon!
detected crash?#
The detected crash? block returns a Boolean indicating whether or not the robot crashed.
True – A crash was detected.
False – A crash was not detected
Note: This block requires a configured drivetrain.
<¿Se detectó un accidente?>
Parameters |
Description |
---|---|
This block has no parameters. |
Example
Example coming soon!
acceleration#
The acceleration block returns the acceleration from one of the axes (x, y, or z) of the VEX GO Brain’s Inertial Sensor as a decimal between -4.0 and 4.0 G’s.
(aceleración del eje [incógnita v] en g)
Parameters |
Description |
---|---|
axis |
The axis to get the acceleration from:
|
Example
Example coming soon!