ModemManager SMS Delivery State

Andrea Schäfer andrea.schaefer at puri.sm
Mon Dec 17 16:26:15 UTC 2018


Hi Aleksander,

Thanks a lot for the explanation and the link to the example.

Now everything is so much clearer :)


Andrea


On 12/17/2018 04:01 PM, Aleksander Morgado wrote:
> Hey Andrea,
> 
>>
>> I wrote a protocol plugin for libpurple, that interfaces with
>> ModemManager via DBUS. Sending and receiving SMS works fine so far, but
>> I'm struggling with getting the status for sent SMS.
>>
>> The SMS are created with 'delivery-report-request' = TRUE. Now I have
>> difficulties to find a way to pull the 'DeliveryState' when an SMS has
>> been sent.
>>
>> When I read the 'DeliveryState' property in the "Send" callback handler,
>> the value is always 256. But it should rather be 0 or 1 for successful
>> delivery.
>>
> 
> The DeliveryState property of a *sent* SMS will always be
> MM_SMS_DELIVERY_STATE_UNKNOWN (0x100).
> 
>> Apart from the exact DeliveryState, I wonder if the callback trigger
>> confirms a successful delivery to the SMSC already?
>>
> 
> No. When you send an SMS, the callback trigger confirms the SMS has
> been sent only (as reported by the modem)
> 
> The way it works is like this:
>  * You send an SMS with delivery-report-request=TRUE
>  * While you do that, the "message reference" of the sent SMS will be
> updated to the correct one.
>  * Once the SMS is received in the SMSC, the network will send you a new SMS.
>  * You receive a new SMS (pdu-type: status report) with a message
> reference matching the one of your sent SMS.
>  * The received SMS contains the information of the delivery in the
> DeliveryState property.
> 
> See some example of this flow here:
> https://sigquit.wordpress.com/2012/09/14/sms-goodies-in-modemmanager/
> 


More information about the ModemManager-devel mailing list