VMP403
V. 01
–
15/04/2020
7
©Velleman nv
5.
Time to test. Connect a speaker or headphones, open a new Command Prompt and enter
following command:
o
arecord -f cd -
Dhw:1 │ aplay
-Dhw:1
Now, you should hear your own voice through the speaker/headphones.
Activating the On-Board RGB LEDs
Open the Command Prompt and enter following commands:
o
sudo pip install spidey
o
cd ~/
o
https://github.com/respeaker/mic_hat.git
o
cd mic_hat
o
python pixels.py
You can change the colour of the LEDs through the Command Prompt.
Using the On-Board User Button
1.
The press button on the ReSpeaker 2-mics is connected to the GPIO17. Enter following
commands:
o
sudo pip install rpi.gpio
o
nano userbutton.py
2.
Copy the code below into the Command Prompt:
import RPi.GPIO as GPIO
import time
GPIO.setmode(GPIO.BCM)
GPIO.setup(17, GPIO.IN, pull_up_down=GPIO.PUD_UP)
while True:
input_state = GPIO.input(17)
if input_state == False:
print(“Button Pressed”)
time.sleep(1)
else:
print(“Button Released”)
time.sleep(1)
Содержание VMP403
Страница 1: ...VMP403 USER MANUAL 2 ...