python-messaging
python-messaging copied to clipboard
Issue in timestap
mismatch in decoding pdu sms delivery time example: text mode: at+cmgr=5 +CMGR: "REC READ","+917618799612",,"17/10/05,11:54:04+22" hg
pdu mode: at+cmgr=5 +CMGR: 1,,21 0791198954800710040C9119678197692100007101501145402202E833
output:
pdu = "0791198954800710040C9119678197692100007101501145402202E833" sms = SmsDeliver(pdu) print sms.date 2017-10-05 06:24:04
Pduspy shows that the network timestamp has offset of GMT+5.5 hours, the modem hasn't adjusted the display time for that, but shows the +22 quarter hours (+5.5 hours). Python-messaging has normalised the time, so that you may apply whatever local timezone you choose, do date calculations and sorting etc.
