78 lines
1.9 KiB
Bash
Executable File
78 lines
1.9 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
if [ "$DEVICE_IP" = "" ]; then
|
|
echo "Enter IP address: "
|
|
read DEVICE_IP
|
|
else
|
|
echo "Device ip is $DEVICE_IP"
|
|
fi
|
|
|
|
echo "Enter TV name: "
|
|
read TV_NAME
|
|
|
|
|
|
device_cmd_exec()
|
|
{
|
|
echo | netcat -t $DEVICE_IP 23 << EOF
|
|
$1
|
|
exit
|
|
EOF
|
|
}
|
|
|
|
device_echo()
|
|
{
|
|
device_cmd_exec "echo \"plugfest: ($TV_NAME): $1\" > /dev/ttyS0"
|
|
}
|
|
|
|
device_cmd()
|
|
{
|
|
device_cmd_exec "$1 > /dev/ttyS0"
|
|
}
|
|
|
|
echo_and_wait()
|
|
{
|
|
local ANY_KEY
|
|
device_echo "Begin: $1"
|
|
echo "#\n# $1\n#"
|
|
read ANY_KEY
|
|
if [ "$ANY_KEY" != "" ]; then
|
|
device_echo "End: $1. Note: $ANY_KEY"
|
|
fi
|
|
}
|
|
|
|
|
|
device_echo "####################################################"
|
|
device_echo "Testing Begin"
|
|
device_cmd "ConfigService -ro"
|
|
device_cmd "ConfigService -so fw.fastboot.capture.snapshot=false"
|
|
device_cmd "ConfigService -so fw.apibroker.failsafe-disable=true"
|
|
device_cmd "ConfigService -so fw.display-doctor-2.enabled=false"
|
|
device_cmd "ConfigService -so fw.display-doctor-2-settings.enabled=false"
|
|
device_cmd "ConfigService -lo"
|
|
device_cmd "[ -e /dev/mapper/snapshotree ] && mkswap /dev/mapper/snapshotree"
|
|
device_cmd "reboot"
|
|
|
|
device_echo "#1: Test Display Doctor 1"
|
|
echo_and_wait "Test Netflix & BBC"
|
|
|
|
device_echo "#2: Test All HDMI Ports. Hot plug in/plug out"
|
|
echo_and_wait "Plug/unplug device from HDMIs: "
|
|
|
|
device_echo "#3: CEC related tests"
|
|
echo_and_wait "Does Roku Name appear as the source input"
|
|
echo_and_wait "Test CEC functionality"
|
|
|
|
device_echo "#0: Running from TV USB"
|
|
device_echo "#5: Test Display Doctor 2"
|
|
echo_and_wait "'Enter' to configure and reboot"
|
|
device_cmd "ConfigService -so fw.display-doctor-2.enabled=true"
|
|
device_cmd "ConfigService -so fw.display-doctor-2-settings.enabled=true"
|
|
echo_and_wait "Check display doctor 2: "
|
|
echo_and_wait "Plug device from the TV USB, and wait till it boots, test Display Doctor2"
|
|
|
|
|
|
echo_and_wait "'Enter' to finish test"
|
|
device_echo "Testing Done"
|
|
device_echo "####################################################"
|
|
|