{"id":3987,"date":"2015-01-02T21:53:31","date_gmt":"2015-01-02T21:53:31","guid":{"rendered":"http:\/\/www.haydnwilliams.com\/blog\/?p=3987"},"modified":"2022-04-11T21:32:28","modified_gmt":"2022-04-11T20:32:28","slug":"airpi-a-tentative-v1-0-release","status":"publish","type":"post","link":"https:\/\/www.haydnwilliams.com\/blog\/airpi-a-tentative-v1-0-release\/","title":{"rendered":"AirPi &#8211; a tentative v1.0 release"},"content":{"rendered":"<p>Earlier this year I forked the software used to control the <a title=\"AirPi Air Quality &amp; Weather Project (Official Site)\" href=\"http:\/\/airpi.es\" target=\"_blank\" rel=\"noopener\">AirPi<\/a>, a small board which fits a <a title=\"Raspberry Pi Foundation\" href=\"http:\/\/raspberrypi.org\/\" target=\"_blank\" rel=\"noopener\">Raspberry Pi<\/a> to monitor environmental phenomena such as temperature, humidity and air pressure along with air quality measures including Carbon Monoxide, Nitrogen Dioxide and <abbr title=\"Volatile Organic Compounds\">VOC<\/abbr>s. Having made quite a lot of changes, I&#8217;ve just tagged a <a title=\"haydnw &gt; AirPi &gt; Release v1.0 on GitHub\" href=\"https:\/\/github.com\/haydnw\/AirPi\/releases\/tag\/v1.0\" target=\"_blank\" rel=\"noopener\">v1.0 release<\/a> on <a title=\"haydnw &gt; AirPi on Github\" href=\"http:\/\/github.com\/haydnw\/AirPi\" target=\"_blank\" rel=\"noopener\">GitHub<\/a>, so thought it might be prudent to take a look at what&#8217;s been added and\/or amended.<\/p>\n<div id=\"attachment_3995\" style=\"width: 760px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-3995\" class=\"size-full wp-image-3995\" src=\"http:\/\/www.haydnwilliams.com\/blog\/wp-content\/uploads\/2015\/01\/2014-01-02c.jpg\" alt=\"The pride of the fleet - Model B+, and the AirPi has the GPS chip. #bling.\" width=\"750\" height=\"559\" \/><p id=\"caption-attachment-3995\" class=\"wp-caption-text\">The pride of the fleet &#8211; Model B+, and the AirPi has the GPS chip. #bling.<\/p><\/div>\n<p>The <a title=\"tomhartley &gt; AirPi on GitHub\" href=\"https:\/\/github.com\/tomhartley\/AirPi\" target=\"_blank\" rel=\"noopener\">original software<\/a> was released by one of the projects instigators, <a title=\"Tom Hartley on Twitter (tmhrtly)\" href=\"https:\/\/twitter.com\/tmhrtly\" target=\"_blank\" rel=\"noopener\">Tom Hartley<\/a>. This was forked by <a title=\"Fred Sonnenwald\" href=\"http:\/\/sonnenwald.co.uk\" target=\"_blank\" rel=\"noopener\">Fred Sonnenwald<\/a>\u00a0as part of the <a title=\"Pi.GATE.ac.uk Project\" href=\"http:\/\/pi.gate.ac.uk\" target=\"_blank\" rel=\"noopener\">pi.gate.ac.uk<\/a> project &#8211; he\u00a0added a number of useful features, not least of\u00a0which\u00a0was the web server to display figures and pretty charts.\u00a0I forked from <a title=\"guruthree &gt; AirPi on GitHub\" href=\"https:\/\/github.com\/guruthree\/AirPi\" target=\"_blank\" rel=\"noopener\">his work<\/a> because I needed to make a couple of tweaks, but they turned into a fairly major update.<\/p>\n<div id=\"attachment_3991\" style=\"width: 1104px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-3991\" class=\"size-full wp-image-3991\" src=\"http:\/\/www.haydnwilliams.com\/blog\/wp-content\/uploads\/2015\/01\/2015-01-02a.png\" alt=\"AirPi software - original release (left) vs. my v1.0 release (right).\" width=\"1094\" height=\"1043\" \/><p id=\"caption-attachment-3991\" class=\"wp-caption-text\">AirPi software &#8211; original release (left) vs. my v1.0 release (right).<\/p><\/div>\n<p>The original release of the software would read from sensors and either print the results to screen or send to a <a title=\"Xively\" href=\"http:\/\/xively.com\" target=\"_blank\" rel=\"noopener\">Xively<\/a> feed. At the end of 2013 the code was updated\u00a0so that sensors and outputs became modular. Fred Sonnenwald&#8217;s update added support for a number of new sensors (including the TGS2600 air quality sensor), output to CSV files,\u00a0the aforementioned HTTP output, and the ability to dial in calibration functions for individual sensors. The latter is particularly important, as the cheap nature of the sensors used by the AirPi mean there is great variability between individual instances of the same model even from the same production run. Fred did <a title=\"Interpreting AirPi sensor readings\" href=\"ate.ac.uk\/posts\/2014\/02\/25\/airpisensors\/\" target=\"_blank\" rel=\"noopener\">a great post<\/a> giving an initial look at interpreting readings from the AirPi.<\/p>\n<p>I stood on Tom and Fred&#8217;s shoulders, and added a number of other features, including:<\/p>\n<ul>\n<li>A host of &#8216;UI&#8217; improvements, either clarifying existing output or adding more information for users.<\/li>\n<li>Output plugins for Thingspeak, dweet, JSON, RRD and ASCII graphs.<\/li>\n<li>A &#8216;notification&#8217; system to send SMS, email or Tweet if an error occurs.<\/li>\n<li>Ability to start sampling automatically with no user interaction when the system boots.<\/li>\n<li>Record metadata with results.<\/li>\n<li>Control script to standardise different ways of running the software (and stopping it).<\/li>\n<li>Averaging, <em>i.e.<\/em> take readings every 10 seconds then average each set of six readings for a minute average.<\/li>\n<li>Full documentation and code\u00a0templates.<\/li>\n<\/ul>\n<p>Full details of all the changes can be found in the README.md file in the root of the repository, and there are now full usage instructions in the `docs` folder &#8211; see the file `usage.md` to get started.<\/p>\n<div id=\"attachment_3992\" style=\"width: 330px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-3992\" class=\"wp-image-3992\" src=\"http:\/\/www.haydnwilliams.com\/blog\/wp-content\/uploads\/2015\/01\/2015-01-02b.png\" alt=\"Convenient!\" width=\"320\" height=\"568\" \/><p id=\"caption-attachment-3992\" class=\"wp-caption-text\">Convenient!<\/p><\/div>\n<p>This commit was tagged as v1.0 because it&#8217;s now got in all of the features I need to support some ongoing work I&#8217;m doing with the <a title=\"Atmospheric Chemistry - University of Leicester\" href=\"http:\/\/www2.le.ac.uk\/departments\/chemistry\/research\/atmospheric-chemistry-1\">Atmospheric Chemistry group<\/a> at the University of Leicester. There are also some additional features which came about as a result of <a title=\"AirPi forum thread - Revised AirPi software\" href=\"http:\/\/airpi.freeforums.net\/thread\/147\/revised-airpi-software-features-averaging\" target=\"_blank\" rel=\"noopener\">a thread on the AirPi forum<\/a>\u00a0&#8211; thanks to participants there for ideas and bug reports. I won&#8217;t be adding any more new features at this point, but will be doing bug fixes and a bit of tidying, and probably\u00a0updating the code to Python3 at some point too.<\/p>\n<p>The next major piece of work is calibrating each of the three AirPis we have under standard conditions, so that we can create the custom calibration functions needed to convert the resistance readings into standard units such as <abbr title=\"parts per million\">ppm<\/abbr>. It&#8217;s absolutely my intention to keep updating the software and this blog with the results of that work, particularly as it reveals more about the responses of the individual sensors. For now, any questions or queries can be raised in the <a title=\"AirPi forum\" href=\"http:\/\/airpi.freeforums.net\/board\/1\/general-board\" target=\"_blank\" rel=\"noopener\">AirPi forum<\/a>, or by <a title=\"haydnw &gt; AirPi &gt; Issues on GitHub\" href=\"https:\/\/github.com\/haydnw\/AirPi\/issues\" target=\"_blank\" rel=\"noopener\">questions and bug reports on GitHub<\/a> too.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Earlier this year I forked the software used to control the AirPi, a small board which monitors air quality measures including Carbon Monoxide, Nitrogen Dioxide and VOCs. Having made quite a lot of changes I&#8217;ve just tagged a v1.0 release on GitHub, so thought it might be prudent to take a look at what&#8217;s been added and\/or amended.<\/p>\n","protected":false},"author":2,"featured_media":3995,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[1025,1023,1057,1022,1032,1024],"class_list":["post-3987","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-it","tag-air-quality","tag-airpi","tag-pollution","tag-raspberry-pi","tag-rpi","tag-weather-station"],"_links":{"self":[{"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/posts\/3987","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/comments?post=3987"}],"version-history":[{"count":0,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/posts\/3987\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/media\/3995"}],"wp:attachment":[{"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/media?parent=3987"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/categories?post=3987"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.haydnwilliams.com\/blog\/wp-json\/wp\/v2\/tags?post=3987"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}