Re: [PATCH] ModemManager: Add GetMsIsdn method to return the phone number
- From: Aleksander Morgado <aleksander lanedo com>
- To: "Andrew Bird (Sphere Systems)" <ajb spheresystems co uk>
- Cc: networkmanager-list gnome org
- Subject: Re: [PATCH] ModemManager: Add GetMsIsdn method to return the phone number
- Date: Mon, 23 Jan 2012 22:40:54 +0100
>>>>>>> I can look at doing that. What should we call it? I think MSISDN is
>>>>>>> a GSM term. How does GetPhoneNumber() sound?
>>>>>>
>>>>>> Hm, old message. Yes, that method sounds fine.
>>>>>
>>>>> Where did this end up?
>>>>>
>>>>> Also, AT+CNUM may report a list of numbers, not just one.
>>>>>
>>>>> For the 0.6 API I was going to add it as a "PhoneNumbers" property
>>>>> (signature 'as') in the Modem interface.
>>>>>
>>>>> Anyway, in my own tests, it really didn't report any number, as some
>>>>> others noticed. :-/
>>>>
>>>> Well IMHO if you are going to get the values from +CNUM, you should
>>>> also allow setting of it, would you agree? Essentially it's a list of
>>>> SIM contacts, other than that it having a dedicated AT command to
>>>> get/set as it's in a different phonebook, there's not really anything
>>>> special about it.
>>>
>>> Given that we have a "Contacts" interface in the 0.6 API, maybe we could
>>> handle own numbers, if retrievable, as any other number in the different
>>> available phonebooks.
>>
>> CDMA devices always have a command (either AT or QCDM/DIAG) to return
>> the MDN since it's stored in the phone and not on a SIM (unless you have
>> a RUIM of course, then it's on the RUIM I think). For the GSM devices,
>> it's often programmed as phonebook #0 but that's easy to change, delete,
>> or screw up. So I think there's value in exposing the current phone
>> number where we can get it, if we can't then we should probably leave it
>> blank.
>>
> That seems a reasonable approach to me as long as on GSM you don't return a
> result based on a query to +CNUM. The +CNUM approach to GetOwnNumber is flawed
> but if you really do wish to use it, I think you need to be able to read and
> write the values, so that if it's wrong you can at least correct the entry.
Being able to modify listed own numbers, at least in 3GPP modems, should
be doable when the new Contacts interface is implemented, by acting on
the "ON" storage, if supported.
Updating that value is IMO a rare use case so I wouldn't really
implement a specific SetOwnNumbers(), I would just rely on being able to
update the ON phonebook via the Contacts interface.
But wanting to read the value is probably not that rare use case, and
also not 3GPP or Contacts/Phonebook specific, so a "PhoneNumbers"
property in the Modem API could be helpful. This then could be done with
+CNUM or reading from the ON phonebook in the 3GPP case, or with other
AT/QCDM commands in CDMA.
--
Aleksander
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]