Discussion:
[Bitpim-devel] Re: bitpim-cvs-checkins digest, Vol 1 #375 - 5 msgs
Stephen Wood
2004-12-14 05:30:48 UTC
Permalink
On Sun, 2004-12-12 at 16:58,
...
+ __switch_mode_cmd='\x44\x58\xf4\x7e'
Joe:

This is a little gem here. If I understand correctly, this puts the
phone back into modem mode without having to power cycle the phone. I
tried it with my phone and that seemed to be the case.

Also, if I understand correctly, you are using the file system to do
the phonebook now. Does this give advantages over using the AT
commands?

Stephen
d***@netzero.com
2004-12-14 13:23:22 UTC
Permalink
Stephen,
this puts the phone back into modem mode without having to power cycle the phone.
It works with my A650, was not sure if it'd work with other Samsung phones. It now appears to work with at least one more Samsung phone.
Does this give advantages over using the AT commands?
On my A650, #pbokr does not return the correct indices for downloaded ringtone assignments (it always returns 0=Inactive), it works fine for builtin ringtones. The only other way to get the correct ringtone assignment is to get them through the file system. I guess I could have gotten the entries through #pbokr and just update the ringtones through the file system, but I figure since I already retrieve the files so might as well. I would not have gone through this route if #pbokr worked properly. Strangely enough, #pbokw works properly for both builtin and downloaded ringtones.

-Joe Pham


________________________________________________________________
NetZero Gift Certificates
Give the gift of Internet access this holiday season.
http://www.netzero.com/give
Stephen Wood
2004-12-15 03:00:47 UTC
Permalink
Post by d***@netzero.com
Stephen,
this puts the phone back into modem mode without having to power cycle the phone.
It works with my A650, was not sure if it'd work with other Samsung phones. It now appears to work with at least one more Samsung phone.
qcplink calls the 0x44 command "reboot". Fortunately it doesn't reboot,
just returns to modem mode.

This also works for the Sanyo SCP-8100 and I have no reason to believe
it won't work for the other BitPim supported Sanyos.

I am hoping that it will also work for the Samsung MM-A700. That phone
apparently can get stuck in diagnostic/brew mode. That doesn't hurt the
phone, but it then can't be used as a modem or with sync programs.

I added an option in the file system browser to execute this modem mode
command. I will try to get an A700 user to try it.
Post by d***@netzero.com
Does this give advantages over using the AT commands?
On my A650, #pbokr does not return the correct indices for downloaded ringtone assignments (it always returns 0=Inactive), it works fine for builtin ringtones. The only other way to get the correct ringtone assignment is to get them through the file system. I guess I could have gotten the entries through #pbokr and just update the ringtones through the file system, but I figure since I already retrieve the files so might as well. I would not have gone through this route if #pbokr worked properly. Strangely enough, #pbokw works properly for both builtin and downloaded ringtones.
The VGA1000/A620 seems to have the same file system files that you use
for the phonebook. I look into adopting your code for that phone. And
this comes just as I have developed code to parse AT command responses
with .p files! But thats OK, I have a slew of older Samsung phones
without filesystems, so they will have to use the AT phonebook commands.

Stephen
Post by d***@netzero.com
-Joe Pham
Roger Binns
2004-12-15 03:34:15 UTC
Permalink
Post by Stephen Wood
this comes just as I have developed code to parse AT command responses
with .p files! But thats OK, I have a slew of older Samsung phones
without filesystems, so they will have to use the AT phonebook commands.
It will also be appreciated for GSM support.

Roger
Roger Binns
2004-12-17 06:58:10 UTC
Permalink
Post by d***@netzero.com
I guess I could have gotten the entries through #pbokr and just update
the ringtones through the file system,
That is generally how I do try to do things - use the official sync
protocol as much as possible and augment it with information obtained
in other ways. The official sync protocols are more portable between
models (ie less new code to write to support a new model) and are
also less likely to get broken by firmware updates. I am also always
paranoid that writing to the file directly could break some other
index or file elsewhere that points into it.

Roger
Vic Heintz
2004-12-14 15:25:54 UTC
Permalink
Post by d***@netzero.com
Stephen,
this puts the phone back into modem mode without having to power
cycle the phone.
It works with my A650, was not sure if it'd work with other Samsung
phones. It now appears to work with at least one more Samsung phone.
Does this give advantages over using the AT commands?
On my A650, #pbokr does not return the correct indices for downloaded
ringtone assignments (it always returns 0=Inactive), it works fine for
builtin ringtones. The only other way to get the correct ringtone
assignment is to get them through the file system. I guess I could
have gotten the entries through #pbokr and just update the ringtones
through the file system, but I figure since I already retrieve the
files so might as well. I would not have gone through this route if
#pbokr worked properly. Strangely enough, #pbokw works properly for
both builtin and downloaded ringtones.
You guys have lost me for the moment. I have a feeling I will want to
follow Joe's lead on this to fix the image and rt assignment process in
the A670's phonebook code but I know I don't have time before this next
build. Since the A650 looks so similar to the A670, I thought I would
try running BitPim as if my phone were an A650 and see what happens. I
get this exception:
File "/Users/vic/Projects/bitpim/com_samsungscha650.py", line 25, in ?
import p_samsungscha650
ImportError: No module named p_samsungscha650

