Skip to main content
Thierry Didi
Associate II
May 5, 2026
Solved

ST87M01 : MAX length of the data returned by AT#IPREAD

  • May 5, 2026
  • 3 replies
  • 196 views

Dear ST team,

In the ST87MXX AT Command User Manual, I can find that I can retrieve the data received on a socket with

AT#IPREAD:
AT#IPREAD=<context_id>,<socket_id>
#IPREAD: <context_id>,<socket_id>,<data_length>
<data>
OK

But I cannot find the max length of the <data> field that can be returned by the modem. 
Where could I find this information ?

Best Regards

Thierry

Best answer by Didier HERROUIN

Yes, AT#IPREAD is limited to 1 IP frame, it is a common way to proceed in NBIOT modems.

And if there are more data to received, you will get an URC message so that the application can read them using again AT#IPREAD.

Regards,

Didier

3 replies

Didier HERROUIN
Technical Moderator
May 7, 2026

Hello Thierry Didi,

The maximum size of an IP frame is defined using the AT command "AT#IPPARAMS", by the parameter "max_ip_frame_size"
It can be set from 512 bytes minimum to 1600 bytes maximum.

Best regards,

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Andrew Neil
Super User
May 7, 2026

So you're saying that the maximum amount returned by AT#IPREAD is one single IP frame?

A complex system that works is invariably found to have evolved from a simple system that worked.A complex system designed from scratch never works and cannot be patched up to make it work.
Thierry Didi
Associate II
May 7, 2026

Thanks Didier,
I think that I have the same question as Andrew : Does it mean that IP#IPREAD never provides more than one IP frame ? (even if more data has been received by the modem) ?

Then, in response to #IPRECV URC, we need to send several AT#IPREAD commands to read all the available data ?

Best Regards
Thierry

Didier HERROUIN
Technical Moderator
May 7, 2026

Yes, AT#IPREAD is limited to 1 IP frame, it is a common way to proceed in NBIOT modems.

And if there are more data to received, you will get an URC message so that the application can read them using again AT#IPREAD.

Regards,

Didier

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
Thierry Didi
Associate II
May 7, 2026

Super !

many thanks !

Thierry