Uncategorized

amp hat button notes

Asked 
Active today
Viewed 55 times
2

I’m currently having trouble with my project. I’m using a Raspberry Pi 3B+ with an InnoMaker Hifi Amp Hat and some push buttons.

import time
import signal
import os
import RPi.GPIO as GPIO

GPIO.setmode(GPIO.BCM)

debounceTime = 300

btn1 = 24
btn2 = 25
btn3 = 13
btn4 = 12
btn5 = 16

def cb_btn1(channel):
    print('Button 1 pressed')

def cb_btn2(channel):
    print('Button 2 pressed')

def cb_btn3(channel):
    print('Button 3 pressed')

def cb_btn4(channel):
    print('Button 4 pressed')

def cb_btn5(channel):
    print('Button 5 pressed')

class GracefulExit:
    kill_now = False
    def __init__(self):
        signal.signal(signal.SIGINT, self.exit_gracefully)
        signal.signal(signal.SIGTERM, self.exit_gracefully)

    def exit_gracefully(self,signum, frame):
        self.kill_now = True

GPIO.setup(btn1, GPIO.IN, pull_up_down=GPIO.PUD_UP)
GPIO.setup(btn2, GPIO.IN, pull_up_down=GPIO.PUD_UP)
GPIO.setup(btn3, GPIO.IN, pull_up_down=GPIO.PUD_UP)
GPIO.setup(btn4, GPIO.IN, pull_up_down=GPIO.PUD_UP)
GPIO.setup(btn5, GPIO.IN, pull_up_down=GPIO.PUD_UP)

GPIO.add_event_detect(btn1, GPIO.FALLING, callback=cb_btn1, bouncetime=debounceTime)
GPIO.add_event_detect(btn2, GPIO.FALLING, callback=cb_btn2, bouncetime=debounceTime)
GPIO.add_event_detect(btn3, GPIO.FALLING, callback=cb_btn3, bouncetime=debounceTime)
GPIO.add_event_detect(btn4, GPIO.FALLING, callback=cb_btn4, bouncetime=debounceTime)
GPIO.add_event_detect(btn5, GPIO.FALLING, callback=cb_btn5, bouncetime=debounceTime)

def main():
    app_killer = GracefulExit()
    while not app_killer.kill_now:
        try:
            time.sleep(0.5)
        except BaseException:
            GPIO.cleanup()
            print "Encountered an axeption."
            break
    print "End of the program."
    GPIO.cleanup()

if __name__ == '__main__':
    main()

I’ve tried with external pull-up/down and also adding a 0.1uF cap between 3.3V / GND and the GPIO.

I’m not using any pins that the Hat is supposed to use (GPIOs 18 to 21) according to the manual

My setup us currently on a breadboard, maybe I’m getting EMI with the jumpers wires…

I’m using a good quality power supply so I hope the problem isn’t coming from here… For reference it’s a Mean Well GSM40A12-P1J

I’ve discovered that touching the metal Ethernet/USB port with the metal tip of an USB flash drive or the tips of my multimeter probe trigger almost all my GPIO each times.

Is there something that I’m missing to get reliable input?

Schematics Breadboard pictures


Edit: Ok I’m slowly putting the pieces together. In order to make pigpiod running on a non full raspbian image in addition to sudo apt install pigpiodI had to run sudo apt install python3-pigpio

Now running python3 monitor.py 12 13 16 24 25 show me this

