{"id":10401,"date":"2015-06-09T16:06:54","date_gmt":"2015-06-09T20:06:54","guid":{"rendered":"http:\/\/embedded-lab.com\/blog\/?p=10401"},"modified":"2015-06-09T16:07:27","modified_gmt":"2015-06-09T20:07:27","slug":"555-timer-power-usage-sensor","status":"publish","type":"post","link":"https:\/\/embedded-lab.com\/blog\/555-timer-power-usage-sensor\/","title":{"rendered":"555 Timer as power usage sensor"},"content":{"rendered":"<p>Electricity meters usually have blinking LED lights whose flashing rate is associated with the amount of energy usage. This <a href=\"https:\/\/github.com\/dkroeske\/emon-server\" target=\"_blank\"><strong>example<\/strong><\/a> shows how to use a\u00a0555 timer chip acting as\u00a0Schmitt trigger\u00a0combined with a phototransistor or LDR to sense the flashing LED on the electricity meter for monitoring electricity usage.<\/p>\n<div id=\"attachment_10402\" style=\"width: 560px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/embedded-lab.com\/blog\/?attachment_id=10402\" rel=\"attachment wp-att-10402\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-10402\" class=\"size-medium wp-image-10402\" alt=\"555 timer as power meter\" src=\"http:\/\/embedded-lab.com\/blog\/wp-content\/uploads\/2015\/06\/emon-550x260.jpg\" width=\"550\" height=\"260\" srcset=\"https:\/\/embedded-lab.com\/blog\/wp-content\/uploads\/2015\/06\/emon-550x260.jpg 550w, https:\/\/embedded-lab.com\/blog\/wp-content\/uploads\/2015\/06\/emon.jpg 736w\" sizes=\"auto, (max-width: 550px) 100vw, 550px\" \/><\/a><p id=\"caption-attachment-10402\" class=\"wp-caption-text\">555 timer as power meter<\/p><\/div>\n<blockquote><p>The output of the 555 timer chip is connected to one of the GPIO pins on the Raspberry Pi. A Python script (executing in the background) recording 555 events is calculating actual energy usage [e.g. Watt] every time the 555 is signaling and stores epochs in an SQLite3 database. From this, another Python script (executed from e.g. cron) generates all kinds of energy usage information (e.g. kWh or kWday or whatever). Using Node.js (running on the same Pi) all data is \u2018RESTified\u2019 enabling spreading out to the W3. To maintain privacy JSON web tokens are required every time the service is queried. Oh, and there is also a\u00a0<a href=\"http:\/\/www.pimatic.org\/\">Pimatic<\/a>\u00a0plugin available (<a href=\"https:\/\/github.com\/dkroeske\/pimatic-emon\">here<\/a>)<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Electricity meters usually have blinking LED lights whose flashing rate is associated with the amount of energy usage. This example shows how to use a\u00a0555 timer chip acting as\u00a0Schmitt trigger\u00a0combined with a phototransistor or LDR to sense the flashing LED on the electricity meter for monitoring electricity usage. The output of the 555 timer chip is connected to one of the GPIO pins on the Raspberry Pi. A Python script (executing in the background) recording 555 events is calculating actual energy usage [e.g. Watt] every time the 555 is signaling and stores epochs in an SQLite3 database. From this, another<\/p>\n","protected":false},"author":1,"featured_media":10402,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[201],"tags":[1196,1197,138],"class_list":["post-10401","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-555-timer","tag-555-project","tag-electricity-usage","tag-power-meter"],"_links":{"self":[{"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/posts\/10401","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/comments?post=10401"}],"version-history":[{"count":2,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/posts\/10401\/revisions"}],"predecessor-version":[{"id":10404,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/posts\/10401\/revisions\/10404"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/media\/10402"}],"wp:attachment":[{"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/media?parent=10401"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/categories?post=10401"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/embedded-lab.com\/blog\/wp-json\/wp\/v2\/tags?post=10401"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}