{"id":20874,"date":"2024-01-16T17:15:03","date_gmt":"2024-01-16T22:15:03","guid":{"rendered":"https:\/\/reactivemusic.net\/?p=20874"},"modified":"2024-01-16T17:25:55","modified_gmt":"2024-01-16T22:25:55","slug":"using-web-serial-api-for-radio-cat-interface","status":"publish","type":"post","link":"https:\/\/reactivemusic.net\/?p=20874","title":{"rendered":"Using Web Serial API for Radio CAT interface"},"content":{"rendered":"<p>Work in progress&#8230;<\/p>\n<p>An html example that sends and receives CAT commands with an Elecraft K4 connected to the serial port of the machine running the web browser.<\/p>\n<p>The file was built using examples from this article by Francois Beaufort.\u00a0<a href=\"https:\/\/developer.chrome.com\/docs\/capabilities\/serial\">https:\/\/developer.chrome.com\/docs\/capabilities\/serial<\/a> It&#8217;s an excellent resource for Web Serial.<\/p>\n<p>The html file for this project is here: <a href=\"http:\/\/www.pr0jex.com\/serial\/index.html\">http:\/\/www.pr0jex.com\/serial\/index.html<\/a><\/p>\n<p>But it won&#8217;t run from that server. It only runs locally.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-20875\" src=\"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png\" alt=\"\" width=\"300\" height=\"180\" srcset=\"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png 300w, https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-768x461.png 768w, https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM.png 996w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/p>\n<h3>Instructions<\/h3>\n<p>Download the index.html file from the link above. start a local web server, eg., &#8220;npx http-server&#8221; and enter the server address into a Chrome browser.<\/p>\n<p>When you press connect, the browser will prompt you to select a serial port for the radio.\u00a0 On my computer the K4 serial ports appear something like: cu2.usbserial-21100. There are 2 ports. Select either one.<\/p>\n<p>Then press read. If you spin the dial on the K4, and it is autoinfo mode, you should see CAT commands in the read window.<\/p>\n<p>enter a CAT command in the write window and press the write button. It is preloaded with &#8220;fa7;&#8221; which sets frequency to 7 MHz.<\/p>\n<p>Press the disconnect button to end your session.<\/p>\n<p>local files tkzic\/webusb\/serial2\/index.html<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Work in progress&#8230; An html example that sends and receives CAT commands with an Elecraft K4 connected to the serial port of the machine running the web browser. The file was built using examples from this article by Francois Beaufort.\u00a0https:\/\/developer.chrome.com\/docs\/capabilities\/serial It&#8217;s an excellent resource for Web Serial. The html file for this project is here: &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/reactivemusic.net\/?p=20874\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Using Web Serial API for Radio CAT interface&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_coblocks_attr":"","_coblocks_dimensions":"","_coblocks_responsive_height":"","_coblocks_accordion_ie_support":"","footnotes":""},"categories":[230,332],"tags":[25,57,12],"class_list":["post-20874","post","type-post","status-publish","format-standard","hentry","category-development","category-radio-2","tag-programming","tag-radio","tag-web-development"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.7 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Using Web Serial API for Radio CAT interface - reactive music<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/reactivemusic.net\/?p=20874\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Using Web Serial API for Radio CAT interface - reactive music\" \/>\n<meta property=\"og:description\" content=\"Work in progress&#8230; An html example that sends and receives CAT commands with an Elecraft K4 connected to the serial port of the machine running the web browser. The file was built using examples from this article by Francois Beaufort.\u00a0https:\/\/developer.chrome.com\/docs\/capabilities\/serial It&#8217;s an excellent resource for Web Serial. The html file for this project is here: &hellip; Continue reading &quot;Using Web Serial API for Radio CAT interface&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/reactivemusic.net\/?p=20874\" \/>\n<meta property=\"og:site_name\" content=\"reactive music\" \/>\n<meta property=\"article:published_time\" content=\"2024-01-16T22:15:03+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-01-16T22:25:55+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png\" \/>\n<meta name=\"author\" content=\"Tom Zicarelli\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Tom Zicarelli\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874\"},\"author\":{\"name\":\"Tom Zicarelli\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/#\\\/schema\\\/person\\\/56224d281582df7e5518e037ca63e571\"},\"headline\":\"Using Web Serial API for Radio CAT interface\",\"datePublished\":\"2024-01-16T22:15:03+00:00\",\"dateModified\":\"2024-01-16T22:25:55+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874\"},\"wordCount\":217,\"image\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/reactivemusic.net\\\/wp-content\\\/uploads\\\/2024\\\/01\\\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png\",\"keywords\":[\"programming\",\"radio\",\"web development\"],\"articleSection\":[\"development\",\"Radio\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874\",\"url\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874\",\"name\":\"Using Web Serial API for Radio CAT interface - reactive music\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/reactivemusic.net\\\/wp-content\\\/uploads\\\/2024\\\/01\\\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png\",\"datePublished\":\"2024-01-16T22:15:03+00:00\",\"dateModified\":\"2024-01-16T22:25:55+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/#\\\/schema\\\/person\\\/56224d281582df7e5518e037ca63e571\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/reactivemusic.net\\\/?p=20874\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#primaryimage\",\"url\":\"https:\\\/\\\/reactivemusic.net\\\/wp-content\\\/uploads\\\/2024\\\/01\\\/Screenshot-2024-01-16-at-5.04.05-PM.png\",\"contentUrl\":\"https:\\\/\\\/reactivemusic.net\\\/wp-content\\\/uploads\\\/2024\\\/01\\\/Screenshot-2024-01-16-at-5.04.05-PM.png\",\"width\":996,\"height\":598},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/?p=20874#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/reactivemusic.net\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Using Web Serial API for Radio CAT interface\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/#website\",\"url\":\"https:\\\/\\\/reactivemusic.net\\\/\",\"name\":\"reactive music\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/reactivemusic.net\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/reactivemusic.net\\\/#\\\/schema\\\/person\\\/56224d281582df7e5518e037ca63e571\",\"name\":\"Tom Zicarelli\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g\",\"caption\":\"Tom Zicarelli\"},\"sameAs\":[\"http:\\\/\\\/tomzicarelli.com\"],\"url\":\"https:\\\/\\\/reactivemusic.net\\\/?author=2\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Using Web Serial API for Radio CAT interface - reactive music","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/reactivemusic.net\/?p=20874","og_locale":"en_US","og_type":"article","og_title":"Using Web Serial API for Radio CAT interface - reactive music","og_description":"Work in progress&#8230; An html example that sends and receives CAT commands with an Elecraft K4 connected to the serial port of the machine running the web browser. The file was built using examples from this article by Francois Beaufort.\u00a0https:\/\/developer.chrome.com\/docs\/capabilities\/serial It&#8217;s an excellent resource for Web Serial. The html file for this project is here: &hellip; Continue reading \"Using Web Serial API for Radio CAT interface\"","og_url":"https:\/\/reactivemusic.net\/?p=20874","og_site_name":"reactive music","article_published_time":"2024-01-16T22:15:03+00:00","article_modified_time":"2024-01-16T22:25:55+00:00","og_image":[{"url":"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png","type":"","width":"","height":""}],"author":"Tom Zicarelli","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Tom Zicarelli","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/reactivemusic.net\/?p=20874#article","isPartOf":{"@id":"https:\/\/reactivemusic.net\/?p=20874"},"author":{"name":"Tom Zicarelli","@id":"https:\/\/reactivemusic.net\/#\/schema\/person\/56224d281582df7e5518e037ca63e571"},"headline":"Using Web Serial API for Radio CAT interface","datePublished":"2024-01-16T22:15:03+00:00","dateModified":"2024-01-16T22:25:55+00:00","mainEntityOfPage":{"@id":"https:\/\/reactivemusic.net\/?p=20874"},"wordCount":217,"image":{"@id":"https:\/\/reactivemusic.net\/?p=20874#primaryimage"},"thumbnailUrl":"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png","keywords":["programming","radio","web development"],"articleSection":["development","Radio"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/reactivemusic.net\/?p=20874","url":"https:\/\/reactivemusic.net\/?p=20874","name":"Using Web Serial API for Radio CAT interface - reactive music","isPartOf":{"@id":"https:\/\/reactivemusic.net\/#website"},"primaryImageOfPage":{"@id":"https:\/\/reactivemusic.net\/?p=20874#primaryimage"},"image":{"@id":"https:\/\/reactivemusic.net\/?p=20874#primaryimage"},"thumbnailUrl":"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM-300x180.png","datePublished":"2024-01-16T22:15:03+00:00","dateModified":"2024-01-16T22:25:55+00:00","author":{"@id":"https:\/\/reactivemusic.net\/#\/schema\/person\/56224d281582df7e5518e037ca63e571"},"breadcrumb":{"@id":"https:\/\/reactivemusic.net\/?p=20874#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/reactivemusic.net\/?p=20874"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/reactivemusic.net\/?p=20874#primaryimage","url":"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM.png","contentUrl":"https:\/\/reactivemusic.net\/wp-content\/uploads\/2024\/01\/Screenshot-2024-01-16-at-5.04.05-PM.png","width":996,"height":598},{"@type":"BreadcrumbList","@id":"https:\/\/reactivemusic.net\/?p=20874#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/reactivemusic.net\/"},{"@type":"ListItem","position":2,"name":"Using Web Serial API for Radio CAT interface"}]},{"@type":"WebSite","@id":"https:\/\/reactivemusic.net\/#website","url":"https:\/\/reactivemusic.net\/","name":"reactive music","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/reactivemusic.net\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/reactivemusic.net\/#\/schema\/person\/56224d281582df7e5518e037ca63e571","name":"Tom Zicarelli","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0da58cf21a2707dd335b204b8ed3cd9194dcbf9d9814ac5d71195a65c76c8a72?s=96&d=mm&r=g","caption":"Tom Zicarelli"},"sameAs":["http:\/\/tomzicarelli.com"],"url":"https:\/\/reactivemusic.net\/?author=2"}]}},"_links":{"self":[{"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/posts\/20874","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=20874"}],"version-history":[{"count":3,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/posts\/20874\/revisions"}],"predecessor-version":[{"id":20878,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=\/wp\/v2\/posts\/20874\/revisions\/20878"}],"wp:attachment":[{"href":"https:\/\/reactivemusic.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=20874"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=20874"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/reactivemusic.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=20874"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}