{"id":400,"date":"2021-11-28T15:40:41","date_gmt":"2021-11-28T15:40:41","guid":{"rendered":"http:\/\/www.thelemmingfarm.uk\/?p=400"},"modified":"2021-11-28T15:41:23","modified_gmt":"2021-11-28T15:41:23","slug":"remote-controller-test","status":"publish","type":"post","link":"http:\/\/www.thelemmingfarm.uk\/?p=400","title":{"rendered":"Remote Controller test"},"content":{"rendered":"\n<p>A few years back we bought a<a href=\"https:\/\/thepihut.com\/products\/raspberry-pi-compatible-wireless-gamepad-controller\" target=\"_blank\" rel=\"noreferrer noopener\"> Pi Hut wireless controller<\/a> at the fantastic <a href=\"https:\/\/www.raspberrypi.org\/raspberry-fields\/\" target=\"_blank\" rel=\"noreferrer noopener\">Raspberry Fields<\/a>, which I&#8217;m sad to say that despite the varied amount of buttons and joysticks it contains we haven&#8217;t used in a single project since.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"379\" height=\"270\" src=\"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg\" alt=\"\" class=\"wp-image-401\" srcset=\"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg 379w, http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747-300x214.jpg 300w\" sizes=\"auto, (max-width: 379px) 100vw, 379px\" \/><\/figure><\/div>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:33.33%\">\n<p>The test setup looked like this. The Pi is connected to a USB hub containing a wireless mouse, keyboard and finally the Controller.<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:66.66%\">\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"640\" height=\"368\" src=\"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_142607.jpg\" alt=\"\" class=\"wp-image-402\" srcset=\"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_142607.jpg 640w, http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_142607-300x173.jpg 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>Following instructions from the Pi Hut page, it points the the <a href=\"https:\/\/approxeng.github.io\/approxeng.input\/index.html\">Approximate Engineering\u2019s Python Game Controller<\/a> library built for a PiWars robot. Installation was simple so I headed over to the Simple Usage section to try things out and built some python to connect to the controller.<\/p>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:33.33%\">\n<p>Using some Python similar to the right built from the examples looked to be working, but didn&#8217;t seem to register any of the controller button presses. <\/p>\n\n\n\n<p>It also had the problem of not being able to escape and sleep obviously not being imported!<\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:66.66%\">\n<pre class=\"wp-block-code has-small-font-size\"><code lang=\"python\" class=\"language-python line-numbers\">from approxeng.input.selectbinder import ControllerResource\n\nwhile True:\n    try:\n        with ControllerResource() as joystick:\n            print('Found a joystick and connected')\n            while joystick.connected:\n                # Do stuff with your joystick here!\n                # ....\n                # ....\n\n                # If we had any presses, print the list of pressed buttons by standard name\n                if joystick.has_presses:\n                    print(joystick.presses)\n        # Joystick disconnected...\n        print('Connection to joystick lost')\n    except IOError:\n        # No joystick found, wait for a bit before trying again\n        print('Unable to find any joysticks')\n<strong>        sleep(1.0)<\/strong>\n<\/code><\/pre>\n<\/div>\n<\/div>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-9d6595d7 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:66.66%\">\n<pre class=\"wp-block-code has-small-font-size\"><code lang=\"python\" class=\"language-python line-numbers\">from approxeng.input.controllers import find_matching_controllers\r\nfrom approxeng.input.controllers import print_controllers\r\nfrom approxeng.input.controllers import print_devices\r\n\r\n\r\ndiscoveries = find_matching_controllers()\r\n\r\nprint_controllers()\r\nprint_devices()\r<\/code><\/pre>\n<\/div>\n\n\n\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:33.33%\">\n<p>In trying to figure out why it was connecting but not registering any key presses I looked to see what else it could be picking up.<\/p>\n\n\n\n<p>This seems to pick up a number of controllers \/ devices, so I can only assume the code picked the first one it found and this wasn&#8217;t the correct one. <\/p>\n<\/div>\n<\/div>\n\n\n\n<p>On the hunt for further examples to test led to the &#8220;Examples&#8221; section. One that jumped out and looked fairly simple was &#8220;Streaming Axis and Button Hold values&#8221;. I tried this and it worked!<\/p>\n\n\n\n<p>The only difference was the line:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code lang=\"python\" class=\"language-python\">ControllerRequirement(require_snames=['lx', 'ly'])<\/code><\/pre>\n\n\n\n<p>which in fairness an early example in the simple usage section did list:<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code lang=\"python\" class=\"language-python\">        <strong>with<\/strong> ControllerResource(ControllerRequirement(require_class=DualShock3),\n                                ControllerRequirement(require_snames=['lx','ly'])) <strong>as<\/strong> ds3, joystick:\n<\/code><\/pre>\n\n\n\n<p>This allows it to pick the first device that has a left joystick. so adding this and rerunning now worked!<\/p>\n\n\n\n<pre class=\"wp-block-code has-small-font-size\"><code lang=\"bash\" class=\"language-bash\">pi@carpizero:~\/code\/TheLemmingFarm\/Code\/controller $ python3 checkbuttons.py \r\nFound a joystick and connected\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\nLeft stick: x=1.0, y=0.3850157346889374 Right stick: x=0, y=0\r\nLeft stick: x=0, y=1.0 Right stick: x=0, y=0\r\nLeft stick: x=-1.0, y=0 Right stick: x=0, y=0\r\n['r2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l1']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['r1']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l1']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l2', 'r1', 'r2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l1', 'r1', 'r2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l1', 'r1', 'r2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['l1', 'r1']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['r2']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n['select']\r\nLeft stick: x=0, y=0 Right stick: x=0, y=0\r\n^CStopping Joystick test<\/code><\/pre>\n\n\n\n<p>Now the comms and ability to read inputs has been proven the more advanced examples can be checked. To fit in with existing code Id like to use button call-backs and the failover example to reconnect if it drops out of range. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>A few years back we bought a Pi Hut wireless controller at the fantastic Raspberry Fields, which I&#8217;m sad to say that despite the varied<\/p>\n","protected":false},"author":1,"featured_media":401,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[9,7],"tags":[],"class_list":["post-400","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-electronics","category-robot"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Remote Controller test - The Lemming Farm<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"http:\/\/www.thelemmingfarm.uk\/?p=400\" \/>\n<meta property=\"og:locale\" content=\"en_GB\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Remote Controller test - The Lemming Farm\" \/>\n<meta property=\"og:description\" content=\"A few years back we bought a Pi Hut wireless controller at the fantastic Raspberry Fields, which I&#8217;m sad to say that despite the varied\" \/>\n<meta property=\"og:url\" content=\"http:\/\/www.thelemmingfarm.uk\/?p=400\" \/>\n<meta property=\"og:site_name\" content=\"The Lemming Farm\" \/>\n<meta property=\"article:published_time\" content=\"2021-11-28T15:40:41+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-11-28T15:41:23+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"379\" \/>\n\t<meta property=\"og:image:height\" content=\"270\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"matt\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"matt\" \/>\n\t<meta name=\"twitter:label2\" content=\"Estimated reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#article\",\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400\"},\"author\":{\"name\":\"matt\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/#\\\/schema\\\/person\\\/ad3da4bf1895ba680ee4c6a0cdcfe5c3\"},\"headline\":\"Remote Controller test\",\"datePublished\":\"2021-11-28T15:40:41+00:00\",\"dateModified\":\"2021-11-28T15:41:23+00:00\",\"mainEntityOfPage\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400\"},\"wordCount\":331,\"image\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/20211128_133747.jpg\",\"articleSection\":[\"Electronics\",\"Robot\"],\"inLanguage\":\"en-GB\"},{\"@type\":\"WebPage\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400\",\"url\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400\",\"name\":\"Remote Controller test - The Lemming Farm\",\"isPartOf\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#primaryimage\"},\"image\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#primaryimage\"},\"thumbnailUrl\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/20211128_133747.jpg\",\"datePublished\":\"2021-11-28T15:40:41+00:00\",\"dateModified\":\"2021-11-28T15:41:23+00:00\",\"author\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/#\\\/schema\\\/person\\\/ad3da4bf1895ba680ee4c6a0cdcfe5c3\"},\"breadcrumb\":{\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#breadcrumb\"},\"inLanguage\":\"en-GB\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#primaryimage\",\"url\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/20211128_133747.jpg\",\"contentUrl\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/wp-content\\\/uploads\\\/2021\\\/11\\\/20211128_133747.jpg\",\"width\":379,\"height\":270},{\"@type\":\"BreadcrumbList\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?p=400#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Remote Controller test\"}]},{\"@type\":\"WebSite\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/#website\",\"url\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/\",\"name\":\"The Lemming Farm\",\"description\":\"An Entry to the Pi Wars Competition 2024\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-GB\"},{\"@type\":\"Person\",\"@id\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/#\\\/schema\\\/person\\\/ad3da4bf1895ba680ee4c6a0cdcfe5c3\",\"name\":\"matt\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-GB\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg\",\"caption\":\"matt\"},\"url\":\"http:\\\/\\\/www.thelemmingfarm.uk\\\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Remote Controller test - The Lemming Farm","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":"http:\/\/www.thelemmingfarm.uk\/?p=400","og_locale":"en_GB","og_type":"article","og_title":"Remote Controller test - The Lemming Farm","og_description":"A few years back we bought a Pi Hut wireless controller at the fantastic Raspberry Fields, which I&#8217;m sad to say that despite the varied","og_url":"http:\/\/www.thelemmingfarm.uk\/?p=400","og_site_name":"The Lemming Farm","article_published_time":"2021-11-28T15:40:41+00:00","article_modified_time":"2021-11-28T15:41:23+00:00","og_image":[{"width":379,"height":270,"url":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","type":"image\/jpeg"}],"author":"matt","twitter_card":"summary_large_image","twitter_misc":{"Written by":"matt","Estimated reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#article","isPartOf":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400"},"author":{"name":"matt","@id":"http:\/\/www.thelemmingfarm.uk\/#\/schema\/person\/ad3da4bf1895ba680ee4c6a0cdcfe5c3"},"headline":"Remote Controller test","datePublished":"2021-11-28T15:40:41+00:00","dateModified":"2021-11-28T15:41:23+00:00","mainEntityOfPage":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400"},"wordCount":331,"image":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#primaryimage"},"thumbnailUrl":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","articleSection":["Electronics","Robot"],"inLanguage":"en-GB"},{"@type":"WebPage","@id":"http:\/\/www.thelemmingfarm.uk\/?p=400","url":"http:\/\/www.thelemmingfarm.uk\/?p=400","name":"Remote Controller test - The Lemming Farm","isPartOf":{"@id":"http:\/\/www.thelemmingfarm.uk\/#website"},"primaryImageOfPage":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#primaryimage"},"image":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#primaryimage"},"thumbnailUrl":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","datePublished":"2021-11-28T15:40:41+00:00","dateModified":"2021-11-28T15:41:23+00:00","author":{"@id":"http:\/\/www.thelemmingfarm.uk\/#\/schema\/person\/ad3da4bf1895ba680ee4c6a0cdcfe5c3"},"breadcrumb":{"@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#breadcrumb"},"inLanguage":"en-GB","potentialAction":[{"@type":"ReadAction","target":["http:\/\/www.thelemmingfarm.uk\/?p=400"]}]},{"@type":"ImageObject","inLanguage":"en-GB","@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#primaryimage","url":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","contentUrl":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","width":379,"height":270},{"@type":"BreadcrumbList","@id":"http:\/\/www.thelemmingfarm.uk\/?p=400#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"http:\/\/www.thelemmingfarm.uk\/"},{"@type":"ListItem","position":2,"name":"Remote Controller test"}]},{"@type":"WebSite","@id":"http:\/\/www.thelemmingfarm.uk\/#website","url":"http:\/\/www.thelemmingfarm.uk\/","name":"The Lemming Farm","description":"An Entry to the Pi Wars Competition 2024","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"http:\/\/www.thelemmingfarm.uk\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-GB"},{"@type":"Person","@id":"http:\/\/www.thelemmingfarm.uk\/#\/schema\/person\/ad3da4bf1895ba680ee4c6a0cdcfe5c3","name":"matt","image":{"@type":"ImageObject","inLanguage":"en-GB","@id":"https:\/\/secure.gravatar.com\/avatar\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg","url":"https:\/\/secure.gravatar.com\/avatar\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/6384a0c4df2a2e69eff9a84163bce14869cb2bde2aa2d0757ccafb22cd711e2c?s=96&d=mm&r=pg","caption":"matt"},"url":"http:\/\/www.thelemmingfarm.uk\/?author=1"}]}},"jetpack_featured_media_url":"http:\/\/www.thelemmingfarm.uk\/wp-content\/uploads\/2021\/11\/20211128_133747.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/posts\/400","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=400"}],"version-history":[{"count":9,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/posts\/400\/revisions"}],"predecessor-version":[{"id":411,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/posts\/400\/revisions\/411"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=\/wp\/v2\/media\/401"}],"wp:attachment":[{"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=400"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=400"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.thelemmingfarm.uk\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=400"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}