<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Micropython on falkp.no/blog</title>
    <link>/blog/tags/micropython/</link>
    <description>falkp.no/blog (Micropython)</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    
      

      
    

    
    <lastBuildDate>Wed, 01 Apr 2020 00:00:00 +0000</lastBuildDate>
    
    <atom:link href="/blog/tags/micropython/index.xml" rel="self" type="application/rss+xml" />
    
    
    <item>
      <title>Non-invasive graphing of energy usage</title>
      <link>/blog/posts/non_invasive_graphing_of_energy_usage/</link>
      <pubDate>Wed, 01 Apr 2020 00:00:00 +0000</pubDate>
      
      <guid>/blog/posts/non_invasive_graphing_of_energy_usage/</guid>
      <description>&lt;p&gt;&amp;ldquo;If you can&amp;rsquo;t measure it, you can&amp;rsquo;t improve it.&amp;rdquo;&lt;/p&gt;
&lt;p&gt;Reducing energy usage is hard if you can&amp;rsquo;t see it. Here&amp;rsquo;s a cheap way to graph home or office energy usage.&lt;/p&gt;
&lt;p&gt;By reading data from the energy meter, one can get super accurate, real-time usage data.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;energy.png&#34; alt=&#34;Energy graph&#34;&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve used:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;A smart home controller, &lt;a href=&#34;https://www.home-assistant.io/&#34;&gt;Home Assistant&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;A graphing system, &lt;a href=&#34;https://grafana.com/&#34;&gt;Grafana&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;A micro controller, &lt;a href=&#34;https://en.wikipedia.org/wiki/ESP8266&#34;&gt;esp8266&lt;/a&gt;, ~$5&lt;/li&gt;
&lt;li&gt;An &lt;a href=&#34;https://en.wikipedia.org/wiki/Photoresistor&#34;&gt;LDR sensor&lt;/a&gt;, $1&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You need some familiarity with all of the above to set this up.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s my energy meter:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;installation.jpg&#34; alt=&#34;Energy meter&#34;&gt;&lt;/p&gt;
&lt;p&gt;It doesn&amp;rsquo;t matter which one you have, as long as it has a LED that blinks each X kWh used. I&amp;rsquo;ve written software for the esp8266 in &lt;a href=&#34;http://micropython.org/&#34;&gt;MicroPython&lt;/a&gt;, called &lt;a href=&#34;https://gitlab.com/larsfp/esp_energy_meter&#34;&gt;esp_energy_meter&lt;/a&gt;, that measures the time between each blink. It works great, and I&amp;rsquo;ve had it running for several locations for years. See the gitlab repo for more info on setup.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;hass.png&#34; alt=&#34;In home assistant&#34;&gt;&lt;/p&gt;
&lt;p&gt;When you have this set up, you can combine it with real-time energy prices to get full control of your energy usage. And then it&amp;rsquo;s time to adjust your usage based on pricing. =)&lt;/p&gt;
</description>
    </item>
    
  </channel>
</rss>
