diff options
author | erin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3> | 2008-03-06 09:35:12 +0000 |
---|---|---|
committer | erin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3> | 2008-03-06 09:35:12 +0000 |
commit | 636e8ecfdf47c6441975e41ed3f39dace55485c6 (patch) | |
tree | af38a8465ff88f7ffef39727b40935d1cc5d704f /src/util | |
parent | dc73a4a864610c3f9d5a175d30f9a168e3dc88fd (diff) |
gsmd: Query Antenna Status (Erin Yueh)
git-svn-id: http://svn.openmoko.org/trunk/src/target/gsm@4174 99fdad57-331a-0410-800a-d7fa5415bdb3
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/shell.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/util/shell.c b/src/util/shell.c index 85aa902..b0d5b41 100644 --- a/src/util/shell.c +++ b/src/util/shell.c @@ -425,6 +425,9 @@ static int phone_msghandler(struct lgsm_handle *lh, struct gsmd_msg_hdr *gmh) else printf("Modem down\n"); break; + case GSMD_PHONE_POWER_STATUS: + printf("Antenna Status: %s\n", payload); + break; case GSMD_PHONE_GET_BATTERY: printf("<BCS>: %d <BCL>: %d \n", bc->bcs, bc->bcl); break; @@ -546,6 +549,7 @@ static void shell_help(void) "\tH\tHangup call\n" "\tO\tAntenna Power On\n" "\to\tAntenna Power Off\n" + "\tgos\tGet Antenna Status\n" "\tV\tVibrator Enable (CVIB=1)\n" "\tv\tVibrator Disable (CVIB=0)\n" "\tM\tModem Power On\n" @@ -680,6 +684,9 @@ int shell_main(struct lgsm_handle *lgsmh, int sync) } else if (!strcmp(buf, "o")) { printf("Power-Off\n"); lgsm_phone_power(lgsmh, 0); + } else if (!strcmp(buf, "gos")) { + printf("Get Antenna status\n"); + lgsm_get_power_status(lgsmh, 0); } else if (!strcmp(buf, "V")) { printf("Vibrator-Enable\n"); lgsm_phone_vibrator(lgsmh, 1); |