BC66: How to detect if message was sent?

When sending messages using BC66, is there any (reliable) way to detect if the message was actually sent?

AT+QISENDEX returns error if the module was not yet connected. But once connected, it will accept the message with SEND OK reply, which only confirms that the message was accepted by the module stack. Then it tries to actually send it (PSM exit, RRC connected etc.), but this may fail, e.g. no network is available. But the module is not reporting the result of this operation. It is possible to detect some situations (e.g. not going to CEREG 1 or 5), but it is just guessing.
As the module discards the message in such a situation, it would be nice to detect it and send it again later.

2 Likes

Hi Rastik
AT+QISEND=,0 Query whether the data is successfully sent to the server.

1 Like

Hello Abner, I wasn’t able to find it in any documentation, thank you.
What exactly the response means?
I get +QISEND: 1,0,1 or +QISEND: 0,0,0.

1 Like

Hello Abner,
i think OK mean that data put to buffer, is not sent from module to air.

I’ve found the documentation of QISEND=,0 in BG96 TCP/IP AT Commands Manual. Important are page 7 (bottom loop in the diagram) and page 18.

Thank you @Abner-Q for pointing it out, it would be nice if this information is included in BC66 documentation as well.

Write Command
When <send_length> is 0, query the sent data
AT+QISEND=<connectID>,0

Response
If the specified <connectID> connection has existed, response:
+QISEND: <total_send_length>,<ackedbytes>,<unackedbytes>
OK

Hi Kvx
OK means that the data is sent to the module buffer area, send ok means that the data is sent to the module protocol stack, AT+QISEND=, 0 queries whether the data has reached the server.

Hi Rastik
You can ask quectel local FAE for the latest BC66 TCP application guide.

You can test it , register in network, disconect antenna, send data AT+QISEND, check answer Ok, and data on server, and you will have
AT+QISEND=0,10,1234567890
OK
SEND OK
but no data on server :slight_smile:

Hi Kvx
AT+QISEND=,0 Query the total length of the data that has been answered and sent but not answered.

Hello Abner,
Yes, your right, need contron, by AT+QISEND=0,0

AT+QISEND=0,10,1234567890
OK
SEND OK
AT+QISEND=0,10,1234567890
OK
SEND OK
AT+QISEND=0,0
+QISEND: 20,20,0
OK
----disconnected antenna-----
AT+QISEND=0,10,1234567890
OK
SEND OK
AT+QISEND=0,10,1234567890
OK
SEND OK
AT+QISEND=,0
+QISEND: 40,20,20
OK

From datasheet
image

Hello Abner,

May me you know how check the total length of the data sent in NIDD tychnology ?

AT+NIDD=0,“APN”,",""
+NIDD=0,0
OK
AT+NIDD=1,0
+NIDD=1,0
OK
AT+NIDD=2,0
OK
AT+NIDD=3,0,“343434345545343434”
OK

@Abner-Q Finally I tried to implement this check on BC66 and it is not working, at least not for UDP. No matter what I do I always get only unackedbytes incremented for UDP connections. Even though the data is sent to the server ackedbytes is still zero. In fact, unackedbytes is incremented even when AT+QISEND returns SEND FAIL (e.g. after AT+CFUN=0).
With TCP it works, but then we are not talking about checking if the network has accepted the message, but if the other party confirmed it.
@KvX Was your test done on BC66 or BG96? Was it TCP or UDP?

the UDP protocol does not involve acknowledgements that the data was received by the remote host. UDP frames are simply sent. if you’re lucky, the network stack (i.e. BC66) gives you some error/success indication, but that’s outside of the protocol, and doesn’t say if the data was actually received by the remote host.

if you need acknowledged data exchange, you need a different protocol (TCP?) or to build acknowledgements on top in the application layer (server).

the documentation may be rubbish about stating it clearly but ackedbytes only counts the bytes that were acknowledged by the server/remote host. I glean that from the whole appnote including comments on examples.

@crackwitz I don’t need confirmations on top of IP stack (e.g. TCP), I just need to know if the message that was acknowledged by the module stack (i.e. SEND OK) was relayed to the radio network or not. I’d expect that the module knows this.