Fix WisBlock GPS power policy and preserve shared peripherals

This commit is contained in:
mikecarper committed 2026-10-13 09:55:32 -07:00
1 parent 9079d6f47e
commit 368770656f
26 files changed
+1830 -107

No files matched your search

+7
View File
@@ -162,6 +162,13 @@ public:
return false;
}
virtual LocationProvider* getLocationProvider() { return NULL; }
// WisBlock slot power is a boot-time choice, separate from logical GPS on/off.
virtual bool supportsSharedPeripheralMode() const { return false; }
virtual void configureSharedPeripheralMode(bool shared) { (void)shared; }
virtual bool isGpsPowered() const {
LocationProvider* location = const_cast<SensorManager*>(this)->getLocationProvider();
return location != NULL && location->isEnabled();
}
virtual void setPowerSavingEnabled(bool enabled) { powersaving_enabled = enabled; }
// Runtime bridges may temporarily own the UART used by a GPS receiver. A
// sensor manager that actually detected a GPS on that UART overrides these