[...]
G=18 l=1 d=30
G=13 l=1 d=5
G=18 l=0 d=5
G=13 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=5
G=18 l=0 d=25
G=18 l=1 d=5
G=18 l=0 d=25
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=115
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=66
G=18 l=0 d=5
G=18 l=1 d=84
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=10
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=15
G=18 l=1 d=20
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=121
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=29
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=10
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=16 l=1 d=9865
G=16 l=0 d=5
G=16 l=1 d=10
G=25 l=1 d=9865
G=16 l=0 d=5
G=25 l=0 d=5
G=16 l=1 d=10
G=25 l=1 d=10
G=16 l=0 d=5
G=25 l=0 d=5
G=16 l=1 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=25 l=1 d=10
G=25 l=0 d=5
G=25 l=1 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=24 l=1 d=9855
G=24 l=0 d=5
G=24 l=1 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=12 l=1 d=9775
G=13 l=1 d=9755
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=10
G=18 l=1 d=5
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=110
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=10
G=18 l=1 d=20
G=18 l=0 d=25
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=10
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=90
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=55
G=18 l=0 d=10
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=115
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=105
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=170
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=95
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=115
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=110
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=110
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=95
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=125
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=16 l=0 d=10085
G=25 l=0 d=10090
G=16 l=1 d=30
G=25 l=1 d=10
G=16 l=0 d=5
G=25 l=0 d=5
G=16 l=1 d=10
G=25 l=1 d=10
G=16 l=0 d=5
G=25 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=24 l=0 d=10125
G=24 l=1 d=5
G=18 l=1 d=55
G=24 l=0 d=5
G=18 l=0 d=5
G=24 l=1 d=5
G=24 l=0 d=10
G=24 l=1 d=25
G=24 l=0 d=5
G=18 l=1 d=130
G=18 l=0 d=5
G=12 l=0 d=10235
G=13 l=0 d=10220
G=12 l=1 d=15
G=13 l=1 d=15
G=12 l=0 d=5
G=13 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=30
G=18 l=1 d=5
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=185
G=18 l=0 d=10
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=165
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=105
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=10
G=18 l=1 d=115
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=140
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=145
G=18 l=0 d=5
G=18 l=1 d=225
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=171
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=4
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=10
G=18 l=1 d=150
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=145
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=16 l=1 d=9875
G=25 l=1 d=9875
G=25 l=0 d=5
G=25 l=1 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=24 l=1 d=9765
G=24 l=0 d=5
G=24 l=1 d=10
G=24 l=0 d=5
G=18 l=1 d=30
G=24 l=1 d=10
G=18 l=0 d=5
G=24 l=0 d=10
G=24 l=1 d=5
G=12 l=1 d=9745
G=13 l=1 d=9755
G=18 l=1 d=350
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=10
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=95
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=10
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=135
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=125
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=125
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=115
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=110
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=66
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=64
G=18 l=0 d=5
G=18 l=1 d=90
G=18 l=0 d=5
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=180
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=315
G=18 l=0 d=5
G=18 l=1 d=135
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=55
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=150
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=145
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=145
G=18 l=0 d=5
G=18 l=1 d=75
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=165
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=191
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=84
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=100
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=140
G=18 l=0 d=5
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=18 l=1 d=35
G=18 l=0 d=5
G=18 l=1 d=105
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=90
G=18 l=0 d=5
G=18 l=1 d=90
G=18 l=0 d=5
G=18 l=1 d=60
G=18 l=0 d=5
G=18 l=1 d=185
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=40
G=18 l=0 d=5
G=16 l=0 d=10060
G=16 l=1 d=10
G=16 l=0 d=5
G=25 l=0 d=10070
G=16 l=1 d=15
G=25 l=1 d=10
G=16 l=0 d=5
G=25 l=0 d=10
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=24 l=0 d=10145
G=18 l=1 d=45
G=18 l=0 d=5
G=18 l=1 d=70
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=12 l=0 d=10210
G=12 l=1 d=5
G=12 l=0 d=5
G=13 l=0 d=10210
G=13 l=1 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=13 l=0 d=20
G=12 l=1 d=30
G=13 l=1 d=5
G=12 l=0 d=5
G=13 l=0 d=5
G=13 l=1 d=10
G=13 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=135
G=18 l=0 d=5
G=18 l=1 d=15
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=10
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=10
G=18 l=1 d=25
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=95
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=10
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=85
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=20
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=10
G=18 l=1 d=170
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
G=18 l=1 d=110
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=50
G=18 l=0 d=5
G=18 l=1 d=105
G=18 l=0 d=5
G=18 l=1 d=80
G=18 l=0 d=10
G=18 l=1 d=185
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=190
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=105
G=18 l=0 d=5
G=18 l=1 d=10
G=18 l=0 d=5
G=18 l=1 d=65
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=155
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=120
G=18 l=0 d=5
G=18 l=1 d=30
G=18 l=0 d=5
G=18 l=1 d=145
G=18 l=0 d=5
G=18 l=1 d=5
G=18 l=0 d=5
[...]
 New contributor
  • I wouldn’t expect that problem with the set up as described. Could we have a clear photo showing the connections to the Pi? – joan 2 days ago
  • I’ve removed the GPIO protection resistors since they aren’t mandatory and make the setup clearer on the pictures – Sébastien 2 days ago
  • Sorry I’m not familiar with pigpiod, I’ve installed it via sudo apt install pigpiodand running via sudo pigpiod. Trying to run the script tells me ImportError: No module named pigpio. Is there any additional package to install? I can’t see on PyPl any python module called pigpio only apigpio but I’m assuming that this is totally different? – Sébastien 2 days ago
  • I’m running Raspbian Lite, if I ps -auxI can see root 2400 6.3 0.1 9976 1632 ? SLsl 04:07 0:12 pigpiod but then when I try python monitor.pyI have Traceback (most recent call last): File "monitor.py", line 12, in <module> import pigpio ImportError: No module named pigpio If I try sudo pigpiodagain I have 2019-10-17 05:49:58 initInitialise: Can't lock /var/run/pigpio.pid Can't initialise pigpio library – Sébastien 2 days ago
  • You can say which GPIO to monitor. In this case the switches so run as ./monitor.py 12 13 16 24 25 – joan 2 days ago

