Thanks to all of you for your interesting, useful and educative inputs. I learnt a lot.
It is indeed likely that I confused TTN-branded “Things Uno” node board with TTN.
I apologize for that confusion, but I hope that the community is also meant to help unskilled people.
In great part thanks to your comments, I finally solved my problem (see at the end of the message). In spite of the numerous suggestions that you made I unfortunately could not identify the origin of the problem. For sure I am not expert enough. I have however been very surprised that the community would not consider “possible” that a LoRa connection might be interrupted for many uncontrollable and possibly unresolvable reasons. When I make a phone call, I sometimes face an unexpected interruption although there should be no reason for that.
So, instead of climbing the steep mountain, I walked around it. This may not be satisfactorily as some of you mentioned, but at least I ascertained that it works.
The ttn_response_t toto = ttn.sendBytes(payload, sizeof(payload));
command seems to both send the payload and put the feedback from the gateway into the toto variable, with values being 1 when the transmission is successful, -10 when there is a problem, -1 when the payload could not be sent, and maybe other values in other situations.
Thus I added a test on the toto value to restart the join procedure when the value of toto is different from 1. And it works finely.
I still do not know how to close a discussion (is it my responsibility ? or the responsibility of any authorized member of the community ?), but as far as I am concerned, the discussion can be closed.