sound noise detecting1 make IP camera using raspberry pi 4 (14) sound detecting 만드는 순서가 뒤죽박죽이긴 한데 아이가 울면 핸드폰 알람이 울리도록 하기 위해서 sound detecting을 준비하기로 했다. 먼저 rpi에서 python으로 recording기능을 테스트 함. https://makehappylife.tistory.com/entry/rpi-%EB%A7%88%EC%9D%B4%ED%81%AC-%ED%99%95%EC%9D%B8-%EB%B0%8F-%EB%85%B9%EC%9D%8C python pyaudio를 통해 sound입력레벨을 알 수 있고, threshold를 정해 지정시간동안 큰 소리가 발생하면 디텍팅이 가능하다. 디텍팅 함수를 아래와 같이 구현하였다. def detect_sound(data_chunk): THRESHOLD = 350 compare = max(data_.. 2022. 3. 2. 이전 1 다음