Commit d186f7e1 authored by Nicole Faerber's avatar Nicole Faerber
Browse files

Extend test script, add test audio wav file

parent 3ac4cbdc
......@@ -72,6 +72,18 @@ else
echo "BQ25890 fail" >> /tmp/l5dvk-test.log;
fi
if [ -e /dev/mtd0 ]; then
echo -n "Purism SPC" > /dev/mtd0; sync
hexdump -n 10 -e '8/1 "%c"' /dev/mtd0ro | grep "Purism SPC"
if [ $? = 0 ]; then
echo "SPIflash pass" >> /tmp/l5dvk-test.log;
else
echo "SPIflash fail" >> /tmp/l5dvk-test.log;
fi
else
echo "SPIflash fail" >> /tmp/l5dvk-test.log;
fi
# I2C devices bus 0: 4b, 52, 68, 6b
if [ -e /sys/class/i2c-adapter/i2c-0/0-004b/bd71837-pmic/registers ]; then
echo "I2C0@4b pass" >> /tmp/l5dvk-test.log;
......@@ -126,7 +138,47 @@ fi
whiptail --title "Hardware presence" --scrolltext --textbox /tmp/l5dvk-test.log 15 60
amixer sset "Lineout" 31
amixer sset "PCM" 154
amixer sset "Headphone" 127
amixer sset "Lineout" 31 > /dev/null 2>&1
amixer sset "PCM" 154 > /dev/null 2>&1
amixer sset "Headphone" 127 > /dev/null 2>&1
whiptail --yesno "Is there a picture on the HDMI screen?" 15 60
whiptail --msgbox "Listen for sound from headphone and speaker" 15 60
aplay /usr/local/bin/piano2.wav > /dev/null 2>&1
whiptail --yesno "Sound heard?" 15 60
whiptail --msgbox "Watch user LED blink two times" 15 60
echo 1 > /sys/class/leds/LED\ 1/brightness
sleep 1
echo 0 > /sys/class/leds/LED\ 1/brightness
sleep 1
echo 1 > /sys/class/leds/LED\ 1/brightness
sleep 1
echo 0 > /sys/class/leds/LED\ 1/brightness
whiptail --yesno "LED OK?" 15 60
whiptail --msgbox "Vibration motor will vibrate two times" 15 60
echo 128 > /sys/class/leds/nxp\:\:haptic/brightness
sleep 1
echo 0 > /sys/class/leds/nxp\:\:haptic/brightness
sleep 1
echo 128 > /sys/class/leds/nxp\:\:haptic/brightness
sleep 1
echo 0 > /sys/class/leds/nxp\:\:haptic/brightness
whiptail --yesno "Motor OK?" 15 60
whiptail --msgbox "Will activate WiFi and scan\nthis takes up to 15 seconds" 15 60
modprobe rsi_sdio > /dev/null 2>&1
sleep 2
nmcli device wifi list | grep NETGEAR13 > /dev/null
if [ $? = 0 ]; then
echo "WiFi pass" >> /tmp/l5dvk-test.log;
whiptail --msgbox "WiFi OK, scan OK" 15 60
else
echo "WiFi fail" >> /tmp/l5dvk-test.log;
whiptail --msgbox "WiFi OK, scan OK" 15 60
fi
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment