Merge pull request #463 from GUVWAF/AmbientLighting

This commit is contained in:
Ben Meadors
2023-11-02 14:46:49 -05:00
committed by GitHub
2 changed files with 6 additions and 0 deletions

View File

@@ -874,6 +874,10 @@ class MeshInterface:
self.localNode.moduleConfig.detection_sensor.CopyFrom(
fromRadio.moduleConfig.detection_sensor
)
elif fromRadio.moduleConfig.HasField("ambient_lighting"):
self.localNode.moduleConfig.ambient_lighting.CopyFrom(
fromRadio.moduleConfig.ambient_lighting
)
else:
logging.debug("Unexpected FromRadio payload")

View File

@@ -192,6 +192,8 @@ class Node:
p.set_module_config.neighbor_info.CopyFrom(self.moduleConfig.neighbor_info)
elif config_name == "detection_sensor":
p.set_module_config.detection_sensor.CopyFrom(self.moduleConfig.detection_sensor)
elif config_name == "ambient_lighting":
p.set_module_config.ambient_lighting.CopyFrom(self.moduleConfig.ambient_lighting)
else:
our_exit(f"Error: No valid config with name {config_name}")