SMS delete by gsmctl CLI

Hello,

we are using the TRB140 with the current firmware TRB1_R_00.07.06.10.
To delete SMS by cli you offer “gsmctl --sms --delete ” and “gsmctl --sms --pdu_delete ”

The --delete function seems to be buggy if the SMS index is not exists and the error response is not clearfy the issue.

root@TRB140:~# gsmctl --sms --list all
Index:          5
Date:           Fri Apr 19 13:10:59 2024
Sender:         +xxxxxxxxxx
Status:         read
Missing:        0
UDHL:           5
IEI type:       0
IEI length:     3
Ref ID:         140
Total parts:    3
Stored parts:   3
Parts:          1 2 3
Pdus:           5 6 7
Text:           Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed dia m voluptua. At vero eos et accusam et
root@TRB140:~# gsmctl --sms --delete 1
[gsmctl_delete_sms:48] error: ERROR: Invalid arguments (errno:2) 'AT+CMGL=4\r' => '\r'

The --pdu_delete function works but also response with “OK” if the sms not exist.

root@TRB140:~# gsmctl --sms --pdu_delete 1
OK

Not perfect but fixable with workarounds. We are looking forward to that the issue will be fixed in future releases.
Thanks.

Cheers,

Hi,

When it comes to deleting messages, there are two distinct commands: PDU and INDEX. These commands determine what gets deleted based on whether you select PDU or INDEX.

For instance, using --pdu_delete won’t delete the same PDU.

2024-04-22-16-10-03-192.168.50.1

It’s important to understand that SMS and PDUs are not interchangeable terms. In SMS lingo, PDU refers to a format utilized for encoding and sending SMS messages over the air interface linking a mobile device to the cellular network. Each SMS message gets wrapped in one or more PDUs for transmission.

To simplify, you can picture SMS as being comprised of PDUs. For illustration, here is the message that has a single index but two PDU numbers:

2024-04-22-16-18-21-192.168.50.1

Best regards,

This topic was automatically closed after 15 days. New replies are no longer allowed.