Add optional BMA456 accelerometer init on shared I2C bus.
Probe and configure the sensor when present; log and continue boot if init fails so boards without BMA456 still run normally. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#ifndef BOSCH456_H
|
||||
#define BOSCH456_H
|
||||
|
||||
#include "driver/i2c_types.h"
|
||||
#include "esp_err.h"
|
||||
|
||||
#define TOUCH_1 9
|
||||
#define TOUCH_2 8
|
||||
|
||||
#define BMA456_ADDRESS 0x18
|
||||
|
||||
/** Initialize BMA456 on the shared I2C bus. Returns ESP_OK or logs and skips sensor use. */
|
||||
esp_err_t init_bma456(i2c_master_bus_handle_t bus_handle);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user