06-23-2019, 07:16 AM
It seems that the debounce function in GPIO does not work in the way it should.
I use GPIO (pin 14) to initiate a smooth shutdown: "sudo shutdown -h now"
This signal comes from a glitch free source: a mini supercap based UPS, that powers the PI for at least 30 seconds to prevent SD card damage.
(0V = UPS OK, 3.3V indicates a powerfailure, and shutdown is required)
I tried different settings for debounde (1000ms...2000ms) but this does not add any delay in response, which I would expect.
Upon first detection (edge) of the pin level change, the shutdown is instantly carried out.
I started to notice this, as when a big transformer in the room next door was turned off, this also stopped the music.
Upon check, it was found that the PI nicely shutdown-ed itself...
As these EMI spikes from the transformer are very short, a 2ms debounce would have worked, a 1000ms for sure would make
the PI blind to any noisy input
@ Tim,
Could you have a check if my statement is correct?
Second: marvelous player you & the team put together!
i use a PI3B+, Allo BOSS DAC & 7" standard touch display.. it works really good.
Regards from Taiwan
I use GPIO (pin 14) to initiate a smooth shutdown: "sudo shutdown -h now"
This signal comes from a glitch free source: a mini supercap based UPS, that powers the PI for at least 30 seconds to prevent SD card damage.
(0V = UPS OK, 3.3V indicates a powerfailure, and shutdown is required)
I tried different settings for debounde (1000ms...2000ms) but this does not add any delay in response, which I would expect.
Upon first detection (edge) of the pin level change, the shutdown is instantly carried out.
I started to notice this, as when a big transformer in the room next door was turned off, this also stopped the music.
Upon check, it was found that the PI nicely shutdown-ed itself...
As these EMI spikes from the transformer are very short, a 2ms debounce would have worked, a 1000ms for sure would make
the PI blind to any noisy input
@ Tim,
Could you have a check if my statement is correct?
Second: marvelous player you & the team put together!
i use a PI3B+, Allo BOSS DAC & 7" standard touch display.. it works really good.
Regards from Taiwan