unsigned int cmee_mode : 2;
bool clip : 1;
bool ccwa : 1;
+ bool ddr_active : 1;
};
struct indicator {
static void biev_cb(GAtServer *server, GAtServerRequestType type,
GAtResult *result, gpointer user_data)
{
+ struct ofono_emulator *em = user_data;
+
switch (type) {
case G_AT_SERVER_REQUEST_TYPE_SET:
{
if (g_at_result_iter_next_number(&iter, &hf_indicator) == FALSE)
goto fail;
- if (hf_indicator != 1)
+ if (hf_indicator != HFP_HF_INDICATOR_ENHANCED_SAFETY)
+ goto fail;
+
+ if (em->ddr_active == FALSE)
goto fail;
if (g_at_result_iter_next_number(&iter, &val) == FALSE)
em);
if (em->type == OFONO_EMULATOR_TYPE_HFP) {
+ em->ddr_active = true;
+
emulator_add_indicator(em, OFONO_EMULATOR_IND_SERVICE, 0, 1, 0,
FALSE);
emulator_add_indicator(em, OFONO_EMULATOR_IND_CALL, 0, 1, 0,
if (indicator != HFP_HF_INDICATOR_ENHANCED_SAFETY)
return;
+ em->ddr_active = active;
+
sprintf(buf, "+BIND: %d,%d", HFP_HF_INDICATOR_ENHANCED_SAFETY, active);
g_at_server_send_unsolicited(em->server, buf);
}