huawei: implement ussd encoding/decoding
Huawei wants the USSD as packed GSM.
This commit is contained in:
committed by
Dan Williams
parent
b82cec8c7e
commit
70715c1c12
@@ -4820,9 +4820,9 @@ ussd_encode (MMModemGsmUssd *modem, const char* command, guint *scheme)
|
||||
if (!success)
|
||||
goto out;
|
||||
|
||||
*scheme = MM_MODEM_GSM_USSD_SCHEME_7BIT;
|
||||
/* convert to hex representation */
|
||||
hex = utils_bin2hexstr (ussd_command->data, ussd_command->len);
|
||||
*scheme = 15;
|
||||
|
||||
out:
|
||||
g_byte_array_free (ussd_command, TRUE);
|
||||
|
||||
@@ -80,6 +80,10 @@ void mm_modem_gsm_ussd_cancel (MMModemGsmUssd *self,
|
||||
MMModemFn callback,
|
||||
gpointer user_data);
|
||||
|
||||
/* CBS data coding scheme - 3GPP TS 23.038 */
|
||||
#define MM_MODEM_GSM_USSD_SCHEME_7BIT 0b00001111;
|
||||
#define MM_MODEM_GSM_USSD_SCHEME_UCS2 0b01001000;
|
||||
|
||||
char *mm_modem_gsm_ussd_encode (MMModemGsmUssd *self,
|
||||
const char* command,
|
||||
guint *scheme);
|
||||
|
||||
Reference in New Issue
Block a user