Skip to content
Snippets Groups Projects
Commit 52b70460 authored by schneider's avatar schneider
Browse files

change(bme680): Keep BME680 always initialized

parent 021dc800
No related branches found
No related tags found
No related merge requests found
......@@ -104,6 +104,13 @@ err:
int epic_bme680_deinit()
{
/* This is an intentional NO OP to keep the BME680 always initialized.
*
* If it configured to foreced mode, there is no energy consumption
* penalty.
*/
#if 0
if (!initialized) {
return 0;
}
......@@ -117,6 +124,7 @@ int epic_bme680_deinit()
hwlock_release(HWLOCK_I2C);
initialized = false;
#endif
return 0;
}
......
......@@ -194,6 +194,11 @@ int hardware_early_init(void)
max86150_shut_down();
/*
* BME680 Sensor
*/
epic_bme680_init();
/* Allow user space to trigger interrupts.
* Used for BLE, not sure if needed. */
SCB->CCR |= SCB_CCR_USERSETMPEND_Msk;
......@@ -276,11 +281,6 @@ int hardware_reset(void)
*/
epic_bhi160_disable_all_sensors();
/*
* BME680 Sensor
*/
epic_bme680_deinit();
epic_max30001_disable_sensor();
epic_max86150_disable_sensor();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment