fgebhart / smart_alarm

IoT Open Source Alarm Clock
Apache License 2.0
16 stars 4 forks source link

Amplifier GPIO pin on/off switchin in wrong order #7

Open fgebhart opened 6 years ago

fgebhart commented 6 years ago

with the current configuration it seems like sometimes the amplifier is switched on even though there is no sound to be played. If some sound needs to be played afterwards, the amplifier will be switched off and it will not be possible to hear the sound.

https://github.com/fgebhart/smart_alarm/blob/1ad9f7d77b2c258df6527c8002156a7c8d430a51/smart_alarm/modules/sounds.py#L66

Suggestion: Implement Amplifier GPIO pin switching like a toggle switch. Turns on if off and off if on.