Added detection sensor en pin to fix issues with RAK microwave (#2940)

This commit is contained in:
Ben Meadors
2023-11-15 09:26:47 -06:00
committed by GitHub
parent 8b16367597
commit 91e399a2b6
3 changed files with 13 additions and 3 deletions

View File

@@ -28,6 +28,12 @@ int32_t DetectionSensorModule::runOnce()
return disable();
if (firstTime) {
#ifdef DETECTION_SENSOR_EN
pinMode(DETECTION_SENSOR_EN, OUTPUT);
digitalWrite(DETECTION_SENSOR_EN, HIGH);
#endif
// This is the first time the OSThread library has called this function, so do some setup
firstTime = false;
if (moduleConfig.detection_sensor.monitor_pin > 0) {