Hi Jeevaka, On 1 September 2010 17:33, Denis Kenzior <[email protected]> wrote: > On 09/01/2010 06:00 AM, Jeevaka Badrappan wrote: >> --- >> src/stkutil.h | 8 ++++++++ >> 1 files changed, 8 insertions(+), 0 deletions(-) >> >> diff --git a/src/stkutil.h b/src/stkutil.h >> index 44d167a..66d2e55 100644 >> --- a/src/stkutil.h >> +++ b/src/stkutil.h >> @@ -237,6 +237,7 @@ enum stk_result_type { >> STK_RESULT_TYPE_GO_BACK = 0x11, >> STK_RESULT_TYPE_NO_RESPONSE = 0x12, >> STK_RESULT_TYPE_HELP_REQUESTED = 0x13, >> + STK_RESULT_TYPE_USSD_OR_SS_USER_TERMINATION = 0x14, >> >> /* 0x20 to 0x2F are used to indicate that SIM should retry */ >> STK_RESULT_TYPE_TERMINAL_BUSY = 0x20, >> @@ -254,6 +255,7 @@ enum stk_result_type { >> STK_RESULT_TYPE_DATA_NOT_UNDERSTOOD = 0x32, >> STK_RESULT_TYPE_COMMAND_ID_UNKNOWN = 0x33, >> STK_RESULT_TYPE_MINIMUM_NOT_MET = 0x36, >> + STK_RESULT_TYPE_USSD_RETURN_ERROR = 0x37, >> STK_RESULT_TYPE_CALL_CONTROL_PERMANENT = 0x39, >> STK_RESULT_TYPE_BIP_ERROR = 0x3A, >> STK_RESULT_TYPE_ACCESS_TECHNOLOGY_ERROR = 0x3B, >> @@ -1445,6 +1447,11 @@ struct stk_response_run_at_command { >> const char *at_response; >> }; >> >> +struct stk_response_text_string { >> + unsigned char dcs; >> + const unsigned char *text; >> +}; >> + > > 3GPP 31.111 says that the terminal response to Send USSD should contain > a simple Text String. The DCS of the text string in STK is different > from DCS that is returned by USSD. Copying it directly from the USSD > DCS seems incorrect. Or is there something I'm missing?
On irc we figured that the best hint about what is expected to be returned is in the tests in 31.124. +CUSD returns sms-like DCS, while STK expects Cell Broadcast-like DCS and recommends using only the values 00, 04, 08, so there needs to be a translation from one to the other (perhaps in stk.c in the ussd callback). I think you'll also need a length field in this struct as the data can contain 0s. Best regards _______________________________________________ ofono mailing list [email protected] http://lists.ofono.org/listinfo/ofono
