diff --git a/platform/cervantes/koreader-standalone.sh b/platform/cervantes/koreader-standalone.sh index 21925085b..bca4a862a 100755 --- a/platform/cervantes/koreader-standalone.sh +++ b/platform/cervantes/koreader-standalone.sh @@ -33,8 +33,11 @@ if [ -b /dev/mmcblk1p1 ]; then mount /dev/mmcblk1p1 /mnt/sd fi -# remove wireless module since it wastes battery. -if lsmod | grep -q 8189fs; then +# stop connman daemon, KOReader will use wpa_supplicant directly. +[ -x /etc/init.d/connman ] && /etc/init.d/connman stop + +# for Cervantes 4 unload realtek module. +if [ "$PCB_ID" -eq 68 ] && lsmod | grep -q 8189fs; then modprobe -r 8189fs fi diff --git a/platform/cervantes/koreader.sh b/platform/cervantes/koreader.sh index 0ec5a8e12..6308dfe08 100755 --- a/platform/cervantes/koreader.sh +++ b/platform/cervantes/koreader.sh @@ -76,6 +76,7 @@ fi if [ "${STANDALONE}" != "true" ]; then stopapp.sh >/dev/null 2>&1 + [ -x /etc/init.d/connman ] && /etc/init.d/connman stop fi RETURN_VALUE=85 @@ -85,5 +86,6 @@ while [ "${RETURN_VALUE}" -eq 85 ]; do done if [ "${STANDALONE}" != "true" ]; then + [ -x /etc/init.d/connman ] && /etc/init.d/connman start restart.sh >/dev/null 2>&1 fi