<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>nrf9160 how to send sms it in packages if the content exceeds 160 characters</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/68623/nrf9160-how-to-send-sms-it-in-packages-if-the-content-exceeds-160-characters</link><description>At present, the SMS is sent normally. The format of nrf9160 is 7bit, and can send a maximum of 160 characters. However, how to send it in packages if the content exceeds 160 characters, and the at manual does not describe how to subpackage. I hope the</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 25 Nov 2020 11:26:05 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/68623/nrf9160-how-to-send-sms-it-in-packages-if-the-content-exceeds-160-characters" /><item><title>RE: nrf9160 how to send sms it in packages if the content exceeds 160 characters</title><link>https://devzone.nordicsemi.com/thread/281763?ContentTypeID=1</link><pubDate>Wed, 25 Nov 2020 11:26:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:cdd226a8-1ebd-424e-a3b8-d10f896806b7</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Modem does not have &amp;quot;direct&amp;quot; support to send these over lengthen SMS, so segmentation will not be done by automatically.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;So client must send so many AT commands as needed with each having one part of concatenated message (so f.ex. if total length would be 200 chars, there would need to use two AT commands where the first one can send 153 chars (with UDH of part 1 in the begin of data part and the second one then has the rest of char data, which means that TP-Data has UDH for part 2 + 47 chars content data).&lt;/p&gt;
&lt;p&gt;Client needs to construct by self a correctly decoded AT commands where SMS PDU data has these UDH (User data header) blocks for each concatenated message, like this smpp webpage also describes in that User Data Header section.&lt;/p&gt;
&lt;p&gt;Customer/client could take a look into 3GPP spec 23-040 that describes how to use User Data Header and how to use/make concatenation.&lt;/p&gt;
&lt;p&gt;Adding here for example one multipart/concatenated SMS message&amp;nbsp;(has 2 parts) decoded for AT commands (have bolded and used colors to separate some fields):&lt;/p&gt;
&lt;p&gt;AT+CMGS=154&lt;/p&gt;
&lt;p&gt;+00+7100*0c91180993569390*0000ffa0&lt;span style="color:rgba(76, 154, 255, 1);"&gt;050003010201&lt;/span&gt;6031d98c56b3dd7039584c36a3d56c375c0e1693cd6835db0d9783c564335acd76c3e56031d98c56b3dd7039584c36a3d56c375c0e1693cd6835db0d9783c564335acd76c3e56031d98c56b3dd7039584c36a3d56c375c0e1693cd6835db0d9783c564335acd76c3e56031d98c56b3dd7039584c36a3d56c375c0e1693cd6835db0d9783c564&lt;/p&gt;
&lt;p&gt;(After OK response then 2nd part)&lt;/p&gt;
&lt;p&gt;AT+CMGS=32&lt;/p&gt;
&lt;p&gt;+00+7100*0c91180993569390*0000ff14&lt;span style="color:rgba(76, 154, 255, 1);"&gt;050003010202&lt;/span&gt;66b49aed86cbc162b219ad06&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;And Decoded as below:&lt;/p&gt;
&lt;p&gt;SCA:&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;ins&gt;00&lt;/ins&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;(the first byte)&lt;/p&gt;
&lt;p&gt;PDU Type: 71 (UDHI is set, look for 3GPP spec)&lt;/p&gt;
&lt;p&gt;MR: 00&lt;/p&gt;
&lt;p&gt;DA:&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;b&gt;0c91180993569390&lt;/b&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;(destination address = recipient 819039653909, 0c = len, 91 = international type, then the actual number)&lt;/p&gt;
&lt;p&gt;TP-PID: 00&lt;/p&gt;
&lt;p&gt;TP-DCS: 00 (GSM-7)&lt;/p&gt;
&lt;p&gt;TP-VP: 0xFF (validity period of message)&lt;/p&gt;
&lt;p&gt;TP-UDL: 0x0a (160) and 0x14 (20)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Then starts the actual SMS TP-Data part -&amp;gt;&lt;/p&gt;
&lt;p&gt;User Data Header 1:&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color:rgba(76, 154, 255, 1);"&gt;050003+01+0201&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;User data Header 2:&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color:rgba(76, 154, 255, 1);"&gt;050003+01+0202&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="color:rgba(23, 43, 77, 1);"&gt;&amp;nbsp;And User data header data opened -&amp;gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;IEI: 00 (concatenated message indication, first byte)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;IEDL: 03 (3 bytes, next 2 bytes)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Reference Number of the concatenated message:&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;ins&gt;01&lt;/ins&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;(same for all in &amp;quot;one over lengthed SMS&amp;quot;)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Total parts of the concatenated message: 02&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Index of this part of the concatenated message: 01 and 02 (the last byte of UDH)&lt;/p&gt;
&lt;p&gt;&lt;span style="color:rgba(23, 43, 77, 1);"&gt;After UDH parts is then the actual message char data (need to take care use of correct padding like described in 3GPP spec).&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;SMS content / &amp;quot;char data&amp;quot; used here is just a dummy (166 bytes of total) decoded to 7 bit format:&lt;/p&gt;
&lt;p&gt;0123456789012345678901234567890123456789&lt;/p&gt;
&lt;p&gt;0123456789012345678901234567890123456789&lt;/p&gt;
&lt;p&gt;0123456789012345678901234567890123456789&lt;/p&gt;
&lt;p&gt;0123456789012345678901234567890123456789012345&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;With google can be found many pages explaining this same issue, like;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://techsofar.com/combining-sms-messages/" rel="nofollow noopener noreferrer" target="_blank"&gt;https://techsofar.com/combining-sms-messages/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://shekharbiradar.wordpress.com/send-and-receive-concatenated-sms-in-pdu-mode/" rel="nofollow noopener noreferrer" target="_blank"&gt;https://shekharbiradar.wordpress.com/send-and-receive-concatenated-sms-in-pdu-mode/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: nrf9160 how to send sms it in packages if the content exceeds 160 characters</title><link>https://devzone.nordicsemi.com/thread/281524?ContentTypeID=1</link><pubDate>Tue, 24 Nov 2020 11:48:07 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:faec7c23-cabf-407b-a3f3-4afab84dbc97</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
[quote user=""]At present, the SMS is sent normally. The format of nrf9160 is 7bit, and can send a maximum of 160 characters. However, how to send it in packages if the content exceeds 160 characters, and the at manual does not describe how to subpackage. I hope the original factory can help.[/quote]
&lt;p&gt;I am checking internally if we support segmentation and re-assembly of sms pdu, and I&amp;#39;ll get back to you with details soon.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Kind regards,&lt;/p&gt;
&lt;p&gt;Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>