Package phones :: Module com_lgvx5500
[hide private]
[frames] | no frames]

Source Code for Module phones.com_lgvx5500

 1  #!/usr/bin/env python 
 2   
 3  ### BITPIM 
 4  ### 
 5  ### Copyright (C) 2009 Nathan Hjelm <hjelmn@users.sf.net> 
 6  ### 
 7  ### This program is free software; you can redistribute it and/or modify 
 8  ### it under the terms of the BitPim license as detailed in the LICENSE file. 
 9  ### 
10  ### 
11   
12  """ 
13  Communicate with the LG VX5500 cell phone 
14  """ 
15   
16  import common 
17  import com_lgvx9700 
18  import p_lgvx5500 
19   
20  parentphone=com_lgvx9700.Phone 
21 -class Phone(parentphone):
22 desc="LG-VX5500" 23 helpid=None 24 protocolclass=p_lgvx5500 25 serialsname='lgvx5500' 26 27 my_model='VX5500' 28 29 builtinringtones= ('Low Beep Once', 'Low Beeps', 'Loud Beep Once', 'Loud Beeps', 'Door Bell', 30 'VZW Default Ringtone', 'Home Phone', 'Short Note Beep', 'Move Bell', 31 'Lullaby', 'Telephone', 'Wahwah', 'Just Fine', 'Froggy Night', 32 'Whistling Wizard', 'Recollection', 'Funky Band', 'Why Not', 'Mystique', 33 'Evening Crow', 'Latin Fever', 'Cigar and Wine', 'Are You Ready', 34 'No Ring') 35 36 ringtonelocations= ( 37 # type index file default dir external dir max type index 38 ('ringers', 'dload/myringtone.dat','brew/mod/10889/ringtones', '', 100, 0x01, 100), 39 ( 'sounds', 'dload/mysound.dat', 'brew/mod/18067', '', 100, 0x02, None), 40 ) 41 42 wallpaperlocations= ( 43 # type index file default dir external dir max type Index 44 ( 'images', 'dload/image.dat', 'brew/mod/10888', '', 100, 0x00, 100), 45 ) 46
47 - def setDMversion(self):
48 self._DMv5=False 49 self._DMv6=True 50 self._timeout=5 # Assume a quick timeout on newer phones
51 52 parentprofile=com_lgvx9700.Profile
53 -class Profile(parentprofile):
54 phone_manufacturer='LG Electronics Inc' 55 phone_model='VX5500' 56 # inside screen resoluation 57 WALLPAPER_WIDTH=176 58 WALLPAPER_HEIGHT=220 59 60 ringtoneorigins=('ringers', 'sounds') 61 62 imageorigins={} 63 imageorigins.update(common.getkv(parentprofile.stockimageorigins, "images")) 64 65 # our targets are the same for all origins 66 imagetargets={} 67 imagetargets.update(common.getkv(parentprofile.stockimagetargets, "wallpaper", 68 {'width': 176, 'height': 220, 'format': "JPEG"})) 69 imagetargets.update(common.getkv(parentprofile.stockimagetargets, "pictureid", 70 {'width': 96, 'height': 64, 'format': "JPEG"})) 71 imagetargets.update(common.getkv(parentprofile.stockimagetargets, "outsidelcd", 72 {'width': 96, 'height': 64, 'format': "JPEG"})) 73 74 _supportedsyncs=( 75 ('phonebook', 'read', None), # all phonebook reading 76 ('calendar', 'read', None), # all calendar reading 77 ('wallpaper', 'read', None), # all wallpaper reading 78 ('ringtone', 'read', None), # all ringtone reading 79 # ('call_history', 'read', None),# all call history list reading 80 # ('sms', 'read', None), # all SMS list reading 81 ('memo', 'read', None), # all memo list reading 82 ('phonebook', 'write', 'OVERWRITE'), # only overwriting phonebook 83 ('calendar', 'write', 'OVERWRITE'), # only overwriting calendar 84 ('wallpaper', 'write', 'MERGE'), # merge and overwrite wallpaper 85 ('wallpaper', 'write', 'OVERWRITE'), 86 ('ringtone', 'write', 'MERGE'), # merge and overwrite ringtone 87 ('ringtone', 'write', 'OVERWRITE'), 88 # ('sms', 'write', 'OVERWRITE'), # all SMS list writing 89 ('memo', 'write', 'OVERWRITE'), # all memo list writing 90 ('t9_udb', 'write', 'OVERWRITE'), 91 ) 92 if __debug__: 93 _supportedsyncs+=( 94 ('t9_udb', 'read', 'OVERWRITE'), 95 )
96