Skip to content

feature: Initial commit with bmi160 driver #693

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@ or [GitLab examples](https://gitlab.com/UncleRus/esp-idf-lib/tree/master/example

| Component | Description | License | Supported on | Thread safety |
| --------- | ----------- | ------- | ------------ | ------------- |
| **bmi160** | Driver for BMI160 6-DOF IMU | ISC | esp32, esp8266, esp32s2, esp32c3, esp32s3, esp32c2, esp32c6, esp32h2, esp32p4, esp32c5, esp32c61 | yes |
| **icm42670** | Driver for TDK ICM-42670-P 6-Axis IMU | ISC | esp32, esp8266, esp32s2, esp32c3, esp32s3, esp32c2, esp32c6, esp32h2, esp32p4, esp32c5, esp32c61 | yes |
| **l3gx** | Driver for L3Gx(L3GD20/L3G4200D) 3-axis gyroscope sensors | BSD-3-Clause | esp32, esp8266, esp32s2, esp32c3, esp32s3, esp32c2, esp32c6, esp32h2, esp32p4, esp32c5, esp32c61 | yes |
| **lsm303** | Driver for LSM303 3-axis accelerometer and magnetometer sensor | BSD-3-Clause | esp32, esp8266, esp32s2, esp32c3, esp32s3, esp32c2, esp32c6, esp32h2, esp32p4, esp32c5, esp32c61 | yes |
Expand Down Expand Up @@ -385,6 +386,8 @@ or [GitLab examples](https://gitlab.com/UncleRus/esp-idf-lib/tree/master/example

- [Lucio Tarantino](https://github.com/dianlight): `ads111x`

- [Lukasz Bielinski](https://github.com/lukbieli): `bmi160`

- [Manuel Markwort](https://github.com/mmarkwort): `mp2660` `tps63101x`

- [Marc Luehr](https://github.com/th3link): `veml7700`
Expand Down
28 changes: 28 additions & 0 deletions components/bmi160/.eil.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: bmi160
description: Driver for BMI160 6-DOF IMU
version: 1.0.0
groups:
- imu
code_owners: lukbieli
depends:
- log
- esp_idf_lib_helpers
- i2cdev
thread_safe: yes
targets:
- esp32
- esp8266
- esp32s2
- esp32c3
- esp32s3
- esp32c2
- esp32c6
- esp32h2
- esp32p4
- esp32c5
- esp32c61
license: ISC
copyrights:
- name: lukbieli
year: 2025
13 changes: 13 additions & 0 deletions components/bmi160/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
if(${IDF_TARGET} STREQUAL esp8266)
set(req esp8266 freertos i2cdev log esp_idf_lib_helpers)
elseif(${IDF_VERSION_MAJOR} STREQUAL 4 AND ${IDF_VERSION_MINOR} STREQUAL 1 AND ${IDF_VERSION_PATCH} STREQUAL 3)
set(req driver freertos i2cdev log esp_idf_lib_helpers)
else()
set(req driver freertos i2cdev log esp_idf_lib_helpers)
endif()

idf_component_register(
SRCS "bmi160.c"
INCLUDE_DIRS .
REQUIRES ${req}
)
13 changes: 13 additions & 0 deletions components/bmi160/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Copyright (c) 2025 Lukasz Bielinski <[email protected]>

Permission to use, copy, modify, and distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
11 changes: 11 additions & 0 deletions components/bmi160/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# `Driver for BMI160`

## Description:

The small, low power BMI160 is a low noise 16-bit IMU designed for mobile applications such as AR or indoor navigation, providing highly accurate sensor data and real-time sensor data. The low current consumption of BMI160 enables always-on applications in battery-driven devices. This sensor features a configurable on-chip interrupt engine which provides motion-based gesture recognition and context awareness as always-on background functions.

## Features:

- Supports regular constant readout throug pulling or interrupt
- Step counting
- Tap detecting
Loading
Loading