{"id":423,"date":"2012-02-28T16:58:01","date_gmt":"2012-02-28T21:58:01","guid":{"rendered":"https:\/\/blogs.mathworks.com\/seth\/?p=423"},"modified":"2017-05-04T08:47:12","modified_gmt":"2017-05-04T13:47:12","slug":"sous-vide-cooking-with-simulink-part-2","status":"publish","type":"post","link":"https:\/\/blogs.mathworks.com\/simulink\/2012\/02\/28\/sous-vide-cooking-with-simulink-part-2\/","title":{"rendered":"Sous-vide Cooking with Simulink Part 2"},"content":{"rendered":"Here is the continuation of my sous-vide cooking story I began to tell in <a href=\"https:\/\/blogs.mathworks.com\/seth\/2012\/02\/21\/sous-vide-cooking-with-simulink-part-1\/\">the last post<\/a>.\r\n\r\n<strong>Hardware Implementation<\/strong>\r\n\r\nAs described last week, I finally received everything I ordered:\r\n<ul>\r\n \t<li><a href=\"http:\/\/arduino.cc\/en\/Main\/ArduinoBoardUno\">Arduino Uno<\/a> microcontroller<\/li>\r\n \t<li>LM35 temperature sensor<\/li>\r\n \t<li><a href=\"http:\/\/powerswitchtail.com\">PowerSwitch Tail<\/a><\/li>\r\n<\/ul>\r\nI dusted off my soldering iron and soldered a cable to the LM35. Then I dipped the extremity into silicone to make it waterproof. With everything connected to the Arduino, my circuit looks like this:\r\n\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/seth\/2012Q1\/finalCircuit.JPG\" alt=\"Schematic of my sous-vide setup\" \/>\r\n\r\nYeah... I know, a Tupperware is not the best container for a micro-controller. But I thought it would help avoiding to drop water on the Arduino.\r\n\r\n<strong>Software Implementation<\/strong>\r\n\r\nWith everything connected to the Arduino, all that remained was to program a controller. I installed the <a href=\"https:\/\/www.mathworks.com\/matlabcentral\/fileexchange\/30277-embedded-coder-target-for-arduino\">Simulink Support Package for Arduino<\/a>.\r\n\r\n<em><strong>Update:<\/strong> This model was created using MATLAB R2011b. Since R2012a Simulink provides built-in support for prototyping, testing, and running models on low-cost target hardware, including Arduino\u00ae, LEGO\u00ae MINDSTORMS\u00ae NXT, and BeagleBoard.<\/em>\r\n\r\nWithin just a few minutes, I created the following model and uploaded it on the Arduino:\r\n\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/seth\/2012Q1\/SousVidetargetModel.png\" alt=\"Simulink model of the Arduino controller\" \/>\r\n\r\nWhile this is running on the target, I can monitor the process on my PC using another model:\r\n\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/seth\/2012Q1\/SousVideHostModel.png\" alt=\"Simulink model of the Arduino controller\" \/>\r\n\r\n<strong>Cooking Time<\/strong>\r\n\r\nI mixed a nice <a href=\"http:\/\/bbq.about.com\/od\/rubrecipes\/tp\/aatp042607a.htm\">rub<\/a> and vacuum-sealed a bunch of pork ribs.\r\n\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/seth\/2012Q1\/Ribs_small.jpg\" alt=\"Vacuum sealed pork ribs\" \/>\r\n\r\nI left them to cook for 24 hours at 140 degrees Fahrenheit.\r\n\r\n<img decoding=\"async\" src=\"https:\/\/blogs.mathworks.com\/images\/seth\/2012Q1\/FullSetup_sma.jpg\" alt=\"My ribs cooking\" \/>\r\n\r\nI was so excited when it was time to take them out that I forgot to take pictures. I put them in the oven at broil for 2 minutes, just to give a little crunch on the top.\r\n\r\nBelieve me... that was totally worth the effort. Next time I'll try the 72 hours brisket!\r\n\r\n<strong>Now it's your turn<\/strong>\r\n\r\nDo you use Simulink on the weekend? What is your most unexpected usage of Simulink? Leave a <a href=\"https:\/\/blogs.mathworks.com\/seth\/?p=362&amp;#comment\">comment here<\/a>.","protected":false},"excerpt":{"rendered":"<p>Here is the continuation of my sous-vide cooking story I began to tell in the last post.\r\n\r\nHardware Implementation\r\n\r\nAs described last week, I finally received everything I ordered:\r\n\r\n \tArduino... <a class=\"read-more\" href=\"https:\/\/blogs.mathworks.com\/simulink\/2012\/02\/28\/sous-vide-cooking-with-simulink-part-2\/\">read more >><\/a><\/p>","protected":false},"author":41,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[115,71,67,24],"tags":[253,255],"_links":{"self":[{"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/posts\/423"}],"collection":[{"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/users\/41"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/comments?post=423"}],"version-history":[{"count":22,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/posts\/423\/revisions"}],"predecessor-version":[{"id":6539,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/posts\/423\/revisions\/6539"}],"wp:attachment":[{"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/media?parent=423"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/categories?post=423"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.mathworks.com\/simulink\/wp-json\/wp\/v2\/tags?post=423"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}