Air quality in home automation AppHomeKit via Homebridge

2 minutes of reading
Guide purposes
  • Equip the profirst home automation AppHomeKit air quality sensors via the Home pluginbridge "homebridge-airnow"
  • Difficulty level: bass
Concepts dealt with:
  • Software installation and configuration
Software components used:
Prerequisites
Physical devices used:
GUIDE more indicated for:

Apple-200x200

Notes and disclaimer
  • qualsiasi modifica all'impianto elettrico dev'essere progettata ed effettuata da personale qualificato;
  • any changes implemented in probefore is a propersonal responsibility as well as a profirst risk and danger (the contents of the present page are purely educational);
  • any changes implemented in proprior to a device it voids the guarantee, quality approvals and certifications.

Abstract

AIR-QUALITY-CONTROL-2"homebridge-airnow”Is a plugin created to equip the profirst personal home automation based on Homebridge of one or more virtual air quality sensors. This virtual sensor draws on the data from two websites which collect the data of inquisnameof thousands of detection units present on the earth globe.

It will therefore be sufficient to identify the control unit closest to our home automation environment, appjoin the coordinates (we will see in the article how) and configure this data in the Home configuration filebridge.
Obviously, this survey will be considered as a sample and not punctual.

Installation

Installation, like all plugins - is very simple.

Run the following command - on unix-based systems (linux, Raspberry etc.) from the terminal, from systems windows su procommand mpt:

npm install -g homebridge-airnow

and wait for the end of proprocedure.
Nb. In case Homebridge is already running as a service (as described in our installation guides), prosee to interrupt it before installing using the command:

sudo systemctl stop homebridge

Configuration

The plugin configuration includes the addition to the Home configuration filebridge of one or more accessories configured as follows:

"accessories": [
   {
   "accessory": "airnow",
   "name": "AirNow",
   "provider": "airnow",
   "airnow_api": "XXXXXX",
   "zipcode": "02860",
   "distance": "25",
   "aqicn_api": "XXXXXX",
   "aqicn_city": "@245",
   "polling": "30"
   }
]

Explanation of the fields.

FieldDescription
accessoryRequired - Must necessarily be "airnow" (all lower case).
nameRequired - Name of the accessory
proemptyRequired - Name of the data source, which can be: airnow, aqicn. The default is airnow.
airnow_apiOptional - Required for AirNow.gov. Indicates YOUR KEY API provided through registration and request on the site. AirNow only lists the US stations.
zipcodeOptional - Required and required for AirNow. This is the ZIP code of the surveyed geographical area.
distanceOptional - Required for AirNow - The range of the control unit. The default is 25 miles.
aqicn_apiOptional - Required for Aqicn.org. Indicates YOUR KEY API provided through registration and request on the site. Aqicn surveys the whole world, including Europe.
aqicn_cityOptional - Used only by Aqicn.org. It is used to indicate the code of the specific ECU from which you want to draw, obtained from http://aqicn.org/city/all. It is possible to alternatively indicate "here", which will use the geolocation obtained through the IP of the Home installationbridge and choose the nearest ECU.

The @code code of aqicn_city in the following example is from Reseda, in Los Angeles, is @245. Just place the mouse on the name of the city / control unit and display the code number at the bottom left of the browser.

Aqicn - City choice

PollingOptional - Census interval, in minutes. The default is 0, or off, no automatic census. The recommended value is 30.

utilization

accessory appare on HomeKit like an air quality sensor. It can be used with automations typical of the domotic environment Appthem.

This slideshow requires JavaScript.

Update Searchnamento

To update the package is sufficient execute the following command:

sudo npm update -g -dev homebridge-airnow

having previously taken care of having stopped any Home executionsbridge in progress.


Logo Appthe HomeKitsATTENZIONE: remember that there is on our FORUM community an ad hoc section dedicated to Appthe Homekits, for any doubt, question, information on the specific merit of these components.


Please comment below