Arduino_LSM6DS3

Sensors

Allows you to read the accelerometer, gyroscope, and temperature values from the LSM6DS3 IMU on your Arduino Nano 33 IoT or Arduino Uno WiFi Rev2 boards.

Go to repository

Compatibility

This library is compatible with all architectures so you should be able to use it on all the Arduino boards.

Releases

To use this library, open the Library Manager in the Arduino IDE and install it from there.

Usage

The ArduinoLSM6DS3 library allows you to use the inertial measurement unit (IMU) available on the Arduino® Nano 33 IoT board and the Arduino® UNO WiFi Rev 2 board. The IMU is a LSM6DS3, it has a 3-axis accelerometer and a 3-axis gyroscope. The IMU is connected through I2C on the Nano 33 IoT board’s microcontroller and through SPI on the UNO WiFi Rev. 2 board’s microcontroller. The values returned are signed floats.

To use this library:

#include <Arduino_LSM6DS3.h>

The ArduinoLSM6DS3 library takes care of the sensor initialization and sets its values as follows:

  • Accelerometer range is set at ±4 g with a resolution of 0.122 mg.
  • Gyroscope range is set at ±2000 dps with a resolution of 70 mdps.
  • Output data rate is fixed at 104 Hz.

Methods