Some SMS API suggestions for ModemManager
- From: "Pablo Martí Gamboa" <pmarti warp es>
- To: networkmanager-list gnome org, roberto majadas gmail com
- Subject: Some SMS API suggestions for ModemManager
- Date: Tue, 20 Jan 2009 17:08:14 +0100
Hi all,
I've got a couple of suggestions for the MM API regarding SMS:
- org.freedesktop.ModemManager.Modem.Gsm.Sms.Send/Save:
* Change in_signature from 'ss', to 'a{sv}': The current API, albeit simple, is not powerful enough for some scenarios. You cannot specify SMSC, validity, message class, etc. It would keep two mandatory keys: 'number', 'text', and the following three would be optional: 'smsc', 'validity' and 'class'. This of course can be extended in the future.
* Change out_signature from 'u' to 'au': The current API assumes that is dealing with single part messages, but when you send/save a multipart one, you get n indexes if the SMS has been splitted into n parts.
- org.freedesktop.ModemManager.Modem.Gsm.Sms.List:
* Change out_signature from 'a(ussd)' to 'aa{sv}': The current signature suffers from the same problems than the in_signature in Sms.Send/Save. There's no way to obtain the smsc, validity, class, etc. Furthermore, a stored SMS in the SIM does not have a timestamp encoded in the pdu, so the 'd' from 'a(ussd)' wouldn't be necessary. One last thing is that the SIM orders messages into four categories:
- 0: Unread messages
- 1: Read messages
- 2: Unsent stored messages
- 3: Sent stored messages
Supporting this is mandatory for any application that pretends to provide a decent SMS experience. This field is commonly referred as 'stat'.
This dictionary then would have the following mandatory keys:
* 'index' (u)
* 'number' (s)
* 'text' (s)
* 'stat' (u)
And the following keys would be optional:
* 'class' (u)
* 'validity' (d)
* 'timestamp' (d)
Accordingly, the out_signature of Sms.Get should be changed to 'a{sv}'.
Any thoughts?
Regards,
Pablo
--
Pablo Martí
http://www.linkedin.com/in/pmarti ||
http://www.warp.es
python -c "print '706d6172746940776172702e6573'.decode('hex')"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]