The VEX GO Brain is used to detect acceleration and rotation.

GO_Brain-Battery.png

Note: in this article, the example projects use the Code Base GO Build.


How the Brain is Used

GO_Brain-Powered_On.png

The Brain has a built in Gyro and Accelerometer. These are used to detect acceleration and rotation.

The Brain can detect:

_Acceleration_of__block.png

Acceleration.
The Brain can report acceleration of each of the three axes using the (Acceleration of) block.

GO_BrainAxis.png

The Brain reports acceleration on three axes. The x, y, and z-axis. Each axis has a positive and negative direction.

_Drive_heading__block.png

Heading and Rotation.
The Brain can report the heading value in degrees using the (Drive heading) block.

GO_Brain_Compass.jpg

The heading value reports a range from 0-359.99 degrees. The value is reported from a clockwise turn.

_Drive_rotation__block.png

The Brain can report the rotation value in degrees using the (Drive rotation) block.

GO_Brain_Rotation_Direction.png

The rotation value reports positive values when rotated to the right, and negative values when rotated to the left. Rotation values are cumulative, and are not capped at 0 or 360 degrees. They will continue to increase or decrease as the rotations accumulate.


Report Acceleration Example Project

Report_acceleration_snipit.png

The code below will report the acceleration value of each axis as the Code Base is rotated.

Report_acceleration_project_markup.jpeg

The Print Console can be used to see the acceleration value changing in real time.


Report Heading and Rotation Example Project

Report_rotation_snipit.png

The code below will report the heading of the Code Base’s Drivetrain and the rotation value as the Code Base turns.

Report_Heading_and_Rotation__right__mockup.jpeg

The Print Console can be used to see the heading and rotation values changing in real time.

Notice that the heading values are reported clockwise between 0-359.99 degrees, because the Code Base is turning right. Rotation values are cumulative, they will continue to increase (right rotation) or decrease (left rotation).

Report_Rotation_left_snipit.png

Adjust the [Turn for] block in the project to change the direction from ‘right’ to ‘left’ and Start the project again.

Report_Heading_and_Rotation__left__mockup.jpeg

In the Print Console, notice that the heading values are reported clockwise between 0-359.99 degrees, because the Code Base is turning left. The first turn left 90 degrees is reported as a heading of 270 degrees. The rotation values continue to increase with each rotation, however, since the Code Base is turning left, the rotation values are reporting negative.

For more information, help, and tips, check out the many resources at VEX Professional Development Plus