X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/6f48b8ea556c7da4ed75cb95571c02582771fae2..1d1240855a20a954a108e5692182e9234a1a7f9a:/package/comgt/files-netifd/3g.sh diff --git a/package/comgt/files-netifd/3g.sh b/package/comgt/files-netifd/3g.sh index cbf8bd1e6..b5da54c44 100644 --- a/package/comgt/files-netifd/3g.sh +++ b/package/comgt/files-netifd/3g.sh @@ -12,7 +12,7 @@ proto_3g_init_config() { proto_config_add_string "device" proto_config_add_string "apn" proto_config_add_string "service" - proto_config_add_int "pincode" + proto_config_add_string "pincode" } proto_3g_setup() { @@ -50,6 +50,8 @@ proto_3g_setup() { *) CODE=3;; esac export MODE="AT_OPSYS=${CODE}" + elif echo "$cardinfo" | grep -q "Sierra Wireless"; then + SIERRA=1 fi if [ -n "$pincode" ]; then @@ -60,6 +62,11 @@ proto_3g_setup() { } fi [ -n "$MODE" ] && gcom -d "$device" -s /etc/gcom/setmode.gcom + + # wait for carrier to avoid firmware stability bugs + [ -n "$SIERRA" ] && { + gcom -d "$device" -s /etc/gcom/getcarrier.gcom || return 1 + } ;; esac