EC200U: Http fails even when data call is connected

Hi All,

We need to make HTTP request every 1 hr from EC200U to cloud. It works fine for 5 to 6 hours. After that the HTTP request fails even though the the data call seems to be connected. The values for int evt, int evt_code in the http_event_cb callback are 0 (HTTP_EVENT_SESSION_ESTABLISH) and -7 (HTTP_ERR_SOCKE_CONNECT_FAIL). The connection log when http failed:

CCMS_LOG(“voice status: %d %d %d %d”, reg_info.voice_reg.state, reg_info.voice_reg.act, reg_info.voice_reg.cid, reg_info.voice_reg.lac);
CCMS_LOG(“data status: %d %d %d %d”, reg_info.data_reg.state, reg_info.data_reg.act, reg_info.data_reg.cid, reg_info.data_reg.lac);

voice status: 1 7 1498930 69
data status: 1 7 1498930 69

profile_idx: 1, ip_version: 3, v4.state: 1
v4.addr.ip: 25.200.184.167
info.v4.addr.pri_dns: 49.45.0.1

I also tried ql_stop_data_call and ql_start_data_call when http failed. Still it did not work. It works again after module is switched off and on.

Thanks,
Prakash

Hi
You can first check whether the server you are connecting to has settings. You can try to switch cfun 0/1 state when your connection fails.

Hi,

Thanks for the response.
Server is working fine.
We are using EC200U-CN. We use only API calls in our app. How do we send AT Commands?

Thanks,
Prakash

Hi Felix,

As you said, I sent AT+CFUN=0, AT+CFUN=1 and got new IP addr. But still http is failing. We are planning to call ql_power_reset. But this is not correct way. Please let us know if need to check anything else.

Thanks,
Prakash

At last I had to reset the device (after saving app state) whenever network failed.