Discussion:
[Bitpim-devel] Re: Phone book conversion questions
Roger Binns
2003-11-03 23:55:05 UTC
Permalink
1. The Sanyo SCP-4900 can hold 7 phone numbers per name, up to one of
each of the following types "Home, Work, Mobile, Pager, Data, Fax, No
Label". In putting the data into Bitpim structures, should these types
be normalized to a bitpim standard? I am guessing these would be "home,
office, cell, pager, data, fax, none".
They are documented in
http://cvs.sourceforge.net/viewcvs.py/bitpim/bitpim/phonebook.py?view=markup

One change I think I am going to make is removing the number suffix.
This is because the list is ordered anyway, and so the second 'home'
is already implicitly 'home2'.
2. For the LGVX4400, phonize is called before writing a number to the
phone to remove all characters except digits, P, T, * and #. For the
4900, the allowed characters are digits, dash, H, T, * and #. H is a
hard pause and T a two second pause. Is H the same meaning as P?
Should I convert H's to P's when going to bitpim structures, and P back
to H when writing to the phone?
The 4400 will truncate the number written to it at the first non-acceptable
character. The UI on the phone then tries to put dashes back in when
displaying numbers (that was one of the fixes in the original firmware
releases). BitPim doesn't place any meaning on the numbers and other
characters in there.

It will be somewhat relevant when "importing" entries since it will have
to decide if two numbers each from a different source are the same. I
will do that by just stripping out all non-digits while doing the
comparison.
3. When writing a bitpim phonebook to a phone, it seems that two
conversion steps are done to put the data into a format suitable for the
specific phone. First the convertphonebooktophone method of the Profile
class is done, and then makeentry is done to put the data into the
structure defined in the protocol definition file. Can you explain why
these two steps are done, and which conversions belong in each place.
(for example, why is phonize done in makeentry and not
converphonebooktophone?)
All of the communication with the phone is done in a background thread.
You can't do any GUI operations from that thread. The purpose of the
first pass (convertphonebooktophone) is to do any preparations it
wants and then have the ability to do some gui operations.

On the 4400, it re-reads the wallpaper and ringtone index files.
It could also check there is enough space for all the entries
or similar things.

The second stage (savephonebook not makeentry) then actually
commits the data.

Roger
Stephen Wood
2003-11-04 23:55:26 UTC
Permalink
Post by Roger Binns
1. The Sanyo SCP-4900 can hold 7 phone numbers per name, up to one of
each of the following types "Home, Work, Mobile, Pager, Data, Fax, No
Label". In putting the data into Bitpim structures, should these types
be normalized to a bitpim standard? I am guessing these would be "home,
office, cell, pager, data, fax, none".
They are documented in
http://cvs.sourceforge.net/viewcvs.py/bitpim/bitpim/phonebook.py?view=markup
Since "data" is not in this list, should I convert Sanyo "data" numbers
to BitPim "none" numbers. If I ever use the Data field on my phone,
it's just going to hold some extra number for someone, not a modem
number.

Steve
Roger Binns
2003-11-05 00:22:05 UTC
Permalink
Post by Stephen Wood
Since "data" is not in this list, should I convert Sanyo "data" numbers
to BitPim "none" numbers. If I ever use the Data field on my phone,
it's just going to hold some extra number for someone, not a modem
number.
It seems like a valid type to me. Just add it as data. Other phones
that don't have that type will have to convert it to something
meaningful if they see it.

Roger

Loading...