forked from natanaeljr/esp32-MPU-driver
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Andrii Teslia
committed
Aug 3, 2023
1 parent
c82b005
commit f753a12
Showing
45 changed files
with
11,084 additions
and
10,168 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,27 @@ | ||
set(COMPONENT_SRCS | ||
"src/MPU.cpp") | ||
set(COMPONENT_ADD_INCLUDEDIRS "include") | ||
set(COMPONENT_REQUIRES "I2Cbus") | ||
|
||
register_component() | ||
|
||
component_compile_options(PUBLIC -DMPU_COMPONENT_TRUE=1) | ||
|
||
## Defines needed for library code implementation | ||
# MPU9250 is the same as MPU6500 + AK8963 | ||
# MPU9150 is the same as MPU6050 + AK8975 | ||
# MPU6000 code is the same as MPU6050 code | ||
# MPU6555 equals MPU6500, MPU9255 equals MPU9250 | ||
if(${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9250") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6500) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9150") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6050) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU6000") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6050) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU6555") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6500) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9255") | ||
component_compile_options(PUBLIC -DCONFIG_MPU9250 -DCONFIG_MPU6500) | ||
endif() | ||
set(COMPONENT_SRCS | ||
"src/MPU.cpp") | ||
set(COMPONENT_ADD_INCLUDEDIRS "include") | ||
set(COMPONENT_REQUIRES "I2Cbus") | ||
|
||
register_component() | ||
|
||
component_compile_options(PUBLIC -DMPU_COMPONENT_TRUE=1) | ||
|
||
## Defines needed for library code implementation | ||
# MPU9250 is the same as MPU6500 + AK8963 | ||
# MPU9150 is the same as MPU6050 + AK8975 | ||
# MPU6000 code is the same as MPU6050 code | ||
# MPU6555 equals MPU6500, MPU9255 equals MPU9250 | ||
if(${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9250") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6500) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "ICM20948") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6500) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9150") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6050) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU6000") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6050) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU6555") | ||
component_compile_options(PUBLIC -DCONFIG_MPU6500) | ||
elseif (${CONFIG_MPU_CHIP_MODEL} STREQUAL "MPU9255") | ||
component_compile_options(PUBLIC -DCONFIG_MPU9250 -DCONFIG_MPU6500) | ||
endif() |
Oops, something went wrong.