{"id":542,"date":"2015-03-19T11:59:12","date_gmt":"2015-03-19T11:59:12","guid":{"rendered":"http:\/\/www.lancaster.ac.uk\/myclasp\/?p=542"},"modified":"2015-03-19T14:10:43","modified_gmt":"2015-03-19T14:10:43","slug":"3d-sleep","status":"publish","type":"post","link":"https:\/\/www.lancaster.ac.uk\/myclasp\/3d-sleep\/","title":{"rendered":"FitBit 3D Sleep"},"content":{"rendered":"<p>At the clasp kick-off, <a href=\"http:\/\/www.lancaster.ac.uk\/myclasp\/moodcons\/\">where we explored &#8220;moodcons&#8221; and constructing our own physical representations of sleep data <\/a>we showed some exploratory work in automatically generating and 3D printing these. The code for generating these is a little &#8220;hacky&#8221; but shared here in case somebody would like to reuse it.<\/p>\n<p>A few of us wear <a href=\"https:\/\/www.fitbit.com\/\">FitBit fitness trackers<\/a>, these also monitor quality of sleep. Here we used the <a href=\"https:\/\/dev.fitbit.com\/\">FitBit API<\/a> to grab the user&#8217;s sleep data for last night and then use some <a href=\"http:\/\/shapejs.shapeways.com\/\">ShapeJS code<\/a> to generate the models. A company called <a href=\"http:\/\/www.shapeways.com\/\">Shapeways, a US based 3D printing bureau<\/a> developed ShapeJS for generating custom 3D models for 3D printing. They released the ShapeJS &#8220;engine&#8221;, <a href=\"http:\/\/abfab3d.com\/\">AbFab3D<\/a> to <a href=\"https:\/\/github.com\/AbFab3D\/AbFab3D\">the community<\/a>. Until the next revision of AbFab3D, the only way to produce a model in shapeJS is to use the <a href=\"http:\/\/shapejs.shapeways.com\/creator\">Shapeways creator website<\/a>.<\/p>\n<p>So the application has a cut and paste step, but in future it should be possible for us to run an AbFab3D server and have the process seamless -&gt; login with FitBit and download \/ send the model for print automatically. When this is sorted I&#8217;ll host it and open it up for public use, but for now <a href=\"https:\/\/github.com\/myclasp\/3DSleep\/\">my experimental code and instructions are shared over on our github account<\/a>.<\/p>\n<div class=\"video-container\"><iframe loading=\"lazy\" width=\"733\" height=\"550\" src=\"https:\/\/www.youtube.com\/embed\/lRcQeofR8v8?feature=oembed\" frameborder=\"0\" allowfullscreen><\/iframe><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Some exploratory work in automatically generating and 3D printing representations of sleep data though the FitBit API and ShapeJS.<\/p>\n","protected":false},"author":3,"featured_media":541,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36,31,12],"tags":[],"class_list":["post-542","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-3d-viz","category-code","category-workshop","np_content_flags-featured-home","np_content_flags-show-featured-image"],"_links":{"self":[{"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/posts\/542","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/comments?post=542"}],"version-history":[{"count":10,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/posts\/542\/revisions"}],"predecessor-version":[{"id":553,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/posts\/542\/revisions\/553"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/media\/541"}],"wp:attachment":[{"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/media?parent=542"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/categories?post=542"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.lancaster.ac.uk\/myclasp\/wp-json\/wp\/v2\/tags?post=542"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}