mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-08-22 00:33:44 +08:00
@@ -155,7 +155,8 @@ class Soundd:
|
||||
while True:
|
||||
sm.update(0)
|
||||
|
||||
if sm.updated['soundPressure'] and self.current_alert == AudibleAlert.none: # only update volume filter when not playing alert
|
||||
# Always update volume, even when alert is playing
|
||||
if sm.updated['soundPressure']:
|
||||
self.spl_filter_weighted.update(sm["soundPressure"].soundPressureWeightedDb)
|
||||
self.current_volume = self.calculate_volume(float(self.spl_filter_weighted.x))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user