The prepare_nsapi_thread function enables threads that are not created by the server to act like server-created threads. This function must be called before any NSAPI functions are called from a thread that is not server-created.
void prepare_nsapi_thread(Request *rq, Session *sn);
void
Request *rq identifies the Request structure.
Session *sn identifies the Session structure.
The Request and Session parameters are the same as the ones passed into your SAF.