Fwd: sch-u520
"John Schmitt" <[email protected]> Wed, 15 Oct 2008 19:04:25 -0500
| Newsgroups | gmane.comp.mobile.bitpim.devel |
|---|---|
| Message-ID | <[email protected]> |
I am having a little trouble porting the following block of code to my
phone, I have attached a sample call log with that describes a call going
out to 1234567891.
I know the off offsets for where the time and duration of the call is
located, but not how to add offsets into the reading process. I've put
comments at the 2 places I need the read buffer to jump to.
# read the call history files
> _req=self.protocolclass.cl_file()
> for _idx in call_list:
> try:
> _buf=prototypes.buffer(self.getfilecontents(
> '%s%02d'%(self.protocolclass.CL_PREFIX, _idx)))
> _req.readfrombuffer(_buf, 'Reading Call Log File')
> if _req.valid:
> _entry=call_history.CallHistoryEntry()
> _entry.folder=folder
> _entry.number=_req.number
> #_buf.setcurrentoffset(36)
> _entry.datetime=_req.datetime
#_buf.setcurrentoffset(80)
> if _req.duration:
> _entry.duration=_req.duration
> res[_entry.id]=_entry
> except com_brew.BrewNoSuchFileException:
> pass
> except:
> if __debug__:
> raise
How do I get my change into bitpim codebase as well?
<[email protected]>
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
BitPim-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bitpim-devel
clog_00
(application/octet-stream, 104 B) - not displayed