Thanks @alzhao on how to hard reset the modem.
For anyone that is interested on getting the 3G / 4G card to reset on its own when signal drops follow instructions below:
Put the script below in /sbin/restart3g and chmod +x /sbin/restart3g
#!/bin/sh
date >> /tmp/restart3g.log
echo 1 > /sys/class/leds/gl_mifi:usbpow/brightness
sleep 1
echo 0 > /sys/class/leds/gl_mifi:usbpow/brightness
To have OpenWRT run the script when the 3g-modem interface goes down put this script in /etc/hotplug.d/iface/99-3g and chmod +x /etc/hotplug.d/iface/99-3g
I have updated the script below for firmware v2.22
#!/bin/sh
[ “$ACTION” = “remove” ] && {
if [ “$INTERFACE” = “3g-modem” ]; then
/sbin/restart3g
fi
}
Every time the 3g-modem interface goes down it will run the restart3g script to reset the modem and reconnect to mobile network.
1 Like