nickpourazima / rotary-phone-audio-guestbook

Audio guestbook using an old rotary phone and a raspberry pi zero
MIT License
57 stars 15 forks source link

Things stop working after a few recordings #66

Open mdavis1982 opened 2 weeks ago

mdavis1982 commented 2 weeks ago

I've just set up a new project with the latest release.

I'm using a normally closed switch. Everything appears to work fine for the first few recordings and then when putting the receiver down the recording just doesn't stop.

When this happens, toggling the switch a few more times sometimes makes things work again, but other times a reboot is required to stop the recording.

I'm not sure how to debug this.

nickpourazima commented 2 weeks ago

Hi @mdavis1982 ,

Thanks for checking out this project!

Let's see if we can check a few things first:

  1. Does an increase in hook_bounce_time resolve it? The current bounce time of 0.1 seconds may not be sufficient to filter out all spurious signals from the switch. Try increasing this value to 0.2 or 0.3 seconds:

    hook_bounce_time: 0.3
  2. Ensure that the switch is properly connected to the GPIO pin and ground. A loose connection could cause intermittent behavior.

  3. If 1. doesn't address the situation we can talk about potentially adding an RC circuit:

rc-debounce-circuit

And this would require a few software tweaks to dial in namely:

hook_bounce_time: 0.05
hook = Button(22, pull_up=None, active_state=False)

Keep me posted on what you're seeing, I'm here to help!

mdavis1982 commented 2 weeks ago

@nickpourazima Thanks... I'll check this out.

Is there a way of tailing the logs so that I can see exactly what's happening as I'm running the project?

I'm using the release version just flashed to the SD card with Raspberry Pi Imager.

nickpourazima commented 2 weeks ago

Check out the debugging section