diff options
author | Paul Kocialkowski <contact@paulk.fr> | 2012-07-08 00:35:04 +0200 |
---|---|---|
committer | Paul Kocialkowski <contact@paulk.fr> | 2012-07-08 00:35:04 +0200 |
commit | dadca553b13324a599c98ca2da98aad25e47d1d5 (patch) | |
tree | 295e9b91ae9da58e6226a32cb128f77a0172430e /include | |
parent | 7090d361f77842818b65f014b3731fb1445362d9 (diff) | |
download | external_libsamsung-ipc-dadca553b13324a599c98ca2da98aad25e47d1d5.zip external_libsamsung-ipc-dadca553b13324a599c98ca2da98aad25e47d1d5.tar.gz external_libsamsung-ipc-dadca553b13324a599c98ca2da98aad25e47d1d5.tar.bz2 |
GPRS: added and completed structures, defines and reworked functions accordingly
Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
Diffstat (limited to 'include')
-rw-r--r-- | include/gprs.h | 73 |
1 files changed, 49 insertions, 24 deletions
diff --git a/include/gprs.h b/include/gprs.h index 600ad2e..1f3f99a 100644 --- a/include/gprs.h +++ b/include/gprs.h @@ -30,7 +30,6 @@ #define IPC_GPRS_MS_CLASS 0x0D07 #define IPC_GPRS_3G_QUAL_SERVICE_PROFILE 0x0D08 #define IPC_GPRS_IP_CONFIGURATION 0x0D09 -#define IPC_GPRS_PORT_LIST 0x0D11 #define IPC_GPRS_DEFINE_SEC_PDP_CONTEXT 0x0D0A #define IPC_GPRS_TFT 0x0D0B #define IPC_GPRS_HSDPA_STATUS 0x0D0C @@ -38,20 +37,54 @@ #define IPC_GPRS_DATA_DORMANT 0x0D0E #define IPC_GPRS_DUN_PIN_CTRL 0x0D0F #define IPC_GPRS_CALL_STATUS 0x0D10 +#define IPC_GPRS_PORT_LIST 0x0D11 -#define IPC_GPRS_CALL_STATUS_TYPE_ON 0x0 -#define IPC_GPRS_CALL_STATUS_TYPE_OFF 0x3 +#define IPC_GPRS_STATE_NOT_ENABLED 0x00 +#define IPC_GPRS_STATE_ENABLED 0x01 +#define IPC_GPRS_STATE_DISABLED 0x03 -#define IPC_GPRS_ERROR_UNAVAILABLE 0x94 -#define IPC_GPRS_ERROR_NOT_SUBSCRIBED 0x0B +#define IPC_GPRS_FAIL_INSUFFICIENT_RESOURCES 0x0004 +#define IPC_GPRS_FAIL_MISSING_UKNOWN_APN 0x0005 +#define IPC_GPRS_FAIL_UNKNOWN_PDP_ADDRESS_TYPE 0x0006 +#define IPC_GPRS_FAIL_USER_AUTHENTICATION 0x0007 +#define IPC_GPRS_FAIL_ACTIVATION_REJECT_GGSN 0x0008 +#define IPC_GPRS_FAIL_ACTIVATION_REJECT_UNSPECIFIED 0x0009 +#define IPC_GPRS_FAIL_SERVICE_OPTION_NOT_SUPPORTED 0x000A +#define IPC_GPRS_FAIL_SERVICE_OPTION_NOT_SUBSCRIBED 0x000B +#define IPC_GPRS_FAIL_SERVICE_OPTION_OUT_OF_ORDER 0x000C +#define IPC_GPRS_FAIL_NSAPI_IN_USE 0x000D + +#define IPC_GPRS_PDP_CONTEXT_GET_DESC_COUNT 3 struct ipc_gprs_define_pdp_context { - unsigned char unk0[3]; + unsigned char enable; + unsigned char cid; + unsigned char unk; unsigned char apn[124]; }; +struct ipc_gprs_pdp_context_set { + unsigned char enable; + unsigned char cid; + unsigned char unk0[4]; + unsigned char username[32]; + unsigned char password[32]; + unsigned char unk1[32]; + unsigned char unk2; +}; + +struct ipc_gprs_pdp_context_get_desc { + unsigned char cid; + unsigned char state; +}; + +struct ipc_gprs_pdp_context_get { + unsigned char unk; + struct ipc_gprs_pdp_context_get_desc desc[IPC_GPRS_PDP_CONTEXT_GET_DESC_COUNT]; +}; + struct ipc_gprs_ip_configuration { - unsigned char unk0; + unsigned char cid; unsigned char field_flag; unsigned char unk1; unsigned char ip[4]; @@ -62,34 +95,24 @@ struct ipc_gprs_ip_configuration { unsigned char unk2[4]; }; -struct ipc_gprs_ip_configuration_response { - unsigned char unk0[376]; -}; - struct ipc_gprs_call_status { unsigned char cid; - unsigned char state; // IPC_GPRS_CALL_STATUS_TYPE_... - unsigned short reason; + unsigned char state; + unsigned short fail_cause; }; struct ipc_gprs_hsdpa_status { unsigned char unk; }; -struct ipc_gprs_pdp_context { - unsigned char unk0[6]; - unsigned char username[32]; - unsigned char password[32]; - unsigned char unk1[32]; - unsigned char unk2; -}; - struct ipc_gprs_ps { unsigned char unk[2]; }; struct ipc_gprs_current_session_data_counter { - unsigned char unk[9]; + unsigned char cid; + unsigned int rx_count; + unsigned int tx_count; }; struct ipc_gprs_port_list { @@ -97,8 +120,10 @@ struct ipc_gprs_port_list { }; void ipc_gprs_port_list_setup(struct ipc_gprs_port_list *message); -void ipc_gprs_pdp_context_setup(struct ipc_gprs_pdp_context *message, int activate, char *username, char *password); -void ipc_gprs_define_pdp_context_setup(struct ipc_gprs_define_pdp_context *message, char *apn); +void ipc_gprs_pdp_context_setup(struct ipc_gprs_pdp_context_set *message, + unsigned char cid, int enable, char *username, char *password); +void ipc_gprs_define_pdp_context_setup(struct ipc_gprs_define_pdp_context *message, + unsigned char cid, int enable, char *apn); #endif |