# Tcp connection

**URL:** <https://forum.sierrawireless.com/t/tcp-connection/20283>\
**Category:** Uncategorized\
**Created:** [May 11, 2020, 5:45am UTC](https://forum.sierrawireless.com/t/tcp-connection/20283 "2020-05-11T05:45:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![yossi.a](https://avatars.discourse-cdn.com/v4/letter/y/c89c15/32.png) [@yossi.a](https://forum.sierrawireless.com/u/yossi.a)\
**Post date:** [May 11, 2020, 5:45am UTC](https://forum.sierrawireless.com/t/tcp-connection/20283/1 "2020-05-11T05:45:11Z")

</div>

Hi All,  
I am trying to create a tcp connection via HL7800 and need some help . I am Using the latest version 4.4.6.0 and getting a Error 921  
The connection is client to server Tcp.  
AT Command were taken from AIR-Prime HL78XX data sheet 14.5. How to Use TCP Commands  
14.5.1. Client Mode.

AT COMMANDS:  
AT&K3  
AT+KCNXCFG=1,“GPRS”,“APN”,“log”,“Password”,“IPV4”,“0.0.0.0”,“0.0.0.0”,“0.0.0.0”  
AT+KTCPCFG=1,0,“IP”,PORT"  
AT+KTCPCNX=1  
+CME ERROR: 921

Thanks

---

<div class="post-metadata">

**Author:** ![mlw](https://sea1.discourse-cdn.com/flex025/user_avatar/forum.sierrawireless.com/mlw/32/3706_2.png) [@mlw](https://forum.sierrawireless.com/u/mlw)\
**Post date:** [May 11, 2020, 10:46am UTC](https://forum.sierrawireless.com/t/tcp-connection/20283/2 "2020-05-11T10:46:47Z")

</div>

@yossi.a,

Can you send the following commands before the others?

at+creg?  
at+cereg?

These need to indicate you are attached to the network.

Regards

Matt

---

<div class="post-metadata">

**Author:** ![yossi.a](https://avatars.discourse-cdn.com/v4/letter/y/c89c15/32.png) [@yossi.a](https://forum.sierrawireless.com/u/yossi.a)\
**Post date:** [May 11, 2020, 11:31am UTC](https://forum.sierrawireless.com/t/tcp-connection/20283/3 "2020-05-11T11:31:05Z")

</div>

AT  
OK

AT+CMEE=1  
OK

AT+CGMR  
HL7800.4.4.6.0  
OK

AT+COPS?  
+COPS: 0,0,“OPERATOR”,7  
OK

AT+CREG=1  
OK

AT+CEREG=1  
OK

AT+CGPADDR=1  
+CGPADDR: 1,“IP”  
OK

AT+CSQ  
+CSQ: 20,99  
OK

Maybe this is the problem +CSQ: 20,99 ?

---

<div class="post-metadata">

**Author:** ![mlw](https://sea1.discourse-cdn.com/flex025/user_avatar/forum.sierrawireless.com/mlw/32/3706_2.png) [@mlw](https://forum.sierrawireless.com/u/mlw)\
**Post date:** [May 11, 2020, 2:21pm UTC](https://forum.sierrawireless.com/t/tcp-connection/20283/4 "2020-05-11T14:21:23Z")

</div>

@yossi.a

No the CSQ is not the issue, 20 is fine for making a connection. I presume you have modified the above CGPADDR response to “IP” where there was actually an IP address in there?

With the at+kcnxcfg command can you lave a number of the fields at the end blank so for EE in the UK

at+kcnxcfg=1,“GPRS”,“everywhere”

Miss everything else off as it might be configuring something the network does not like and leaving it blank will allow the network to do something it wants to do.

Regards

Matt
