{"id":145500,"date":"2020-06-21T08:38:12","date_gmt":"2020-06-21T15:38:12","guid":{"rendered":"https:\/\/m2msupport.net\/m2msupport\/?page_id=145500"},"modified":"2020-06-23T06:19:07","modified_gmt":"2020-06-23T13:19:07","slug":"tcp-ip-testing-with-simcom-sim7070-sim7080-modules","status":"publish","type":"page","link":"https:\/\/m2msupport.net\/m2msupport\/tcp-ip-testing-with-simcom-sim7070-sim7080-modules\/","title":{"rendered":"TCP\/IP testing with Simcom SIM7070\/SIM7080 Modules"},"content":{"rendered":"<h3>Steps to test TCP\/IP with SIM7070 and SIM7080 Modules<\/h3>\n<ul>\n<li>Verify that the device is registered with the network provider<\/li>\n<li>Verify that APN is assigned using\u00a0 the AT+CGNAPN command<\/li>\n<li>Activate the network using the AT+CNACT command<\/li>\n<li>Configure the device for TCP connection using the AT+CNCFG command<\/li>\n<li>Open a TCP connection to the remote server using the AT+CAOPEN command.<\/li>\n<li>Send TCP data using the AT+CASEND command<\/li>\n<li>Get the response from the remote server using the AT+CARECV command.<\/li>\n<\/ul>\n<p><a href=\"https:\/\/m2msupport.net\/m2msupport\/download-at-command-tester-for-simcom-modules\/\">AT Command Tester<\/a> Tool provides an interface to test the TCP connection with the Simcom modules.<\/p>\n<p>In this example,<\/p>\n<ul>\n<li>TCP connection is made to remote server &#8216;postman-echo.com&#8217;<\/li>\n<li>HTTP formatted data is sent to the remote server<\/li>\n<li>The remote server echos the IP address of the device which is received by the module.<\/li>\n<\/ul>\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/m2msupport.net\/m2msupport\/wp-content\/uploads\/2020\/06\/simcom_sim7080_tcp_ui.png\" alt=\"\" class=\"wp-image-32155\"\/><\/figure>\n<br \/>\n\n\n<div class=\"video-responsive\"><iframe loading=\"lazy\" id=\"youTubePlayer\" src=\"https:\/\/www.youtube.com\/embed\/PUBExx9XRWc\" width=\"750\" height=\"421\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/div>\n<p><\/p>\n<h3><strong>TCP Testing in script mode <\/strong><\/h3>\n<p>TCP function can be tested with script mode in the&nbsp;<a href=\"https:\/\/m2msupport.net\/m2msupport\/download-at-command-tester-for-simcom-modules\/\">AT Command Tester<\/a>&nbsp;tool.<\/p>\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/m2msupport.net\/m2msupport\/wp-content\/uploads\/2020\/06\/simcom_sim7080_tcp.png\" alt=\"\" class=\"wp-image-32155\"\/><\/figure>\n\n\n<p>Try the script in&nbsp;<a href=\"https:\/\/m2msupport.net\/m2msupport\/download-at-command-tester-for-simcom-modules\/\">AT Command Tester<\/a>&nbsp;tool.\n<\/p>\n<pre style=\"color: blue; background-color: white; border: 1px solid black;\">\/\/Script: TCP testing with SIM7070\/SIM7080 modules\n\/\/Check SIMCOM Module AT Command documentaiton\n\n\/\/Get the current TCP configuration\nAT+CACFG?\n\n\/\/Wait\nWAIT=1\n\n\/\/TCP\/UDP wait time\nAT+CACFG=\"TRANSWAITTM\",5\n\n\/\/Wait\nWAIT=1\n\n\/\/TCP\/UDP packet size\nAT+CACFG=\"TRANSPKTSIZE\",1024\n\n\/\/Wait\nWAIT=1\n\n\/\/TCP\/UDP timeout\nAT+CACFG=\"TIMEOUT\",0,10\n\n\/\/Wait\nWAIT=1\n\n\/\/Activate the network\nAT+CNACT=0,1\n\n\/\/Wait\nWAIT=5\n\n\/\/Open TCP connection\n\/\/CID, PDP Index, connection type, server address, port\nAT+CAOPEN=0,0,\"TCP\",\"postman-echo.com\",80\n\n\/\/Wait\nWAIT=5\n\n\/\/Send\nAT+CASEND=0,46\n\n\/\/Send HTTP get as the TCP data\n<cr><lf>GET https:\/\/postman-echo.com\/ip HTTP\/1.0<cr><lf>\n\n\/\/Wait for response\nWAIT=5\n\n\/\/Get the response from the remote server\nAT+CARECV=0,500\n\n\/\/Wait for response\nWAIT=3\n\n\/\/Close the connection\nAT+CACLOSE=0\n\n\n\n<\/lf><\/cr><\/lf><\/cr><\/pre>\n<p>Output of the script in the&nbsp;<a href=\"https:\/\/m2msupport.net\/m2msupport\/download-at-command-tester-for-simcom-modules\/\">AT Command Tester<\/a>&nbsp;tool.\n<\/p>\n<pre style=\"color: blue; background-color: #ffffcc; border: 1px solid black;\">AT+CACFG?\n\n+CACFG: TRANSWAITTM,2\n\n+CACFG: TRANSPKTSIZE,1024\n\nOK\nAT+CACFG=\"TRANSWAITTM\",5\n\nOK\nAT+CACFG=\"TRANSPKTSIZE\",1024\n\nOK\nAT+CACFG=\"TIMEOUT\",0,10\n\nOK\nAT+CNACT=0,1\n\nOK\n\n+APP PDP: 0,ACTIVE\nAT+CAOPEN=0,0,\"TCP\",\"postman-echo.com\",80\n\n+CAOPEN: 0,0\n\nOK\nAT+CASEND=0,46\n\n&gt; \nOK\n\n+CASEND: 0,0,46\n\n+CADATAIND: 0\n\n+CASTATE: 0,0\nAT+CARECV=0,500\n\n+CARECV: 351,HTTP\/1.1 200 OK\n\nDate: Sun, 21 Jun 2020 15:53:47 GMT\n\nContent-Type: application\/json; charset=utf-8\n\nContent-Length: 22\n\nConnection: close\n\nETag: W\/\"16-oWgnR5OcW0cDXWFy\/\/pdWkFPX5Y\"\n\nVary: Accept-Encoding\n\nset-cookie: sails.sid=s%3ASdk9zJoskd7lyjdQqqL1KXCTZfHOdI7e.A0fAwOW7CSujaLee93RvJkFEVCrQUnXQn6G082bheNw; Path=\/; HttpOnly\n\n\n\n{\"ip\":\"54.244.63.216\"}\n\nOK\nAT+CACLOSE=0\n\nTCP connection is closed by remote server\n\nOK\n\n\n\n<\/pre>\n<div class=\"video-responsive\"><iframe loading=\"lazy\" id=\"youTubePlayer\" src=\"https:\/\/www.youtube.com\/embed\/DAu6VR4muog\" width=\"750\" height=\"421\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/div>","protected":false},"excerpt":{"rendered":"<p>Steps to test TCP\/IP with SIM7070 and SIM7080 Modules Verify that the device is registered with the network provider Verify that APN is assigned using\u00a0 the AT+CGNAPN command Activate the network using the AT+CNACT command Configure the device for TCP &hellip; <a href=\"https:\/\/m2msupport.net\/m2msupport\/tcp-ip-testing-with-simcom-sim7070-sim7080-modules\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"software_howto.php","meta":{"footnotes":""},"class_list":["post-145500","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/pages\/145500","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/comments?post=145500"}],"version-history":[{"count":13,"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/pages\/145500\/revisions"}],"predecessor-version":[{"id":145642,"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/pages\/145500\/revisions\/145642"}],"wp:attachment":[{"href":"https:\/\/m2msupport.net\/m2msupport\/wp-json\/wp\/v2\/media?parent=145500"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}