-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update XPowersLib & SensorLib to master
- Loading branch information
Showing
161 changed files
with
101,809 additions
and
10,391 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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*.hpp linguist-language=C++ | ||
|
||
|
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.pio | ||
.vscode | ||
test | ||
.travis.yml | ||
test | ||
assets | ||
*.bk | ||
*.test | ||
build | ||
*.old | ||
sdkconfig |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
set(src_dirs ./src | ||
./src/touch | ||
./src/platform) | ||
set(include_dirs ./src | ||
./src/REG | ||
./src/touch | ||
./src/platform) | ||
idf_component_register(SRC_DIRS ${src_dirs} | ||
INCLUDE_DIRS ${include_dirs} | ||
REQUIRES esp_timer esp_driver_gpio driver) |
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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
menu "SensorLib Configuration" | ||
|
||
choice SensorLib_ESP_IDF_API | ||
prompt "SensorLib library esp-idf api version" | ||
default SENSORLIB_ESP_IDF_NEW_API | ||
help | ||
Define API version | ||
|
||
config SENSORLIB_ESP_IDF_NEW_API | ||
bool "Use esp-idf higher version (>= 5.0) API" | ||
config SENSORLIB_ESP_IDF_OLD_API | ||
bool "Use esp-idf lower version ( < 5.0) API , Compatible with lower versions of esp-idf" | ||
endchoice | ||
|
||
|
||
endmenu |
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
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 |
---|---|---|
|
@@ -25,7 +25,7 @@ | |
* @file BHI260AP_6DoF.ino | ||
* @author Lewis He ([email protected]) | ||
* @date 2023-09-06 | ||
* | ||
* @note Changed from Boschsensortec API https://github.com/boschsensortec/BHY2_SensorAPI | ||
*/ | ||
#include <Wire.h> | ||
#include <SPI.h> | ||
|
@@ -48,7 +48,7 @@ | |
|
||
|
||
SensorBHI260AP bhy; | ||
void accel_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void accel_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
struct bhy2_data_xyz data; | ||
float scaling_factor = get_sensor_default_scaling(sensor_id); | ||
|
@@ -63,7 +63,7 @@ void accel_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | |
} | ||
|
||
|
||
void gyro_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void gyro_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
struct bhy2_data_xyz data; | ||
float scaling_factor = get_sensor_default_scaling(sensor_id); | ||
|
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 |
---|---|---|
|
@@ -25,7 +25,7 @@ | |
* @file BHI260AP_DebugInfo.ino | ||
* @author Lewis He ([email protected]) | ||
* @date 2023-10-08 | ||
* | ||
* @note Changed from Boschsensortec API https://github.com/boschsensortec/BHY2_SensorAPI | ||
*/ | ||
#include <Wire.h> | ||
#include <SPI.h> | ||
|
@@ -49,7 +49,7 @@ | |
SensorBHI260AP bhy; | ||
|
||
|
||
void quaternion_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void quaternion_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
Serial.println(bhy.getSensorName(sensor_id)); | ||
} | ||
|
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 |
---|---|---|
|
@@ -25,7 +25,7 @@ | |
* @file BHI260AP_Orientation.ino | ||
* @author Lewis He ([email protected]) | ||
* @date 2023-10-07 | ||
* | ||
* @note Changed from Boschsensortec API https://github.com/boschsensortec/BHY2_SensorAPI | ||
*/ | ||
#include <Wire.h> | ||
#include <SPI.h> | ||
|
@@ -46,7 +46,7 @@ | |
#define BHI260AP_RST 47 | ||
#endif | ||
|
||
void orientation_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len); | ||
void orientation_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp); | ||
|
||
SensorBHI260AP bhy; | ||
|
||
|
@@ -106,7 +106,7 @@ void loop() | |
} | ||
|
||
|
||
void orientation_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void orientation_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
char report[256]; | ||
uint8_t direction = *data_ptr; | ||
|
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 |
---|---|---|
|
@@ -25,7 +25,7 @@ | |
* @file BHI260AP_StepCounter.ino | ||
* @author Lewis He ([email protected]) | ||
* @date 2023-10-08 | ||
* | ||
* @note Changed from Boschsensortec API https://github.com/boschsensortec/BHY2_SensorAPI | ||
*/ | ||
#include <Wire.h> | ||
#include <SPI.h> | ||
|
@@ -49,13 +49,13 @@ | |
SensorBHI260AP bhy; | ||
|
||
|
||
void step_detector_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void step_detector_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
Serial.print(bhy.getSensorName(sensor_id)); | ||
Serial.println(" detected."); | ||
} | ||
|
||
void step_counter_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len) | ||
void step_counter_process_callback(uint8_t sensor_id, uint8_t *data_ptr, uint32_t len, uint64_t *timestamp) | ||
{ | ||
Serial.print(bhy.getSensorName(sensor_id)); | ||
Serial.print(":"); | ||
|
Oops, something went wrong.