summaryrefslogtreecommitdiff
path: root/include/gsmd
diff options
context:
space:
mode:
authorerin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3>2008-02-21 05:16:15 +0000
committererin_yueh <erin_yueh@99fdad57-331a-0410-800a-d7fa5415bdb3>2008-02-21 05:16:15 +0000
commit29a2f6a3b46afb00052a24b05232630acad3af70 (patch)
tree181b89e02491f52e5d375fa277521cd76382e2f3 /include/gsmd
parent20adbe01bb4d7490436d0294de37b6c12624143b (diff)
gsmd: get battery status (Sudharshan S)
git-svn-id: http://svn.openmoko.org/trunk/src/target/gsm@4091 99fdad57-331a-0410-800a-d7fa5415bdb3
Diffstat (limited to 'include/gsmd')
-rw-r--r--include/gsmd/usock.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/gsmd/usock.h b/include/gsmd/usock.h
index 4263cad..7df22b2 100644
--- a/include/gsmd/usock.h
+++ b/include/gsmd/usock.h
@@ -139,6 +139,7 @@ enum gsmd_msg_phone {
GSMD_PHONE_GET_MODEL = 5,
GSMD_PHONE_GET_REVISION = 6,
GSMD_PHONE_GET_SERIAL = 7,
+ GSMD_PHONE_GET_BATTERY = 8,
};
enum gsmd_msg_modem {
@@ -371,6 +372,14 @@ enum gsmd_toa_reserved {
/* Length from 3GPP TS 04.08, Clause 10.5.4.7 */
+/* battery connection status from 3GPP TS 07.07 subclause 8.4 */
+enum gsmd_bat_conn_status {
+ GSMD_BAT_NORMAL = 0,
+ GSMD_BAT_NOT_POWERED = 1,
+ GSMD_BAT_NO_BAT = 2,
+ GSMD_BAT_POWER_FAULT = 3,
+};
+
#define GSMD_ADDR_MAXLEN 32
struct gsmd_addr {
u_int8_t type;
@@ -392,6 +401,11 @@ struct gsmd_voicemail {
struct gsmd_addr addr;
} __attribute__ ((packed));
+struct gsmd_battery_charge {
+ enum gsmd_bat_conn_status bcs;
+ u_int8_t bcl;
+} __attribute__ ((packed));
+
#define GSMD_ALPHA_MAXLEN 20
/* call status from 3GPP TS 07.07 clause 07.17 */
personal git repositories of Harald Welte. Your mileage may vary