Hi Alvaro,

Am Mo den 30. September 2019 um 09:51 Uhr schrieb Alvaro Cornejo:

> The problem you describe looks like for any reason your modem is not able
> to pass the incoming messages to kannel.
> 
> What I did in the past is configure kannel to automatically look for
> messages in modem storage. I guess you are only using CNMI command. This
> command tells the modem to pass messages to kannel. however. if the message
> got stuck in the memory, CNMI command will not check for it. You need to
> tell kannel to look periodically into the memory for the messages and free
> the messages memory. If this memory gets full, the modem will reject any
> other incoming message.

Meanwhile i believe this problem occurs if a message is received while
another message is sent. After that no more messages are received until
i reset the modem.

For example i found the following entries in kannel.log:

2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: TP-Validity-Period: 
24.0 hours
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: --> AT+CMGS=76^M
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- >
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: send command status: 1
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: --> [pdu data snipped]
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: --> ^Z

Here the modem should answer with ">" and "+CMGS: 20" and "OK", but
instead a messages comes in:

2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- +CMT: ,68
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- [pdu data snipped]
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: received message from 
SMSC: +491760000443
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: Alphanumeric sender 
<...>
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: User data length read 
as (54)
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: Udh decoding done 
len=54 udhi=0 udhlen=0 udh=''
2019-09-17 09:07:23 [17126] [6] DEBUG: AT2[/dev/ttyS1]: --> AT+CNMA^M
2019-09-17 09:07:23 [17126] [9] DEBUG: send_msg: sending msg to box: <127.0.0.1>
2019-09-17 09:07:23 [17126] [9] DEBUG: boxc_sender: sent message to <127.0.0.1>
2019-09-17 09:07:23 [17126] [8] DEBUG: boxc_receiver: got ack

Here the modem should answer with OK but this OK never appears, instead
the ">" and "+CMGS: 20" and "OK" from the sending above appear:

2019-09-17 09:07:25 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- >
2019-09-17 09:07:25 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- +CMGS: 20
2019-09-17 09:07:25 [17126] [6] DEBUG: AT2[/dev/ttyS1]: <-- OK
2019-09-17 09:07:38 [17126] [8] DEBUG: boxc_receiver: heartbeat with load value 
0 received
2019-09-17 09:07:44 [17126] [6] DEBUG: AT2[/dev/ttyS1]: send command status: -1
2019-09-17 09:07:44 [17126] [7] DEBUG: sms_router: handling message 
(0x7f5684001880 vs 0x7f5684001880)
2019-09-17 09:07:44 [17126] [7] DEBUG: re-queing SMS not-yet-to-be resent

So the modem has delivered the message to kannel, but perhaps didn't delete it
from its memory, or didn't aknowledge to the provider that it has received the
message?

And isn't this also a bug in kannel, that it does not recognize that the
message has been sent?

> Note that his work around is not 100% effective, but should largely reduce
> the times your modem gets locked for IM.
> 
> The commands you need to add to your config are:
> 
> On your SMSC-AT group:
> sim-buffering = true
> 
> AND on your MODEM group:
> message-storage = SM or ME. You should test which work best with your modem.
> 
> Hope this helps,

I'll try this tomorrow, thanks for your help!

Georg

Reply via email to