Dlink DSL-2750U telnet interface



I use a 3g usb dongle as a backup connection on the router. The 3g kicks in when the BSNL broadband has died. I would like to limit my connections when the 3g interface is being used. The idea is to use a script to find out when 3g is being used and then act accordingly.

Unfortunately, i havent been able to figure out the 3g status from command line. The following is what the modem provides.
Connected to
Escape character is '^]'.

  Authenticate Success!

  Input "?" to get the help information,
  Input "cm xxx" to change you command mode to xxx,
  Input CTRL+C to interrupt the command input
  Now list the command word of all mode:

  3g                display the brand,design,firmware don...
  acl                acl: <conname(s)> <contype(s)> <port(...
  adsl             Display the table SNR or Bits per ton...
  cls  Clear screen
  cpuinfo  CPU usage
  ddns  Show or config the ddns module
  debug  Get or Set a Node,only for debug
  device  display the brand and model of proces...
  dhcpserver  Show or config or enable or disable t...
  dmz  Show or configure the DMZ
  exit  Logout from the system
  firmware  download image via network using TFTP...
  help  Help information of command line operate
  ifconfig  Show or configure the WAN interface
  ipt  Show or configure the IPT module  
  lan  Show or config or enabl or|disable th...
  mac  Show or config or enable or filter ma...
  meminfo  Memory usage
  modem  display the brand,model,firmware vers...
  natp  Show or config the natp(Port Forwardi...
  password  config the username and the password
  pmirror  pmirror vpi [vpival] vci[vcival] flag...
  reboot  reboot
  restore_defaults  load default factory config
  route  Show or config the route module inclu...
  save  save config
  save_and_exit  save config and exit
  save_and_reboot  save and reboot
  set  scroll  Set screen scroll mode: manual or aut...
  sh  go to shell platform
  wan  Show or config the wan connection
  wlan  Show or config or enable or disable t...
  wmac  Show or config or enable or filter wi...



To see the available commands, you just gotta type
3g ?
and hit enter.

You'll see the following output:

TBS>>3g ?

  display the brand,design,firmware dongle connect status, information of 3G...
    show dongstatus:    display the status of 3G dongle
    show connstatus:    display the status of 3G
    show attenuation:   display the attenuation of the 3G link
    show connmode:    display the connection mode and the 3G sub-connection
    show detail:  display the information of 3G.such as: APN,Auth,use,pwd,IMSI...

So you can run
3g show connstatus
to check the connection status.