{"id":2011,"date":"2025-04-14T12:48:00","date_gmt":"2025-04-14T12:48:00","guid":{"rendered":"https:\/\/webprojects.cloud\/wordpress\/splatco\/?post_type=spl_knowledgebase&#038;p=2011"},"modified":"2025-06-10T09:11:26","modified_gmt":"2025-06-10T09:11:26","slug":"sx10509-server-commands","status":"publish","type":"spl_knowledgebase","link":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/","title":{"rendered":"SX10509: Server Commands"},"content":{"rendered":"\n<p>The controller communicates with the SX10509 via commands. The following table lists the commands and the data that is associated with each one:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">  \n:: Transmit Buffer (Commands) ::\nCommandName CommandValue   NextByte          NextBytes\n              Byte 0        Byte 1           Bytes 2...n\n-----------------------------------------------------------------\nIdle        '00 \/ '80      Unused            Unused\nWrite       '01 \/ '81      bLength           Data..\nRead        '02 \/ '82      CumulativeOffset  Unused\nServer      '03 \/ '83      bLength           Data..\nPort        '04 \/ '84      4 bytes of floating point port number\nPath        '05 \/ '85      bLength           Data..\nContentType '06 \/ '86      bLength           Data..\nDoGet       '07 \/ '87      Unused            Unused\nDoPost      '08 \/ '88      Unused            Unused\nGetID       '09 \/ '89      Unused            Unused\nGetGMT      '0A \/ '8A      Unused            Unused\nGetIP       '0B \/ '8B      Unused            Unused\n  \n:: Receive Buffer (responses) ::\nCommandName CommandValue   NextByte          NextBytes\n              Byte 0        Byte 1           Bytes 2...n\n-----------------------------------------------------------------\nIdle        '00 \/ '80      Unused            Unused\nToServer    '01 \/ '81      Unused            Unused\nFromServer  '02 \/ '82      bLength           Data..\nServer      '03 \/ '83      Unused            Unused\nPort        '04 \/ '84      Unused            Unused\nPath        '05 \/ '85      Unused            Unused\nContentType '06 \/ '86      Unused            Unused\nDoGet       '07 \/ '87      bLength*          4 bytes of floating point status code\nDoPost      '08 \/ '88      bLength*          4 bytes of floating point status code\nGetID       '09 \/ '89      bLength           IDString..\nGetGMT      '0A \/ '8A      bLength           GMTString..\nGetIP       '0B \/ '8B      IP                IP,IP,IP\n\n* For DoGet and DoPost responses, the bLengthByte is the number of characters available \n  for readout using subsequent Read commands<\/pre>\n\n\n\n<p>To send a command, first load up any data associated with it, and the&nbsp;<code>bLength<\/code>&nbsp;byte is required. Then, once all the data is ready, load the command byte itself.<\/p>\n\n\n\n<p>The SX10509 will ignore the data until the command byte is loaded. Once it sees a new command byte, it will execute the command. When it finishes executing the command it will return a matching command byte in the network receive data block. For most commands this will be nearly instantaneous, but for&nbsp;<code>DoGet<\/code>&nbsp;and&nbsp;<code>DoPost<\/code>&nbsp;it may take several seconds.<\/p>\n\n\n\n<p>Be sure to wait for the command byte response before sending the next command.<\/p>\n\n\n\n<p>As the Xwire data blocks are limited to 32 bytes, these commands may require several iterations to be fully completed:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">   Write      \n   Read       \n   Server     \n   Path       \n   ContentType<\/pre>\n\n\n\n<p>For example, setting a path with more than 30 characters, like &#8220;<code>custom\/scripts\/mmi202\/poopump\/flow_monitor.php<\/code>&#8220;, must be done in two iterations.<\/p>\n\n\n\n<p>Bit 7 of the command byte may be toggled to indicate the next iteration is ready. Here&#8217;s an example:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">  \n;Creating two versions of the Path command provides a simple way to toggle\nCMDkPathA   EQU   '05   ;Path command\nCMDkPathB   EQU   '85   ;(toggled version of the) Path command\n  \n   SetMem         bTxByte1,0                          ;set the length to zero to erase any existing path\n   SetMem         bTxByte0,CMDkPathA                  ;load the command\nWafDoPath1:\n   YieldTask\n   GoIfMNE        bRxByte0,CMDkPathA,WafDoPath1       ;waf erase to complete\n \n   LoadI          0                                   ;zero the index (this will be used as a length indicator)\n   iiPrintText    bTxByte2,\"custom\/scripts\/mmi202\/p\"  ;store the first part of the path\n   ItoX                                               ;get the length\n   Store          bTxByte1                            ;store the length of the first part\n   SetMem         bTxByte0,CMDkPathB                  ;load the path command (toggled version)\nWafDoPath2:\n   YieldTask\n   GoIfMNE        bRxByte0,CMDkPathB,WafDoPath2       ;waf the SX10509 to save the first part\n \n   LoadI          0                                   ;zero the index (this will be used as a length indicator)\n   iiPrintText    bTxByte2,\"oopump\/flow_monitor.php\"  ;store the second part of the path\n   ItoX                                               ;get the length\n   Store          bTxByte1                            ;store the length of the second part\n   SetMem         bTxByte0,CMDkPathA                  ;load the path command\nWafDoPath3:\n   YieldTask\n   GoIfMNE        bRxByte0,CMDkPathA,WafDoPath3       ;waf the SX10509 to save the second part\n   ;-- the full path has now been loaded\n  <\/pre>\n\n\n\n<p>If, instead of issuing hardcoded strings you&#8217;re running in a loop, then you can toggle the command with a NotS instruction, for example:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">   NotS           7,bTxByte0                          ;toggle the command\n  <\/pre>\n\n\n\n<p>Now you can check for command completion by comparing the current Tx command with the Rx command, for example:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">   Recall         bTxByte0                            ;get the request\n   Recall         bRxByte0                            ;get the response\n   Compare                                            ;has the command been performed?\n   GoIfNZ         StillWaiting                        ;jump if still waiting<\/pre>\n\n\n\n<p>The\u00a0<a href=\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/tutorials-application-notes-and-white-papers\/tutorial-splat-call-home-sx10509-programming\/\">SX10509 tutorial<\/a>\u00a0shows an alternative way of doing this.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The controller communicates with the SX10509 via commands. The following table lists the commands and the data that is associated with each one: :: Transmit&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":2008,"menu_order":3,"template":"","class_list":["post-2011","spl_knowledgebase","type-spl_knowledgebase","status-publish","hentry"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>SX10509: Server Commands - SPLat Controls<\/title>\n<meta name=\"robots\" content=\"noindex, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SX10509: Server Commands - SPLat Controls\" \/>\n<meta property=\"og:description\" content=\"The controller communicates with the SX10509 via commands. The following table lists the commands and the data that is associated with each one: :: Transmit...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/\" \/>\n<meta property=\"og:site_name\" content=\"SPLat Controls\" \/>\n<meta property=\"article:modified_time\" content=\"2025-06-10T09:11:26+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/\",\"url\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/\",\"name\":\"SX10509: Server Commands - SPLat Controls\",\"isPartOf\":{\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#website\"},\"datePublished\":\"2025-04-14T12:48:00+00:00\",\"dateModified\":\"2025-06-10T09:11:26+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Product documentation\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Product documentation: Xwire peripherals\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"SX10509: Ethernet\/Internet &#8220;SPLat Call Home&#8221;\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"SX10509: Programming the SPLat controller\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/\"},{\"@type\":\"ListItem\",\"position\":6,\"name\":\"SX10509: Server\",\"item\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/\"},{\"@type\":\"ListItem\",\"position\":7,\"name\":\"SX10509: Server Commands\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#website\",\"url\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/\",\"name\":\"SPLat Controls\",\"description\":\"OEM Embedded Machine Controllers\",\"publisher\":{\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#organization\",\"name\":\"SPLat Controls\",\"url\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-content\/uploads\/2024\/10\/logo.svg\",\"contentUrl\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-content\/uploads\/2024\/10\/logo.svg\",\"caption\":\"SPLat Controls\"},\"image\":{\"@id\":\"https:\/\/webprojects.cloud\/wordpress\/splatco\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SX10509: Server Commands - SPLat Controls","robots":{"index":"noindex","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"og_locale":"en_US","og_type":"article","og_title":"SX10509: Server Commands - SPLat Controls","og_description":"The controller communicates with the SX10509 via commands. The following table lists the commands and the data that is associated with each one: :: Transmit...","og_url":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/","og_site_name":"SPLat Controls","article_modified_time":"2025-06-10T09:11:26+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/","url":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/","name":"SX10509: Server Commands - SPLat Controls","isPartOf":{"@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#website"},"datePublished":"2025-04-14T12:48:00+00:00","dateModified":"2025-06-10T09:11:26+00:00","breadcrumb":{"@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/sx10509-server-commands\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/"},{"@type":"ListItem","position":2,"name":"Product documentation","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/"},{"@type":"ListItem","position":3,"name":"Product documentation: Xwire peripherals","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/"},{"@type":"ListItem","position":4,"name":"SX10509: Ethernet\/Internet &#8220;SPLat Call Home&#8221;","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/"},{"@type":"ListItem","position":5,"name":"SX10509: Programming the SPLat controller","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/"},{"@type":"ListItem","position":6,"name":"SX10509: Server","item":"https:\/\/webprojects.cloud\/wordpress\/splatco\/knowledgebase\/product-documentation\/product-documentation-xwire-peripherals\/sx10509-ethernet-internet-splat-call-home\/sx10509-programming-the-splat-controller\/sx10509-server\/"},{"@type":"ListItem","position":7,"name":"SX10509: Server Commands"}]},{"@type":"WebSite","@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#website","url":"https:\/\/webprojects.cloud\/wordpress\/splatco\/","name":"SPLat Controls","description":"OEM Embedded Machine Controllers","publisher":{"@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/webprojects.cloud\/wordpress\/splatco\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#organization","name":"SPLat Controls","url":"https:\/\/webprojects.cloud\/wordpress\/splatco\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#\/schema\/logo\/image\/","url":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-content\/uploads\/2024\/10\/logo.svg","contentUrl":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-content\/uploads\/2024\/10\/logo.svg","caption":"SPLat Controls"},"image":{"@id":"https:\/\/webprojects.cloud\/wordpress\/splatco\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/spl_knowledgebase\/2011","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/spl_knowledgebase"}],"about":[{"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/types\/spl_knowledgebase"}],"author":[{"embeddable":true,"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/users\/1"}],"up":[{"embeddable":true,"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/spl_knowledgebase\/2008"}],"wp:attachment":[{"href":"https:\/\/webprojects.cloud\/wordpress\/splatco\/wp-json\/wp\/v2\/media?parent=2011"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}