keywords: ip pbx voip gateway gsm gateway

×

Notice

The forum is in read only mode.
× Questions about G400/G410 Cards.

New G400P and CUSD

12 years 10 months ago #7057 by Easy
We've just got new G400P with Quectel_M20 Revision: MTK 0828. All cards that we had before were Simcom. I have updated chan-extra and now have 2 problems:

1. For the moment I am unable to get CUSD from those new cards. For SImcom card I get:
S0*CLI> gsm send at 5 "ATDT*245#;"
S0*CLI>
+CUSD: 0,"004A0075007300750020006B006F007200740065006C006500730020007300610073006B006100690074006F00730020006C0069006B007500740069007300200036002E003900390020004C0074002E0020004B006F007200740065006C0065002000670061006C0069006F006A006100200069006B006900200032003000310031002E00300039002E00320036002E",15
OK

For Quectel I get:
S0*CLI> gsm send at 2 "ATDT*245#;"
S0*CLI>
OK


2. With the latest chan-extra version CUSD messge is in really strange format, as You see. As I was able to solve its unicode, and if You split the line by 4 chars and then search for unicode chars with such codes - it's possible to decode the message. But that's the problem - for our software to work we definitively need to get those messages in plain text. Anyways, I could still stick with the old chan-extra version if there would be a way to get those CUSD messages at all from those new cards...

BTW, SMS sending if finally fixed to have span number in asterisk's response, but debug messages and any responses for AT commands are still unclear - witch span sent those.
12 years 9 months ago #7068 by Joe.Yung
Hi,
Regarding to your last question, you might need to increase a span parameter in the following functions.

.../chan_extra-xxx/src/libgsmat/gsm.c

1. Find function `gsm_dump`(near line 477), then get the debug output line(near 499). Please modify them like this:

From:
gsm_message(gsm, "%s %s\n",(txrx) ? ">>" : "<<", buf);

To:
gsm_message(gsm, "span:%d%s %s\n", gsm->span, (txrx) ? ">>" : "<<", buf);

2: Another function `gsm_set_switchtype`,

From:
gsm_message(gsm, "\t\t<<< %d %s -- %s , %d\n", i, tmp, buf, len);


To:
gsm_message(gsm, "\t\tspan:%d<<< %d %s -- %s , %d\n", gsm->span, i, tmp, buf, len);

3. ../chan_extra-xxx/src/libgsmat/m20.c (M20 Module)

Function `m20_receive`

From:
gsm_message(gsm, "\t\t<<< %d %s -- %s , NULL\n", i, tmp, buf);
gsm_message(gsm, "\t\t<<< %d %s -- %s , %d\n", i, tmp, buf, len);


To:
gsm_message(gsm, "\t\tspan:%d<<< %d %s -- %s , NULL\n", gsm->span, i, tmp, buf);
gsm_message(gsm, "\t\tspan:%d<<< %d %s -- %s , %d\n", gsm->span, i, tmp, buf, len);


4. .../chan_extra-xxx/src/libgsmat/simcom.c (Simcom Module)

Function `simcom_receive`

From:
gsm_message(gsm, "\t\t<<< %d %s -- %s , NULL\n", i, tmp, buf);
gsm_message(gsm, "\t\t<<< %d %s -- %s , %d\n", i, tmp, buf, len);



To:
gsm_message(gsm, "\t\tspan:<<< %d %s -- %s , NULL\n", gsm->span, i, tmp, buf);
gsm_message(gsm, "\t\tspan:<<< %d %s -- %s , %d\n", gsm->span, i, tmp, buf, len);


5. .../chan_extra-xxx/src/libgsmat/sim900.c (sim900 Module)

Function `sim900_receive`

From:
gsm_message(gsm, "\t\t<<< %d %s -- %s , NULL\n", i, tmp, buf);
gsm_message(gsm, "\t\t<<< %d %s -- %s , %d\n", i, tmp, buf, len);



To:
gsm_message(gsm, "\t\tspan:%d<<< %d %s -- %s , NULL\n", gsm->span, i, tmp, buf);
gsm_message(gsm, "\t\tspan:%d<<< %d %s -- %s , %d\n", gsm->span, i, tmp, buf, len);


After modification, you have to recompile it.

With regard to the first question, since they are different modules, the AT commands between them are not same. We will be trying to solve it.

Time to create page: 0.028 seconds
Powered by Kunena Forum