87 lines
1.8 KiB
Bash
87 lines
1.8 KiB
Bash
#!/bin/sh
|
|
#echo "start up qtui...."
|
|
export QT_QWS_FONTDIR=/usr/lib/fonts
|
|
export QWS_MOUSE_PROTO="TSLIB:/dev/input/event1 mouseman:/dev/input/mice"
|
|
|
|
cd /dev/ && ln -s am335x_visco_pwm pwm && ln -s am335x_suction_pwm pwm1
|
|
|
|
if [ -e /dev/input/touchscreen0 ]; then
|
|
TSLIB_TSDEVICE=/dev/input/touchscreen0
|
|
export TSLIB_CALIBFILE=/etc/pointercal
|
|
export TSLIB_CONFFILE=/usr/local/etc/ts.conf
|
|
export TSLIB_PLUGINDIR=/usr/lib/ts
|
|
export TSLIB_TSDEVICE
|
|
fi
|
|
|
|
|
|
if [ ! -f /etc/pointercal ];then
|
|
touch /etc/pointercal
|
|
ts_calibrate
|
|
fi
|
|
|
|
cd /home/plg
|
|
if [ ! -f /home/plg/runFlag ];then
|
|
chmod a+x InkJetPrinter
|
|
chmod a+x InkJetPrinterEng
|
|
if [ -f /home/plg/chinese ];then
|
|
./InkJetPrinter -qws
|
|
else
|
|
./InkJetPrinterEng -qws
|
|
fi
|
|
fi
|
|
sleep 2
|
|
|
|
if [ -f /home/plg/rebootFlag0 ];then
|
|
rm /home/plg/rebootFlag0
|
|
export QWS_MOUSE_PROTO="TSLIB:/dev/input/event0 mouseman:/dev/input/mice"
|
|
chmod a+x rebootWelcome.sh
|
|
./rebootWelcome.sh
|
|
|
|
fi
|
|
|
|
if [ -f /home/plg/rebootFlag1 ];then
|
|
rm /home/plg/rebootFlag1
|
|
export QWS_MOUSE_PROTO="TSLIB:/dev/input/event1 mouseman:/dev/input/mice"
|
|
chmod a+x rebootWelcome.sh
|
|
./rebootWelcome.sh
|
|
|
|
fi
|
|
|
|
if [ -f /home/plg/rebootFlag0 ];then
|
|
rm /home/plg/rebootFlag0
|
|
export QWS_MOUSE_PROTO="TSLIB:/dev/input/event0 mouseman:/dev/input/mice"
|
|
chmod a+x rebootWelcome.sh
|
|
./rebootWelcome.sh
|
|
|
|
fi
|
|
|
|
if [ -f /home/plg/rebootFlag1 ];then
|
|
rm /home/plg/rebootFlag1
|
|
export QWS_MOUSE_PROTO="TSLIB:/dev/input/event1 mouseman:/dev/input/mice"
|
|
chmod a+x rebootWelcome.sh
|
|
./rebootWelcome.sh
|
|
|
|
fi
|
|
|
|
#bootup QtUI
|
|
chmod +x QtUI
|
|
./QtUI -qws -display VNC:LinuxFb &
|
|
rm /home/plg/runFlag
|
|
|
|
sleep 1
|
|
#mount mmc and usb disk
|
|
if [ -f /dev/mmcblk0p1 ];then
|
|
mount /dev/mmcblk0p1 /mnt/mmc/
|
|
fi
|
|
|
|
ln -sf /mnt/udisk /udisk
|
|
if [ -f /dev/sda1 ];then
|
|
mount /dev/sda1 /mnt/udisk/
|
|
fi
|
|
|
|
sleep 2
|
|
#start quectel-CM
|
|
./quectel-CM &
|
|
|
|
|