2 Answers

0

To mitigate against unwanted events I suggest you use code similar to the following. Basically read the level of the GPIO in the callback to verify it is not a short term transient.

#!/usr/bin/env python

import time
import signal
import os
import RPi.GPIO as GPIO

GPIO.setmode(GPIO.BCM)

buttons=[24, 25, 13, 12, 16]

def cb_buttons(channel):
   if GPIO.input(channel) == 0:
      btn = buttons.index(channel) + 1
      print("Button {} pressed".format(btn))

class GracefulExit:
    kill_now = False
    def __init__(self):
        signal.signal(signal.SIGINT, self.exit_gracefully)
        signal.signal(signal.SIGTERM, self.exit_gracefully)

    def exit_gracefully(self,signum, frame):
        self.kill_now = True

for btn in buttons:
   GPIO.setup(btn, GPIO.IN, pull_up_down=GPIO.PUD_UP)
   GPIO.add_event_detect(btn, GPIO.FALLING, callback=cb_buttons)

def main():
    app_killer = GracefulExit()
    while not app_killer.kill_now:
        try:
            time.sleep(0.5)
        except BaseException:
            GPIO.cleanup()
            print "Encountered an axeption."
            break
    print "End of the program."
    GPIO.cleanup()

if __name__ == '__main__':
    main()

  • I’m letting the script running, I can’t manage to get the event to trigger accidentally now when I’m inserting an USB thumb drive, that’s already a win there – Sébastien 18 hours ago

0

Question

Rpi GPIO push buttons connected to HiFi amplifier HAT have false detection problems. How to fix it?

/ to continue, …


Answer

You HAT has 40 pins connected to the Rpi. So we need to make sure if the HAT already uses the GPIO pins you are using for your push button detection circuit.

Or are you already following the user manual and use the GPIO pins recommended there. I googled and noticed that the vendor has a software download site. Perhaps you might let us know which driver you are using.

Let me first study the circuit, to make sure if it is related to the amplifier, or to push button circuit only.


The following schematic seems to say the HAT is using a couple of GPIO pins I2C, I2S, and Infrared control. So you should make sure if your push button circuit does not use the same pins.

amp hat 40 pin schematic

And there seems another complication. They seems to have a default player software which the HAT expects to use which you power on the Rpi which will read the HAT configuration and drivers etc from the HAT’s built in EEPROM, and starts the player software. But I am not sure at all, just wild guessing. You might like to confirm you are reading the same user guide as mine.


Pins already used by HAT

pins used


I also read that Inno has a propriety player software called volumio, which you can download and install.

This way you don’t need to DIY your own push button controls. Please confirm if you would like to try this volumio software or already tried and still wish to carry on the push button circuit.

I am happy to try to solve the original false triggering problem.

volumio 1

/ to continue, …


References

(1) Amazon Inno-Maker Rpi HiFi 25W Class-D Power TAS5713 Amplifier HAT – USD27

(2) Inno Maker HiFi Amplifier HAT Ad – US$40

(3) Inno Maker HiFi Amplifier HAT Video

(4) Inno Maker HiFi Amplifier HAT User Manual

(5) Inno Maker HiFi Amplifier HAT Software/Documentation

/ to continue, …


Appendices

Appendix A – Amazon Inno-Maker Rpi HiFi Amplifier Features

Rpi 3/3B+/4B,Aero/ZeroW 40 pin connector, no external cables required

Supports OSMC, Max2Play, RuneAudio, Volumio, Moode, Pi CorePlayer, Pi MusicBox, OpenELEC, DSD over PCM(DOP)

Supports playing music form hard disk or network

On-board TAS5713 25-W Class-D digital-audio power amplifier for driving stereo bridge-tied speakers

Accept input data 8-Khz to 48-Khz, 4 Ohm speakers

/ to continue, …


End of answer

Categories: Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: