Package phones :: Module com_moto :: Class Phone
[hide private]
[frames] | no frames]

Class Phone

source code

     object --+        
              |        
com_phone.Phone --+    
                  |    
     com_etsi.Phone --+
                      |
                     Phone
Known Subclasses:

Talk to a generic Motorola phone.

Instance Methods [hide private]
 
__init__(self, logtarget, commport)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
set_mode(self, mode)
Set the current phone mode
source code
 
charset_ascii(self)
Set the charset to ASCII (default)
source code
 
charset_ucs2(self)
Set the charset to UCS-2, used for most string values
source code
 
select_phonebook(self, phonebook=None) source code
 
ucs2_to_ascii(self, v)
convert an UCS-2 to ASCII string
source code
 
ascii_to_ucs2(self, v)
convert an ascii string to UCS-2
source code
 
_setmodemodemtophonebook(self) source code
 
_setmodemodem(self) source code
 
_setmodephonebook(self) source code
 
_setmodephonebooktomodem(self) source code
 
decode_utf16(self, v)
Decode a Motorola unicode string
source code
 
encode_utf16(self, v)
Encode a unicode/string into a Motorola unicode
source code
 
get_model(self) source code
 
get_manufacturer(self) source code
 
get_phone_number(self) source code
 
get_firmware_version(self) source code
 
get_signal_quality(self) source code
 
get_battery_level(self) source code
 
getphoneinfo(self, phone_info) source code
 
getfundamentals(self, results)
Gets information fundamental to interopating with the phone and UI.
source code
 
_update_group_ringtone(self, results) source code
 
_setup_ringtone_name_dict(self, fundamentals)
Create a new ringtone dict keyed by name for lookup
source code
 
_setup_group_name_dict(self, fundamentals)
Create a new group dict keyed by name for lookup
source code
 
_mark_used_slots(self, entries, sd_slots, key_name)
Mark the speed dial slots being used
source code
 
_get_sd_slot(self, entries, sd_slots, key_name)
Populate the next available speed dial
source code
 
_ensure_speeddials(self, fundamentals)
Make sure that each and every number/email/mail list has a speed dial, which is being used as the slot/index number
source code
 
_get_groups(self) source code
 
_get_ringtone_index(self) source code
 
_get_wallpaper_index(self) source code
 
_save_groups(self, fundamentals) source code
 
_build_pb_entry(self, entry, pb_book, fundamentals)
Build a BitPim phonebook entry based on phone data.
source code
 
_update_mail_list(self, pb_book, fundamentals) source code
 
getphonebook(self, result)
Reads the phonebook data.
source code
 
savephonebook(self, result)
Saves out the phonebook
source code
 
_build_cal_entry(self, entry, calendar, fundamentals)
Build a BitPim calendar object from phonebook data
source code
 
del_calendar_entry(self, index) source code
 
lock_calendar(self, lock=True)
Lock the calendar to access it
source code
 
getcalendar(self, result)
Read all calendars from the phone
source code
 
savecalendar(self, result, merge)
Save calendar entries to the phone
source code
 
select_default_SMS(self)
Select the default SMS storage
source code
 
_process_sms_header(self, _header, _entry) source code
 
_process_sms_text(self, res, entry) source code
 
_process_sms_result(self, _res, _sms, fundamentals)
Process an SMS result as returned from the phone
source code
 
getsms(self, fundamentals)
Read SMS messages from the phone
source code

Inherited from com_etsi.Phone: get_esn, get_manufacturer_id, get_model_id, get_sim_id, sendATcommand

Inherited from com_phone.Phone: alert, close, log, logdata, progress, raisecommsdnaexception, raisecommsexception, readobject, setmode, writeobject

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Class Variables [hide private]
  desc = 'Motorola'
  protocolclass
Various descriptions of data specific to Motorola phones
  MODEPHONEBOOK = 'modephonebook'

Inherited from com_phone.Phone: MODEMODEM, MODENONE, getcallhistory, getmemo, getplaylist, gett9db, gettodo

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, logtarget, commport)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

_setmodemodem(self)

source code 
Overrides: com_phone.Phone._setmodemodem

get_firmware_version(self)

source code 
Overrides: com_etsi.Phone.get_firmware_version

getfundamentals(self, results)

source code 

Gets information fundamental to interopating with the phone and UI.

Currently this is:

  • 'uniqueserial' a unique serial number representing the phone
  • 'groups' the phonebook groups
  • 'wallpaper-index' map index numbers to names
  • 'ringtone-index' map index numbers to ringtone names

This method is called before we read the phonebook data or before we write phonebook data.

_build_pb_entry(self, entry, pb_book, fundamentals)

source code 

Build a BitPim phonebook entry based on phone data. Need to to implement in subclass for each phone

getphonebook(self, result)

source code 

Reads the phonebook data. The getfundamentals information will already be in result.

getsms(self, fundamentals)

source code 

Read SMS messages from the phone

Overrides: getsms

Class Variable Details [hide private]

protocolclass

Various descriptions of data specific to Motorola phones

Value:
phones.p_moto