{"id":242,"date":"2020-11-10T15:59:56","date_gmt":"2020-11-10T15:59:56","guid":{"rendered":"https:\/\/jadijkstra.nl\/?p=242"},"modified":"2020-11-10T15:59:58","modified_gmt":"2020-11-10T15:59:58","slug":"keeping-arduino-based-projects-running-on-a-powerbank","status":"publish","type":"post","link":"https:\/\/jadijkstra.nl\/index.php\/2020\/11\/10\/keeping-arduino-based-projects-running-on-a-powerbank\/","title":{"rendered":"Keeping Arduino based projects running on a powerbank"},"content":{"rendered":"\n<p>To keep Arduino Based projects running on a powerbank, you will need something to generate load every now and then to keep the powerbank powered on.<\/p>\n\n\n\n<p>This can be achieved by connecting 2 resistors and 1 mosfet to you\u2019re Arduino based project.<\/p>\n\n\n\n<p>With a little program, you can keep the powerbank on forever (at least for the time the battery is not drained)<\/p>\n\n\n\n<p>Code example:<\/p>\n\n\n\n<p>void setup() {<br>\/\/ put your setup code here, to run once:<br>pinMode(12, OUTPUT);<br>}<\/p>\n\n\n\n<p>void loop() {<br>\/\/ put your main code here, to run repeatedly:<br>digitalWrite(12, HIGH);<br>delay(500);<br>digitalWrite(12, LOW);<br>delay(5000);<br>}<\/p>\n\n\n\n<p>Here some pictures of a real life situation (just for testing purposes) and it works great!<\/p>\n\n\n\n<p>Here are the parts connected:<\/p>\n\n\n\n<p>This is the \u201cnormal load\u201d of the project:<\/p>\n\n\n\n<p>And this is the load generated by the resistors and the mosfet:<\/p>\n\n\n\n<p>I used the following components:<\/p>\n\n\n\n<p>1 resistor 66 ohm<br>1 resistor 1K ohm<br>1 Mosfet NPN 2N2222<\/p>\n\n\n\n<p>Combining it to:<\/p>\n","protected":false},"excerpt":{"rendered":"<p>To keep Arduino Based projects running on a powerbank, you will need something to generate load every now and then to keep the powerbank powered on. This can be achieved by connecting 2 resistors and 1 mosfet to you\u2019re Arduino based project. With a little program, you can keep the powerbank on forever (at least [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/posts\/242"}],"collection":[{"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/comments?post=242"}],"version-history":[{"count":1,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/posts\/242\/revisions"}],"predecessor-version":[{"id":243,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/posts\/242\/revisions\/243"}],"wp:attachment":[{"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/media?parent=242"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/categories?post=242"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jadijkstra.nl\/index.php\/wp-json\/wp\/v2\/tags?post=242"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}