meta-bletchley: motor-ctrl: enable motor by pwm and gpio driver
1.enable bmc pwm output by sysfs
2.control motor vref by libgpiod-tools
3.Correct typo and formating
Change-Id: Ie0a57a12e328913f007cb2014d4205ded99c91b3
Signed-off-by: Allen.Wang <Allen_Wang@quantatw.com>
diff --git a/meta-facebook/meta-bletchley/recipes-bletchley/motor-ctrl/files/power-ctrl b/meta-facebook/meta-bletchley/recipes-bletchley/motor-ctrl/files/power-ctrl
index 111ce8b..eebe50c 100755
--- a/meta-facebook/meta-bletchley/recipes-bletchley/motor-ctrl/files/power-ctrl
+++ b/meta-facebook/meta-bletchley/recipes-bletchley/motor-ctrl/files/power-ctrl
@@ -28,7 +28,7 @@
function trigger_power_button() {
local sled_num=$1
- local delay_time=$2
+ local delay_time=$2
#SLED{N}_MS_DETECT1 (initial position)
GPIO_DETECT_PIN1="SLED${sled_num}_MS_DETECT1"
@@ -45,7 +45,7 @@
echo "Press power key for Sled${1} ${delay_time} seconds..."
sleep "$delay_time"
else
- echo "Power key switch not trigger, back motor to initail position"
+ echo "Power key switch not trigger, back motor to initial position"
fi
motor-ctrl "sled${sled_num}" r >/dev/null
@@ -54,7 +54,7 @@
if [ "$(get_gpio "$GPIO_DETECT_PIN1")" -eq 0 ];then
echo "Motor reverse to initial position successful"
else
- echo "Initail position switch not trigger, force stop motor"
+ echo "Initial position switch not trigger, force stop motor"
fi
}