Re: catenate the sms
Yury Mikhienko <[email protected]>
| Newsgroups | gmane.comp.mobile.kannel.devel |
|---|---|
| Organization | Mobicom-Kavkaz |
| Message-ID | <[email protected]> |
On Wed, 23 Apr 2003 15:39:23 +0200 Andreas Fink <[email protected]> wrote: > > On Mittwoch, April 23, 2003, at 03:33 Uhr, Yury Mikhienko wrote: > > > On Wed, 23 Apr 2003 15:19:32 +0200 > > Andreas Fink <[email protected]> wrote: > > > >> > >> On Mittwoch, April 23, 2003, at 03:11 Uhr, Yury Mikhienko wrote: > >>>>> > >>>> > >>>> no. You should do this in your application. > >>>> > >>> > >>> Of course, but can I send the unique sms-id (in splitting parts) to > >>> my > >>> application? > >>> > >> > >> The unique sms-id is not that unique as you might think. > >> The splitting header is part of the UDH and includes one byte. So the > >> uniqueness is a value between 0 and 255. You can make it more unique > >> by > >> combining it with the originator's phone number of course. > >> > >> > > > > But in current version of smsc_smpp.c UDH and message is spliting, and > > I did not see the way of send pure UDH into my application :(( > > This is for OUTGOING sms and has nothing to do for INCOMING sms. > For incoming SMS, just parse the UDH you receive. > This is not in any way unique to SMPP. Splitting on outgoing is done in > smsbox, not on SMSC driver level. > But I see in pdu_to_msg function (smsc_smpp.c) the following: ... if (pdu->u.deliver_sm.esm_class & ESM_CLASS_SUBMIT_UDH_INDICATOR) { udh_offset = octstr_get_char(pdu->u.deliver_sm.short_message, 0) + 1; msg->sms.udhdata = octstr_copy(pdu->u.deliver_sm.short_message, 0, udh_offset); msg->sms.msgdata = octstr_copy(pdu->u.deliver_sm.short_message, udh_offset, octstr_len(pdu->u.deliver_sm.short_message) - udh_offset); octstr_destroy(pdu->u.deliver_sm.short_message); msg->sms.coding = DC_8BIT; } else { msg->sms.msgdata = pdu->u.deliver_sm.short_message; } pdu->u.deliver_sm.short_message = NULL; ... this is work for INCOMING sms only (in my opinion) -- Best regards, Yury Mikhienko. IT engineer, ZAO "Mobicom-Kavkaz"