summaryrefslogtreecommitdiff
path: root/include/types.h
diff options
context:
space:
mode:
authorAndrzej Zaborowski <andrew.zaborowski@intel.com>2009-10-12 23:35:59 +0200
committerDenis Kenzior <denkenz@gmail.com>2009-10-23 17:05:53 -0500
commitf43efa8a5f24f2aab71f829082cc02a272268986 (patch)
tree3947897237b13880d172e4aaa116cc5792d4b115 /include/types.h
parent0faa8b3c42533578b5b6ed4d3de0cb25ba24cb1d (diff)
downloadofono-f43efa8a5f24f2aab71f829082cc02a272268986.tar.gz
Add GPRS support
This commit implements the GPRS context setup and teardown according to doc/dataconnectionmanager-api.txt One issue with the AT implementation of the api is that "Powered" (a read-write property) can be set independently of "Attached" (read-only property) and remain set when "Attached" is clear. The semantics would be that the network doesn't have resources to let the modem attach, but the modem waits for the resources to become available and then attaches. On AT the modem is in this state only when executing +CGATT, so currently the code will rerun +CGATT as soon as the previous one returns with error, probably starving other commands. A possible workaround would be for "Powered" to flip back to False after the modem fails to attach once, or give up on having separate properties. Alternatively we could re-try to attach periodically but on one modem I've tried +CGATT fails after about 1 minute (that's the Calypso) and on another only about 0.5s (Nokia phones with AT emulation). When "Powered" is set and "RoamingAllowed" is clear and we manage to attach and find that we're roaming, ofono resets "Powered". We may want to catch the user trying to dial *99***1# which is the backwards compatibility quirk for old modems (same way ofono parses USSD strings).
Diffstat (limited to 'include/types.h')
-rw-r--r--include/types.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/include/types.h b/include/types.h
index 6a9681d0..44428fb1 100644
--- a/include/types.h
+++ b/include/types.h
@@ -91,6 +91,16 @@ struct ofono_call {
int clip_validity;
};
+struct ofono_data_context {
+ unsigned id;
+ int type;
+ int direction;
+ int active;
+ char *apn;
+ char *username;
+ char *password;
+};
+
#ifdef __cplusplus
}
#endif