List Info

Thread: the gsmd_alive timer ignores the interpreter_ready variable




the gsmd_alive timer ignores the interpreter_ready variable
country flaguser name
Germany
2007-06-03 09:18:09
Hi,

the latest gsmd sends the alive detector's ATE0 to the GSM
modem, even
if interpreter_ready == 0. The attached patch sees to it
that if
interpreter_ready is zero, gsmd_alive_start is only called
once the
"AT-Command Interpreter ready" message was seen.

regards
Philipp

Index: gsm/src/gsmd/atcmd.c
============================================================
=======
--- gsm.orig/src/gsmd/atcmd.c	2007-06-03 13:24:44.000000000
+0200
+++ gsm/src/gsmd/atcmd.c	2007-06-03 13:24:46.000000000
+0200
 -185,6
+185,7 
 	    !strcmp(buf, "AT-Command Interpreter
ready")) {
 		g->interpreter_ready = 1;
 		gsmd_initsettings(g);
+		gmsd_alive_start(g);
 		return 0;
 	}
 
Index: gsm/src/gsmd/gsmd.c
============================================================
=======
--- gsm.orig/src/gsmd/gsmd.c	2007-06-03 13:22:02.000000000
+0200
+++ gsm/src/gsmd/gsmd.c	2007-06-03 13:22:56.000000000 +0200
 -128,7
+128,7 
 	gsmd_timer_register(tmr);
 }
 
-static int gmsd_alive_start(struct gsmd *gsmd)
+int gmsd_alive_start(struct gsmd *gsmd)
 {
 	struct timeval tv;
 
 -478,10
+478,11 
 	/* select a vendor plugin */
 	gsmd_vendor_plugin_find(&g);
 
-	if (g.interpreter_ready)
+	if (g.interpreter_ready) {
 		gsmd_initsettings(&g);
 	
-	gmsd_alive_start(&g);
+		gmsd_alive_start(&g);
+	}
 
 	gsmd_opname_init(&g);
 



Re: the gsmd_alive timer ignores the interpreter_ready variable
user name
2007-07-31 02:03:50
On Sun, Jun 03, 2007 at 04:18:09PM +0200, Philipp Zabel
wrote:
> Hi,
> 
> the latest gsmd sends the alive detector's ATE0 to the
GSM modem, even
> if interpreter_ready == 0. The attached patch sees to
it that if
> interpreter_ready is zero, gsmd_alive_start is only
called once the
> "AT-Command Interpreter ready" message was
seen.

thanks, applied. (svn rev 2578)
-- 
- Harald Welte <laforgeopenmoko.org>          	
       http://openmoko.org/
============================================================
================
Software for the world's first truly open Free Software
mobile phone


[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )