diff options
-rw-r--r-- | include/gprs.h | 6 | ||||
-rw-r--r-- | samsung-ipc/gprs.c | 12 |
2 files changed, 18 insertions, 0 deletions
diff --git a/include/gprs.h b/include/gprs.h index 0c96ff1..600ad2e 100644 --- a/include/gprs.h +++ b/include/gprs.h @@ -30,6 +30,7 @@ #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 @@ -91,6 +92,11 @@ struct ipc_gprs_current_session_data_counter { unsigned char unk[9]; }; +struct ipc_gprs_port_list { + unsigned char unk[804]; +}; + +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); diff --git a/samsung-ipc/gprs.c b/samsung-ipc/gprs.c index 0366712..c9edf7b 100644 --- a/samsung-ipc/gprs.c +++ b/samsung-ipc/gprs.c @@ -23,6 +23,18 @@ #include <stdlib.h> #include <assert.h> +void ipc_gprs_port_list_setup(struct ipc_gprs_port_list *message) +{ + // FIXME: These are only known-to-work values used on most devices + unsigned char bytes[] = { + 0x02, 0x04, 0x16, 0x00, 0x17, 0x00, 0x87, 0x00, 0xBD, 0x01 + }; + + memset(message->unk, 0, sizeof(message->unk)); + memcpy(message->unk, bytes, sizeof(bytes)); + +} + void ipc_gprs_define_pdp_context_setup(struct ipc_gprs_define_pdp_context *message, char *apn) { assert(message != NULL); |