From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: Unable to decode PDU for SMS-STATUS-REPORT
Date: Fri, 22 Jun 2012 03:28:55 -0500 [thread overview]
Message-ID: <4FE42CC7.5050209@gmail.com> (raw)
In-Reply-To: <d075607b731e301c6ab7b10bb99a5774@toulouse.viveris.com>
[-- Attachment #1: Type: text/plain, Size: 1510 bytes --]
Hi Audric,
On 06/25/2012 11:10 AM, Audric Schiltknecht wrote:
> Hi guys.
>
> I'm having troubles with delivery reports.
>
> When I send a message with the property "UseDeliveryReports" set to "true",
> I can get the delivery report from the GSM modem, but ofono is unable to
> decode it:
>
> ofonod[677]: SMS: < \r\n+CDS:
> 32\r\n07913386094000F006DB0A810011223344216052714081802160527140228000\r\n
> ofonod[677]: drivers/atmodem/sms.c:at_cds_notify() Got new Status-Report
> PDU via CDS:
> 07913386094000F006DB0A810011223344216052714081802160527140228000, 32
> ofonod[677]: src/sms.c:ofono_sms_status_notify() len 32 tpdu len 32
> ofonod[677]: Unable to decode PDU
>
> The PDU is valid, since I can decode it using some online tool.
>
> It seems that sms_decode does not correctly handle the SMSCC part
> (913386094000F0),
> and tries to decode it as the sender address, which obviously fails.
>
Likely it is because your modem is being stupid. 3GPP 27.005 states:
<length> integer type value indicating in the text mode (+CMGF=1) the
length of the message body <data> > (or <cdata>) in characters; or in
PDU mode (+CMGF=0), the length of the actual TP data unit in octets
(i.e. the RP layer SMSC address octets are not counted in the length)
So in the case above it should be reporting the length of the payload,
not the length of the entire hex string.
See if the PDU is decoded successfully by setting tpdu_len to the
appropriate value.
Regards,
-Denis
next prev parent reply other threads:[~2012-06-22 8:28 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-25 16:10 Unable to decode PDU for SMS-STATUS-REPORT Audric Schiltknecht
2012-06-22 8:28 ` Denis Kenzior [this message]
2012-06-26 7:18 ` Audric Schiltknecht
2012-06-25 16:20 ` Audric Schiltknecht
2012-06-26 9:14 ` Philippe Nunes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4FE42CC7.5050209@gmail.com \
--to=denkenz@gmail.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.