{"id":5285,"date":"2022-09-07T13:42:17","date_gmt":"2022-09-07T17:42:17","guid":{"rendered":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/?p=5285"},"modified":"2022-09-07T13:42:18","modified_gmt":"2022-09-07T17:42:18","slug":"servo-pico-hw","status":"publish","type":"post","link":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/2022\/09\/07\/servo-pico-hw\/","title":{"rendered":"Servo Pico Hw"},"content":{"rendered":"\n<h1><\/h1>\n\n\n\n<p>My version of this assignment is meant to simulate the actions of a cat. The process follows the cat walking normally when not alert, seeing a mouse scurry by, then getting ready to pounce on it. <\/p>\n\n\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\n#initial pause\ntime.sleep(2.0)\n\n# cat walking (not alert)\nprint(&quot;walking while not alert&quot;)\nringing_move(servo, 45.0, duration = 4)\ntime.sleep(1.5)\nringing_move(servo, 45.0, duration = 2)\n# cat takes a pause to stare at something\ntime.sleep(2.0)\n\n# cat's eyes follow mouse running by\nprint(&quot;Target found&quot;)\nlinear_move(servo, 180.0, 25.0, speed=45)\n\n# brief pause; stillness is the counterpoint\ntime.sleep(1.0)\n\n# start bouncy oscillation movements\nprint(&quot;Wiggling to adjust pounce direction&quot;)\nringing_move(servo, 25.0, duration=1.5)\nringing_move(servo, 35.0, duration=1.5)\nringing_move(servo, 40.0, duration=1.5)\n\ntime.sleep(5.0)\n<\/pre>","protected":false},"excerpt":{"rendered":"<p>My version of this assignment is meant to simulate the actions of a cat. The process follows the cat walking normally when not alert, seeing a mouse scurry&#8230;<\/p>\n","protected":false},"author":54,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/posts\/5285"}],"collection":[{"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/users\/54"}],"replies":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/comments?post=5285"}],"version-history":[{"count":1,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/posts\/5285\/revisions"}],"predecessor-version":[{"id":5286,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/posts\/5285\/revisions\/5286"}],"wp:attachment":[{"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/media?parent=5285"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/categories?post=5285"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/16-223\/f2022\/work\/wp-json\/wp\/v2\/tags?post=5285"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}