Sodaq Sara R410M connect erro over tls

hi:
we use SARA-R410M-02B tls to connect the AWS,after connect the socket it return err +USOER: 11

this is our AT command:

AT+USECPRF=1,3,“rootca.der”
OK
AT+USECPRF=1,5,“client_ca.der”
OK
AT+USECPRF=1,6,“pclient_private.der”
OK

AT+USECPRF=1,0,0
OK

AT+UDCONF=1,1
OK

AT+USOCR=6
+USOCR: 0

OK

AT+USOSEC=0,1,1
OK

AT+USOCO=0,“xxxxxxxxxxxxxxx.amazonaws.com”,8883
OK

AT+USOER
+USOER: 11
OK

AT+USOWR=0,75,“104900044d515454048204b000084d5154544563686f00333f53444b3d416d617a6f6e4672xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx”
+CME ERROR: Operation not allowed

after that it refuse to write any data. why USOCO return OK while check it USOER:11

thank you

Can you use a domainname directly on a tcp socket?

Try looking up the IP first via DNS command +UDNSRN

thanks for your reply.but it is not surpport +UDNSRN:

AT+UDNSRN=0,“echo.u-blox.com

ERROR

Apparently it needs an activated Connection profile.

But does it work if you just use an IP? You could do the lookup you self and test the IP.

hi Krolken:
thank you for your reply. I use an IP directly,but it still come the same erro.

AT+USOER
+USOER: 11
OK

“ERRO 11 : EWOULDBLOCK / EAGAIN - Current operation would block, try again”