提交 aa78fa77 authored 作者: Giovanni Maruzzelli's avatar Giovanni Maruzzelli

gsmopen: continue AT control with tcblib, most of the AT timeouts are now 1/10th…

gsmopen: continue AT control with tcblib, most of the AT timeouts are now 1/10th of sec, eg: 100millisec
上级 94ca0be2
...@@ -585,8 +585,8 @@ int gsmopen_serial_sync_AT(private_t * tech_pvt); ...@@ -585,8 +585,8 @@ int gsmopen_serial_sync_AT(private_t * tech_pvt);
int gsmopen_serial_config(private_t * tech_pvt); int gsmopen_serial_config(private_t * tech_pvt);
int gsmopen_serial_config_AT(private_t * tech_pvt); int gsmopen_serial_config_AT(private_t * tech_pvt);
#define gsmopen_serial_write_AT_expect(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 1, 2) #define gsmopen_serial_write_AT_expect(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 1, 0)
#define gsmopen_serial_write_AT_expect_noexpcr(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 0, 2) #define gsmopen_serial_write_AT_expect_noexpcr(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 0, 0)
#define gsmopen_serial_write_AT_expect_noexpcr_tout(P, D, S, T) gsmopen_serial_write_AT_expect1(P, D, S, 0, T) #define gsmopen_serial_write_AT_expect_noexpcr_tout(P, D, S, T) gsmopen_serial_write_AT_expect1(P, D, S, 0, T)
// 20.5 sec timeout, used for querying the SIM and sending SMSs // 20.5 sec timeout, used for querying the SIM and sending SMSs
#define gsmopen_serial_write_AT_expect_longtime(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 1, 20) #define gsmopen_serial_write_AT_expect_longtime(P, D, S) gsmopen_serial_write_AT_expect1(P, D, S, 1, 20)
......
...@@ -1994,7 +1994,7 @@ int gsmopen_serial_write_AT_expect1(private_t * tech_pvt, const char *data, cons ...@@ -1994,7 +1994,7 @@ int gsmopen_serial_write_AT_expect1(private_t * tech_pvt, const char *data, cons
return -1; return -1;
} }
at_result = gsmopen_serial_read_AT(tech_pvt, 1, 500000, seconds, expected_string, expect_crlf); // 20.5 sec timeout, used for querying the SIM and sending SMSs at_result = gsmopen_serial_read_AT(tech_pvt, 1, 100000, seconds, expected_string, expect_crlf); // minimum 1/10th sec timeout
UNLOCKA(tech_pvt->controldev_lock); UNLOCKA(tech_pvt->controldev_lock);
POPPA_UNLOCKA(tech_pvt->controldev_lock); POPPA_UNLOCKA(tech_pvt->controldev_lock);
...@@ -2011,7 +2011,8 @@ int gsmopen_serial_AT_expect(private_t * tech_pvt, const char *expected_string, ...@@ -2011,7 +2011,8 @@ int gsmopen_serial_AT_expect(private_t * tech_pvt, const char *expected_string,
if (option_debug > 1) if (option_debug > 1)
DEBUGA_GSMOPEN("expecting: %s\n", GSMOPEN_P_LOG, expected_string); DEBUGA_GSMOPEN("expecting: %s\n", GSMOPEN_P_LOG, expected_string);
at_result = gsmopen_serial_read_AT(tech_pvt, 1, 500000, seconds, expected_string, expect_crlf); // 20.5 sec timeout, used for querying the SIM and sending SMSs //cicopet at_result = gsmopen_serial_read_AT(tech_pvt, 1, 500000, seconds, expected_string, expect_crlf); // 20.5 sec timeout, used for querying the SIM and sending SMSs
at_result = gsmopen_serial_read_AT(tech_pvt, 1, 100000, seconds, expected_string, expect_crlf); // minimum 1/10th sec timeout
UNLOCKA(tech_pvt->controldev_lock); UNLOCKA(tech_pvt->controldev_lock);
POPPA_UNLOCKA(tech_pvt->controldev_lock); POPPA_UNLOCKA(tech_pvt->controldev_lock);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论