How does the p_samsungscha650.py file get built from the
p_samsungscha650.p file?

Vic
d***@netzero.com
2004-12-14 16:23:19 UTC
Permalink
You can do from a shell:

python protogen.py p_samsungscha650.p p_samsungscha650.py

-Joe Pham


________________________________________________________________
NetZero Gift Certificates
Give the gift of Internet access this holiday season.
http://www.netzero.com/give
Roger Binns
2004-12-14 16:38:01 UTC
Permalink
Post by d***@netzero.com
python protogen.py p_samsungscha650.p p_samsungscha650.py
The "correct" way is to run 'makepackets.sh'. (On Windows install
MinGW/MSYS and associate .sh with the shell in MSYS).

For various historical reasons both the source (.p) and output
(.py) are in CVS.

Roger
d***@netzero.net
2004-12-15 13:25:53 UTC
Permalink
I have developed code to parse AT command responses with .p files
That'd still be useful since I still send phonebook entries, and other info, to the phone via AT commands.

-Joe Pham


________________________________________________________________
NetZero Gift Certificates
Give the gift of Internet access this holiday season.
http://www.netzero.com/give
Stephen Wood
2004-12-15 14:17:45 UTC
Permalink
Post by d***@netzero.net
I have developed code to parse AT command responses with .p files
That'd still be useful since I still send phonebook entries, and other info, to the phone via AT commands.
I will upgrade the A620 code to use the packet descriptions, sticking
the AT phonebook commands for now. That can then serve as an
example. Once I learn more about the file system on the phone (which
is similar, but not identical to yours), I'll migrate to using the
files.

If phonebook writes can be done with the filesystem, that would have
the advantage that "'s won't have to be stripped from names. I can't
figure out how to escape the " on PBOKR commands. But I think we have
to be extra careful using the filesystem when writing to it.

Stephen
Vic Heintz
2004-12-15 14:38:49 UTC
Permalink
Post by Stephen Wood
Post by d***@netzero.net
I have developed code to parse AT command responses with .p files
That'd still be useful since I still send phonebook entries, and
other info, to the phone via AT commands.
I will upgrade the A620 code to use the packet descriptions, sticking
the AT phonebook commands for now. That can then serve as an
example. Once I learn more about the file system on the phone (which
is similar, but not identical to yours), I'll migrate to using the
files.
If phonebook writes can be done with the filesystem, that would have
the advantage that "'s won't have to be stripped from names. I can't
figure out how to escape the " on PBOKR commands. But I think we have
to be extra careful using the filesystem when writing to it.
When I took a quick look at the packet descriptions for the A650 I
thought they looked exactly like I would want them for the A670,
however, when I ran BitPim pretending to be an A650 it did not work
except for calendar downloads. Obviously there are bigger differences
than I realized. I will try to upgrade my code also. My phone seems to
be somewhat of a hybrid between your two. It is a camera phone so I
need to handle camera images but the A650 is not, though the filesystem
is very similar. The A620 is apparently a camera phone but has a more
dissimilar filesystem. BTW there is a guy named Troy who is working on
code for the Telus version of the A670 which apparently has a different
filesystem from my Verizon version. Hopefully, he has joined this group
and is in the loop. We should try to keep the code for the various
Samsung models as similar as possible.

Vic
d***@netzero.com
2004-12-18 07:55:30 UTC
Permalink
Post by Roger Binns
That is generally how I do try to do things - use the official sync
protocol as much as possible and augment it with information obtained
in other ways
Totally agreed. That's why I read the phonebook by reading files, and update it by AT commands.

-Joe Pham



________________________________________________________________
NetZero Gift Certificates
Give the gift of Internet access this holiday season.
http://www.netzero.com/give
Roger Binns
2004-12-18 08:08:46 UTC
Permalink
Post by d***@netzero.com
Totally agreed. That's why I read the phonebook by reading files,
and update it by AT commands.
I take it that reading some of the fields by AT commands is a lost
cause? [My self interest is that I have the A500 (as loaner) and
want to do the least amount of work possible to support it :-]

On the LG phones each phonebook entry is synthesized from several
files whose format is fairly bizarre. The actually use BCD for the
phone numbers. That makes it way easier to just read using the
protocol. But then again they don't try to escape things.

You should also experiment with non-ascii characters. Some
of the Spanish letters work well. The LG phones use the
ISO-8859-1 character set. (I must admit I was fairly surprised
at them picking a reasonable standard for once.)

Roger

Loading...