Skip to main content

PDU Converter: SMS PDU encoding and decoding, including GSM-0338 character set, support Python 3

Project description

PDU Converter Package

About this Package

  • This library will help you to encode and decode raw SMS data
  • Support 7-bit, 8-bit, 16-bit
  • Requires Python 3.6 or better

How to use (Encode and Decode)

Example to number 0123456789 with message Chào thế giới

>>> import smspdu, time
>>> p = smspdu.SMS_DELIVER.create('0123456789', '987654321', 'Chào thế giới', datestamp=time.time(), tp_sri=1, tp_mms=0)
>>> print(p.toPDU())
200A8110325476980008122182514023001A0043006800E0006F0020007400681EBF0020006700691EDB0069
>>> s = smspdu.SMS_DELIVER.fromPDU(p.toPDU(), '0123456789')
>>> print("s.tp_address: " + s.tp_address)
>>> print("s.tp_scts: " + s.tp_scts)
>>> print("s.user_data: " + s.user_data)
s.tp_address: 0123456789
s.tp_scts: 21122815043200
s.user_data: Chào thế giới

This is upgrade version. The original from smspdu 1.0

Project details


Release history Release notifications | RSS feed

This version

1.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pdusms-1.0.tar.gz (31.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pdusms-1.0-py3-none-any.whl (36.3 kB view details)

Uploaded Python 3

File details

Details for the file pdusms-1.0.tar.gz.

File metadata

  • Download URL: pdusms-1.0.tar.gz
  • Upload date:
  • Size: 31.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.5

File hashes

Hashes for pdusms-1.0.tar.gz
Algorithm Hash digest
SHA256 cf400a55911dae888e51a98ebcfd3073fde2a496ec911edf7e5aab032ebea73e
MD5 04b81872c6c46f4b23edf7370bf75a01
BLAKE2b-256 369126780d417e34da113d238611ec77cc73ebafb07ad54b45bce72da8652ab4

See more details on using hashes here.

File details

Details for the file pdusms-1.0-py3-none-any.whl.

File metadata

  • Download URL: pdusms-1.0-py3-none-any.whl
  • Upload date:
  • Size: 36.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.5

File hashes

Hashes for pdusms-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a8131f0e02419c52c0c68d937c861cbd247ed150ff7515d28cf4069a8b6282b3
MD5 2da5d1cd539780778f5f447a6bb22df5
BLAKE2b-256 480ac51c19788ba4ce4d9e781c043f5f05eadec737ae759814c066243c4f6df4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page