diff options
author | erin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3> | 2008-01-18 09:15:33 +0000 |
---|---|---|
committer | erin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3> | 2008-01-18 09:15:33 +0000 |
commit | 07aca97d83c52de1a5e0189cb5f7351ebe40185a (patch) | |
tree | cdf3042dcfd3ad19d6f0c184c7284bb072dad663 /src/util | |
parent | 9b7916395e21e4efe3d0fc76adad30c3b1f169be (diff) |
gsmd: add 'lgsm_open_n_get' to retrieve the current country code (Sean Chiang)
git-svn-id: http://svn.openmoko.org/trunk/src/target/gsm@3876 99fdad57-331a-0410-800a-d7fa5415bdb3
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/shell.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/util/shell.c b/src/util/shell.c index f5f8fd3..e9aae1c 100644 --- a/src/util/shell.c +++ b/src/util/shell.c @@ -320,6 +320,7 @@ static int net_msghandler(struct lgsm_handle *lh, struct gsmd_msg_hdr *gmh) pending_responses --; break; case GSMD_NETWORK_OPER_GET: + case GSMD_NETWORK_OPER_N_GET: if (oper[0]) printf("Our current operator is %s\n", oper); else @@ -500,6 +501,7 @@ static void shell_help(void) "\tR\tRegister to given operator (R=number)\n" "\tU\tUnregister from netowrk\n" "\tP\tPrint current operator\n" + "\tN\tPrint current operator in numeric\n" "\tL\tList available operators\n" "\tQ\tRead signal quality\n" "\tS\tSleep (S[=second], default 5)\n" @@ -634,6 +636,10 @@ int shell_main(struct lgsm_handle *lgsmh, int sync) printf("Read current opername\n"); lgsm_oper_get(lgsmh); pending_responses ++; + } else if (!strcmp(buf, "N")) { + printf("Read current opername in numeric format\n"); + lgsm_oper_n_get(lgsmh); + pending_responses ++; } else if (!strcmp(buf, "L")) { printf("List operators\n"); lgsm_opers_get(lgsmh); |