Skip to content

Implement PDU mode for sim800 module #2

@cbosdo

Description

@cbosdo

Sending long SMSes is only possible using the PDU mode. This would be useful for the help command since this generates several messages for now: concatenated SMS would make this more readable for the user.

Useful resources:

Reading a received SMS PDU:

import smspdu
from io import StringIO
sms_data = smspdu.fields.SMSDeliver.decode(StringIO(the_pdu_from_cmgr))

Preparing the PDU to send an SMS:

import smspdu
pdu = smspdu.SMS_SUBMIT.create(_, 'recipient', 'The message should not exceed 140 characters.')

To send longer messages cut them and play with the user data headers.
See https://en.wikipedia.org/wiki/Concatenated_SMS

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions