Accelerometers - Hardware
Accelerometers are common sensors used to measure acceleration.
In principle, precise measurements of acceleration can be double-integrated and used to track position (similarly to how the measurement of turn rate from a gyroscope can be integrated to determine heading) - however, in practice, accelerometers that are available within the legal FRC® price range are not nearly accurate for this use. However, accelerometers are still useful for a number of tasks in FRC.
The roboRIO comes with a built-in three-axis accelerometer that all teams can use, however teams seeking more-precise measurements may purchase and use a peripheral accelerometer, as well.
Types of accelerometers
There are three types of accelerometers commonly-used in FRC: single-axis accelerometers, multi-axis accelerometers, and IMUs.
Single-axis accelerometers
As per their name, single-axis accelerometers measure acceleration along a single axis. This axis is generally specified on the physical device, and mounting the device in the proper orientation so that the desired axis is measured is highly important. Single-axis accelerometers generally output an analog voltage corresponding to the measured acceleration, and so connect to the roboRIO’s analog input ports.
Multi-axis accelerometers
Multi-axis accelerometers measure acceleration along multiple spatial axes. The roboRIO’s built-in accelerometer is a three-axis accelerometer.
Peripheral multi-axis accelerometers may simply output multiple analog voltages (and thus connect to the analog input ports, or (more commonly) they may communicate with one of the roboRIO’s serial buses.
roboRIO built-in accelerometer
The roboRIO has a built-in accelerometer, which does not need any external connections. You can find more details about how to use it in the Built-in Accelerometer section of the software documentation.
IMUs (Inertial Measurement Units)
Several popular FRC devices (known as “inertial measurement units,” or “IMUs”) combine both an accelerometer and a gyroscope. Popular FRC example include: