@@ -54,15 +54,16 @@ def set_threshold(event: SoundEvent, value: int) -> None:
5454
5555 Example: ``microphone.set_threshold(SoundEvent.LOUD, 250)``
5656
57- The ``SoundEvent.LOUD`` event will be triggered when the sound level
58- crosses this threshold upwards (from "quiet" to "loud"),
59- and ``SoundEvent.QUIET`` event is triggered when crossing the threshold
60- downwards (from "loud" to "quiet").
61-
62- If the ``SoundEvent.LOUD`` value set is lower than ``SoundEvent.QUIET``,
63- then "quiet" threshold will be decreased to one unit below the "loud"
64- threshold. If the ``SoundEvent.QUIET`` value is set higher than
65- ``SoundEvent.LOUD``, then the "loud" threshold will be set one unit above.
57+ The ``SoundEvent.LOUD`` event is triggered when the sound level crosses the
58+ threshold from "quiet" to "loud", and the ``SoundEvent.QUIET`` event is
59+ triggered when the sound level crosses from "loud" to "quiet".
60+
61+ If the ``SoundEvent.LOUD`` threshold is set lower than the
62+ ``SoundEvent.QUIET`` threshold, then the ``SoundEvent.QUIET`` threshold
63+ will decrease by one unit below the ``SoundEvent.LOUD`` threshold. If the
64+ ``SoundEvent.QUIET`` threshold is set higher than the ``SoundEvent.LOUD``
65+ threshold, then the ``SoundEvent.LOUD`` threshold will increase by one unit
66+ above the ``SoundEvent.QUIET`` threshold.
6667
6768 :param event: A sound event, such as ``SoundEvent.LOUD`` or ``SoundEvent.QUIET``.
6869 :param value: The threshold level in the range 0-255. Values outside this range will be clamped.
0 commit comments