Snap for 10500749 from 32535854cc6920aa15a231af56c78282b9c4114f to udc-qpr1-release

Change-Id: I07a911310ab5a8252bdb08049c8637893399a9e4
This commit is contained in:
Android Build Coastguard Worker 2023-07-15 01:06:48 +00:00
commit 3fdd9f4d0d
2 changed files with 40 additions and 2 deletions

View File

@ -9,7 +9,26 @@ heatmap_path=$path
fi
echo "------ Force Touch Active ------"
echo 1 > $path/force_active
result=$( cat "$path/force_active" 2>&1 )
if [ $? -eq 0 ]; then
state=$( echo "$result" |cut -d " " -f 2 )
if [ "$state" = "locked" ]; then
echo "The force_active is already locked!"
else
echo 1 > $path/force_active
if [ $? -ne 0 ]; then
echo "Failed to active touch device"
exit 1
fi
fi
else
if [[ $result == *Operation\ not\ supported* ]]; then
echo "force_active is not support, skip it"
else
echo "Failed to read the state of force_force"
exit 1
fi
fi
echo "------ Touch Firmware Version ------"
cat $path/fw_ver

View File

@ -9,7 +9,26 @@ heatmap_path=$path
fi
echo "------ Force Touch Active ------"
echo 1 > $path/force_active
result=$( cat "$path/force_active" 2>&1 )
if [ $? -eq 0 ]; then
state=$( echo "$result" |cut -d " " -f 2 )
if [ "$state" = "locked" ]; then
echo "The force_active is already locked!"
else
echo 1 > $path/force_active
if [ $? -ne 0 ]; then
echo "Failed to active touch device"
exit 1
fi
fi
else
if [[ $result == *Operation\ not\ supported* ]]; then
echo "force_active is not support, skip it"
else
echo "Failed to read the state of force_force"
exit 1
fi
fi
echo "------ Touch Firmware Version ------"
cat $path/fw_ver