{"id":394,"date":"2020-09-30T08:53:33","date_gmt":"2020-09-30T08:53:33","guid":{"rendered":"https:\/\/starthardware.org\/en\/?p=394"},"modified":"2020-09-30T12:57:30","modified_gmt":"2020-09-30T12:57:30","slug":"creepy-halloween-candy-dispenser-with-arduino","status":"publish","type":"post","link":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/","title":{"rendered":"Creepy Halloween candy dispenser with Arduino"},"content":{"rendered":"\n<p>In this project I show you how to build a Halloween candy dispenser with creepy factor with Arduino.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is a Halloween candy dispenser?<\/h2>\n\n\n\n<p>It&#8217;s Halloween and colorfully dressed ghosts are at the door. Usually someone comes out with a bowl of candy and the ghosts take their loot. But not this year! Instead of a bowl, visitors have to reach into the mouth of a creepy skull to get the rewards. But the skull opens its eyes and sprays creepy fog from its nose.<\/p>\n\n\n\n<p>Please also pay attention to my Corona hint at the end of this article.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"800\" height=\"450\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-animation.gif\" alt=\"Arduino creepy halloween candy dispenser animation\" class=\"wp-image-397\"\/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Components for electronics<\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>Arduino Set, Breadboard, Cable, etc.*<\/li><li>2x servo motor*<\/li><li>1x fog machine*<\/li><li>1x IR sensor*<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Functionality<\/h2>\n\n\n\n<p>If someone puts his hand into the mouth of the skull, it is registered by an infrared sensor. The eye sockets light up and the eyeballs turn forward. After a short time, a burst of fog sprays from the skull&#8217;s nose. When the hand is pulled out again, the eyes turn back again and the light switches off.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Halloween candy dispenser setup<\/h2>\n\n\n\n<p>Let&#8217;s start with the electronics. The project consists of two LEDs for lighting and a servo (<a href=\"https:\/\/starthardware.org\/en\/arduino-servo-motor-control\/\" target=\"_blank\" rel=\"noreferrer noopener\">More information about the servo motor<\/a>) for the movement of the eyes, a fog machine that is switched on by the servo motor and an IR sensor that detects movement in the skull&#8217;s mouth.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-1024x576.jpg\" alt=\"Arduino creepy halloween candy dispenser electronics\" class=\"wp-image-396\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-1024x576.jpg 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-300x169.jpg 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-768x432.jpg 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-800x450.jpg 800w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Trigger fog<\/h2>\n\n\n\n<p><br>A fog machine is an exciting device and I don&#8217;t want to destroy it for this project by cutting off cables somewhere. My alternative is a servo motor fixed to the release button with hot glue and a cable tie. If the servo is turned, it pushes the trigger down and the fog machine starts. If the servo is turned back, the machine stops again. But only assemble it after you have tested the code. The angle of rotation of the servos must fit to your setup.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo-1024x576.jpg\" alt=\"Arduino creepy halloween candy dispenser servo fog machine trigger \" class=\"wp-image-398\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo-1024x576.jpg 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo-300x169.jpg 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo-768x432.jpg 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo-800x450.jpg 800w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-servo.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Circuit<\/h2>\n\n\n\n<p>The circuit consists of two LEDs connected to GND on the cathode side (short legs) and to digital pin 7 of the Arduino on the anode side (long leg) via a 220 Ohm resistor. Two servo motors are connected to 5V+ and the GND. They receive their control signals via digital pins 2 and 3. The infrared sensor is also connected to 5V+ and the GND. It sends an analog signal to the analog input pin A0.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"765\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1-1024x765.png\" alt=\"Arduino creepy halloween candy dispenser circuit\" class=\"wp-image-405\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1-1024x765.png 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1-300x224.png 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1-768x574.png 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1-500x375.png 500w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-fog-machine-breadboard-circuit-1.png 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Code for the Halloween candy dispenser<\/h2>\n\n\n\n<p>To understand how the code works, let&#8217;s look at the loop of the candy dispenser code.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>void loop() {\n  Serial.println(analogRead(irPin));\n  if (analogRead(irPin) > irThreshold) {\n    eyesOn();\n    if ((fogTimer+fogTimeout&lt;millis())&amp;&amp;(fogDone==false)){\n        fog();\n        fogDone=true;\n    }\n  } else {\n    eyesOff();\n    fogTimer = millis();\n    fogDone = false;\n  }\n  delay(10);\n}<\/code><\/pre>\n\n\n\n<p>Through the if-query, the program waits until the IR sensor reports that someone has put his hand in the mouth. The switching limit (irThreshold) must still be set for this. Just test it out. In the Serial Monitor (baud rate 115200) you can display the values.<\/p>\n\n\n\n<p>So if the IR sensor is triggered, the method eyesOn() is called. It turns on the LEDs and turns the eyes forward.<\/p>\n\n\n\n<p>Now it is checked if the variable nebulaTimer plus the time the fog should spray (fogTimeout) has expired and if fog has been emitted before. If both are not the case, fog is released.<\/p>\n\n\n\n<p>If there is no hand in the mouth, the method eyesOff() is called. It turns the eyes backwards and switches off the LEDs. At the same time it resets the fogTimer and sets the variable fogDone to false.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#include &lt;Servo.h>\n\nint ledPin = 7;\nint servoEyesPin = 2;\nint servoFogPin = 3;\nint irPin = A0;\nint irThreshold = 300;    \/\/ threshold when a hand is close to the sensor\n\nlong fogTimer = 0;\nint fogTimeout = 2000;    \/\/ time until fog shall apear\n\nboolean fogDone = false;\n\nServo myServoEyes, myServoFog;\n\nvoid fog() {\n    delay(random(1000));\n    myServoFog.write(15);\n    delay(300);\n    myServoFog.write(0);\n}\n\nvoid eyesOn() {\n  if (millis()%4000&lt;10){    \n    digitalWrite(ledPin, LOW);\n    delay(100);\n    digitalWrite(ledPin, HIGH);\n    }\n  digitalWrite(ledPin, HIGH);\n  myServoEyes.write(180);\n}\n\nvoid eyesOff() {\n  digitalWrite(ledPin, LOW);\n  myServoEyes.write(0);\n}\n\nvoid setup() {\n  Serial.begin(115200);\n  myServoEyes.attach(servoEyesPin);\n  myServoFog.attach(servoFogPin);\n  pinMode(ledPin, OUTPUT);\n  myServoFog.write(0);\n  myServoEyes.write(0);\n}\n\nvoid loop() {\n  Serial.println(analogRead(irPin));\n  if (analogRead(irPin) > irThreshold) {\n    eyesOn();\n    if ((fogTimer+fogTimeout&lt;millis())&amp;&amp;(fogDone==false)){\n        fog();\n        fogDone=true;\n    }\n  } else {\n    eyesOff();\n    fogTimer = millis();\n    fogDone = false;\n  }\n  delay(10);\n}<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Structure of the project<\/h2>\n\n\n\n<p>I am very lucky to own a CNC machine. It is the Shapeoko MAX and I got it from https:\/\/myhobby-cnc.de. However, an jigsaw and some creativity is enough for the project. The layout files I have made available on Github (https:\/\/github.com\/StefanHermannBerlin\/Arduino-Halloween-2018).<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"768\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull-1024x768.jpg\" alt=\"Arduino creepy halloween candy dispenser scull\" class=\"wp-image-399\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull-1024x768.jpg 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull-300x225.jpg 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull-768x576.jpg 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull-500x375.jpg 500w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-f-mdf-scull.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>I milled out the reliefs and then painted everything black. Then I went over the surface with a varnishing roller and white varnish. This created a spotty effect, which I found quite nice.<\/p>\n\n\n\n<p>On the picture below you can see the structure. I got the eyes from the baking department in our supermarket, but a few painted table tennis balls are at least as good. The eyes are mounted on a M8 shaft. I glued a M8 nut to the axle of the servo with hot glue and it works pretty good. The two LEDs are glued under the eyes. They illuminate the eyes from below, which looks extra scary.<\/p>\n\n\n\n<p>The IR sensor is mounted in a plastic box directly above the upper teeth of the skull, looking down.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner-1024x576.jpg\" alt=\"Arduino creepy halloween candy dispenser upper box with electronics\" class=\"wp-image-400\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner-1024x576.jpg 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner-300x169.jpg 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner-768x432.jpg 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner-800x450.jpg 800w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-build-inner.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>I sawed the plastic box open at the back to put sweets in. It is screwed to the skull and offers stability for the assembly. On top of it is the fog machine, which blows fog through a hole in the back of the upper box through nose and eye sockets. (By the way, the white powerbank on top of the box in the picture is just for testing purposes).<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build-1024x576.jpg\" alt=\"Arduino creepy halloween candy dispenser assembled\" class=\"wp-image-402\" srcset=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build-1024x576.jpg 1024w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build-300x169.jpg 300w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build-768x432.jpg 768w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build-800x450.jpg 800w, https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-outer-build.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Attention! You should definitely test if the fog from your machine is too hot and if someone could be injured. With my fog machine the fog is rather cold.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Project as video<\/h2>\n\n\n\n<p>By the way, the project is also available as video. It is in German but good to see the steps of the build \ud83d\ude42<\/p>\n\n\n\n<figure class=\"wp-block-embed-youtube wp-block-embed is-type-video is-provider-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<div class=\"sp-dsgvo sp-dsgvo-embedding-container sp-dsgvo-embedding-youtube \"><div class=\"sp-dsgvo-blocked-embedding-placeholder sp-dsgvo-blocked-embedding-placeholder-youtube\">  <div class=\"sp-dsgvo-blocked-embedding-placeholder-header\"><img decoding=\"async\" class=\"sp-dsgvo-blocked-embedding-placeholder-header-icon\" src=\"https:\/\/starthardware.org\/en\/wp-content\/plugins\/shapepress-dsgvo\/public\/images\/embeddings\/icon-youtube.svg\"\/>We need your consent to load the content of YouTube.<\/div>  <div class=\"sp-dsgvo-blocked-embedding-placeholder-body\"><p>If you click on this video we will play the video, load scripts on your device, store cookies and collect personal data. This enables [Google Ireland Limited, Irland] to track activities on the Internet and to display advertising in a target group-oriented manner. There is a data transfer to the USA, which does not have EU-compliant data protection. You will find further information <a target=\"_blank\" href=\"#\" class=\"sp-dsgvo-navigate-privacy-policy\">here<\/a>.<\/p>   <div class=\"sp-dsgvo-blocked-embedding-button-container\"> <a href=\"#\" class=\"sp-dsgvo-direct-enable-popup sp-dsgvo-blocked-embedding-button-enable\" data-slug=\"youtube\">Click here to enable this content.<\/a><\/div>  <\/div><\/div><div class=\"sp-dsgvo-hidden-embedding-content sp-dsgvo-hidden-embedding-content-youtube\" data-sp-dsgvo-embedding-slug=\"youtube\">Jmx0O2RpdiBjbGFzcz0mcXVvdDtudi1pZnJhbWUtZW1iZWQmcXVvdDsmZ3Q7Jmx0O2lmcmFtZSB0aXRsZT0mcXVvdDtIYWxsb3dlZW4gbWl0IEFyZHVpbm8mcXVvdDsgd2lkdGg9JnF1b3Q7MTIwMCZxdW90OyBoZWlnaHQ9JnF1b3Q7Njc1JnF1b3Q7IHNyYz0mcXVvdDtodHRwczovL3d3dy55b3V0dWJlLmNvbS9lbWJlZC9FTGdfeTNiZmZjUT9mZWF0dXJlPW9lbWJlZCZxdW90OyBmcmFtZWJvcmRlcj0mcXVvdDswJnF1b3Q7IGFsbG93PSZxdW90O2FjY2VsZXJvbWV0ZXI7IGF1dG9wbGF5OyBjbGlwYm9hcmQtd3JpdGU7IGVuY3J5cHRlZC1tZWRpYTsgZ3lyb3Njb3BlOyBwaWN0dXJlLWluLXBpY3R1cmUmcXVvdDsgYWxsb3dmdWxsc2NyZWVuJmd0OyZsdDsvaWZyYW1lJmd0OyZsdDsvZGl2Jmd0Ow==<\/div><\/div>\n<\/div><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Corona note<\/h2>\n\n\n\n<p>This year everything is a bit crazy and I don&#8217;t know if we will see any Halloween visitors at all. But in order not to endanger them, I recommend &#8211; no, I&#8217;m not a virologist &#8211; to spray the box with disinfectant after each group of visitors and put a clean bowl of new candy in it. On the other hand, the Halloween candy dispenser at least doesn&#8217;t get you too close to other people.<\/p>\n\n\n\n<p>I hope you have as much fun with the build as I did and finally a reason to get yourself a fog machine. If you have any questions, feel free to ask in the comments here.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this project I show you how to build a Halloween candy dispenser with creepy factor with Arduino. What is a Halloween candy dispenser? It&#8217;s Halloween and colorfully dressed ghosts are at the door. Usually someone comes out with a bowl of candy and the ghosts take their loot. But not this year! Instead of&hellip;&nbsp;<a href=\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/\" class=\"\" rel=\"bookmark\">Read More &raquo;<span class=\"screen-reader-text\">Creepy Halloween candy dispenser with Arduino<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":401,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"neve_meta_sidebar":"","neve_meta_container":"","neve_meta_enable_content_width":"","neve_meta_content_width":0,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":"","footnotes":""},"categories":[5],"tags":[],"class_list":["post-394","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-arduino-projects"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v18.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Let&#039;s build a Creepy Halloween candy dispenser with Arduino<\/title>\n<meta name=\"description\" content=\"How about a creepy Halloween candy dispenser with fog and light this year? I&#039;ll show you how to build it and program it. Let&#039;s go!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Let&#039;s build a Creepy Halloween candy dispenser with Arduino\" \/>\n<meta property=\"og:description\" content=\"How about a creepy Halloween candy dispenser with fog and light this year? I&#039;ll show you how to build it and program it. Let&#039;s go!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/\" \/>\n<meta property=\"og:site_name\" content=\"StartHardware - Tutorials for Arduino\" \/>\n<meta property=\"article:published_time\" content=\"2020-09-30T08:53:33+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-09-30T12:57:30+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"675\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Stefan Hermann\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/starthardware.org\/en\/#website\",\"url\":\"https:\/\/starthardware.org\/en\/\",\"name\":\"StartHardware - Tutorials for Arduino\",\"description\":\"Arduino, Electronics, Fun\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/starthardware.org\/en\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg\",\"contentUrl\":\"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg\",\"width\":1200,\"height\":675,\"caption\":\"Arduino creepy halloween candy dispenser\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#webpage\",\"url\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/\",\"name\":\"Let's build a Creepy Halloween candy dispenser with Arduino\",\"isPartOf\":{\"@id\":\"https:\/\/starthardware.org\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#primaryimage\"},\"datePublished\":\"2020-09-30T08:53:33+00:00\",\"dateModified\":\"2020-09-30T12:57:30+00:00\",\"author\":{\"@id\":\"https:\/\/starthardware.org\/en\/#\/schema\/person\/811b16fabcbfeef4210ea79cf0990a59\"},\"description\":\"How about a creepy Halloween candy dispenser with fog and light this year? I'll show you how to build it and program it. Let's go!\",\"breadcrumb\":{\"@id\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/starthardware.org\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Creepy Halloween candy dispenser with Arduino\"}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/starthardware.org\/en\/#\/schema\/person\/811b16fabcbfeef4210ea79cf0990a59\",\"name\":\"Stefan Hermann\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/starthardware.org\/en\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/5b5a74ee1d07024fd1eff9b1f7137108089169010a93afaee907b9325ee579a6?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/5b5a74ee1d07024fd1eff9b1f7137108089169010a93afaee907b9325ee579a6?s=96&d=mm&r=g\",\"caption\":\"Stefan Hermann\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Let's build a Creepy Halloween candy dispenser with Arduino","description":"How about a creepy Halloween candy dispenser with fog and light this year? I'll show you how to build it and program it. Let's go!","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:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/","og_locale":"en_US","og_type":"article","og_title":"Let's build a Creepy Halloween candy dispenser with Arduino","og_description":"How about a creepy Halloween candy dispenser with fog and light this year? I'll show you how to build it and program it. Let's go!","og_url":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/","og_site_name":"StartHardware - Tutorials for Arduino","article_published_time":"2020-09-30T08:53:33+00:00","article_modified_time":"2020-09-30T12:57:30+00:00","og_image":[{"width":1200,"height":675,"url":"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg","type":"image\/jpeg"}],"twitter_card":"summary_large_image","twitter_misc":{"Written by":"Stefan Hermann","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebSite","@id":"https:\/\/starthardware.org\/en\/#website","url":"https:\/\/starthardware.org\/en\/","name":"StartHardware - Tutorials for Arduino","description":"Arduino, Electronics, Fun","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/starthardware.org\/en\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"ImageObject","@id":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#primaryimage","inLanguage":"en-US","url":"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg","contentUrl":"https:\/\/starthardware.org\/en\/wp-content\/uploads\/2020\/09\/arduino-halloween-candy-dispenser-title.jpg","width":1200,"height":675,"caption":"Arduino creepy halloween candy dispenser"},{"@type":"WebPage","@id":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#webpage","url":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/","name":"Let's build a Creepy Halloween candy dispenser with Arduino","isPartOf":{"@id":"https:\/\/starthardware.org\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#primaryimage"},"datePublished":"2020-09-30T08:53:33+00:00","dateModified":"2020-09-30T12:57:30+00:00","author":{"@id":"https:\/\/starthardware.org\/en\/#\/schema\/person\/811b16fabcbfeef4210ea79cf0990a59"},"description":"How about a creepy Halloween candy dispenser with fog and light this year? I'll show you how to build it and program it. Let's go!","breadcrumb":{"@id":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/starthardware.org\/en\/creepy-halloween-candy-dispenser-with-arduino\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/starthardware.org\/en\/"},{"@type":"ListItem","position":2,"name":"Creepy Halloween candy dispenser with Arduino"}]},{"@type":"Person","@id":"https:\/\/starthardware.org\/en\/#\/schema\/person\/811b16fabcbfeef4210ea79cf0990a59","name":"Stefan Hermann","image":{"@type":"ImageObject","@id":"https:\/\/starthardware.org\/en\/#personlogo","inLanguage":"en-US","url":"https:\/\/secure.gravatar.com\/avatar\/5b5a74ee1d07024fd1eff9b1f7137108089169010a93afaee907b9325ee579a6?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/5b5a74ee1d07024fd1eff9b1f7137108089169010a93afaee907b9325ee579a6?s=96&d=mm&r=g","caption":"Stefan Hermann"}}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/posts\/394","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/comments?post=394"}],"version-history":[{"count":2,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/posts\/394\/revisions"}],"predecessor-version":[{"id":406,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/posts\/394\/revisions\/406"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/media\/401"}],"wp:attachment":[{"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/media?parent=394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/categories?post=394"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/starthardware.org\/en\/wp-json\/wp\/v2\/tags?post=394"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}