More a less a note to self, if you're using a Vodafone TopUp and Go dongle on Linux, you'll quickly find there's no nice way to check your remaining credit. On Windows, you can use the button so labelled in the Vodafone connect software. On Linux, that's not really an option!
The answer is to pop open your trusty copy of minicom so proceed thusly:
minicom -s
In the resulting settings menu, change the serial port configuration so that your device is set up. The most likely choice is /dev/ttyUSB0 or /dev/ttyUSB0 rather than /dev/ttyS8 or whatever the default on your system is. Then go to 'exit' in the menu, which should take you into minicom.
What we do now is to simulate pressing that button, so, paste in (so that it happens quickly), and follow with Enter:
AT+CUSD=1,"*&1345;",15
You may have to have a few goes. What you get back should look like this:
+CUSD: 0,"#14.66.",0
Which is your dongle's way of saying £14.66 remaining.
I don't know how up-to-date this figure is, and for the record, I think £15/GB is extortionate (I'm paying £15 for 5GB for my own 3 dongle with a rolling one-month contract by Direct Debit).
This will only work for Vodafone dongles (and TopUp and Go mobiles, I suppose if you've hooked yours up by USB). The approach might work for other setups, though.
Friday, August 26. 2011 at 09:24 (Link) (Reply)
How did you determine that the command was AT+CUSD=1,"*&1345;",15 - when I issue this I just get OK,
Do you need to switch to a specific mode first?
Or were you able to sniff the command somehow?
Thanks David