Apache License 2.0

项目介绍

Hypfer/esp8266-vindriktning-particle-sensor 是一个托管在 GitHub 上的开源项目,主要使用 C++ 编写,采用 Apache License 2.0 许可证,目前获得 1.2k 个 Star、115 次 Fork。

仓库全名
Hypfer/esp8266-vindriktning-particle-sensor
开源许可证
Apache License 2.0
Star 数
1.2k
Fork 数
115
未关闭 Issue
28

README 摘要

MQTT connectivity for the Ikea VINDRIKTNING This repository contains an ESP8266 firmware, which adds MQTT to the Ikea VINDRIKTNING PM2.5 air quality sensor. The modification doesn't interfere with normal operation of the device in any way. The ESP8266 just adds another data sink beside the colored LEDs. Home Assistant Autodiscovery is supported. Furthermore, the WifiManager library is used for on-the-fly…

完整内容见 GitHub 原始 README 或本页 。

常见问题

esp8266-vindriktning-particle-sensor 用什么语言开发?

主要使用 C++ 编写,采用 Apache License 2.0 许可证,目前有 1.2k 个 Star。

esp8266-vindriktning-particle-sensor 可以免费商用吗?

仓库采用 Apache License 2.0 许可证,可免费使用与修改,商业使用请遵守许可证条款(例如保留版权声明与许可声明)。

如何获取 esp8266-vindriktning-particle-sensor 的源码?

可以直接克隆仓库:git clone https://github.com/Hypfer/esp8266-vindriktning-particle-sensor.git,默认分支为 master;安装与运行步骤见仓库 README。

esp8266-vindriktning-particle-sensor 最近还在维护吗?

仓库最近一次更新为 2023年9月30日,当前有 28 个未关闭 Issue;Star 数为 1.2k,可作为社区活跃度的参考。

简要分析

热度分
1512
价值分
782
活跃状态
活跃

语言占比

C
C++

README

MQTT connectivity for the Ikea VINDRIKTNING

This repository contains an ESP8266 firmware, which adds MQTT to the Ikea VINDRIKTNING PM2.5 air quality sensor. The modification doesn’t interfere with normal operation of the device in any way. The ESP8266 just adds another data sink beside the colored LEDs.

half_assembled

Home Assistant Autodiscovery is supported. Furthermore, the WifiManager library is used for on-the-fly configuration. Also, ArduinoOTA is used, so that firmware updates are possible even with a reassembled device.

As the ESP8266 is 5V-tolerant, this should there shouldn’t be any issues, however I haven’t had time to test this for longer periods of time. Therefore, if the ESP burns out after a while, just add a voltage divider or something.

Prerequisites

To extend your air quality sensor, you will need

  • An ESP8266 with a 5v voltage regulator (e.g. a Wemos D1 Mini)
  • Some short dupont cables
  • A soldering iron
  • A long PH0 Screwdriver (e.g. Wera 118022)

Fortunately, there is a lot of unused space in the enclosure, which is perfect for our ESP8266. Also, everything we need is accessible via easy to solder testpoints.

Hardware

To install the ESP8266, you need to unscrew the four visible screws in the back of the enclosure.

Then, there are also three screws holding the tiny PCB in place. These aren’t necessary to remove since you can solder in-place, however personally, I’d recommend taking the board out of there since it will be easier to solder without fear of accidentally melting some plastic.

board

As you can see in this image, you’ll need to solder wires to GND, 5V and the Testpoint that is connected to TX of the Particle Sensor.

Then just connect these Wires to GND, VIN (5V) and D2 (if you’re using a Wemos D1 Mini).

Done.

Software

The firmware can be built and flashed using the Arduino IDE.

For this, you will need to add ESP8266 support to it by using the Boards Manager.

Furthermore, you will also need to install the following libraries using the Library Manager:

  • ArduinoOTA 1.0.3
  • ArduinoJSON 6.10.1
  • PubSubClient 2.8.0
  • WiFiManager 0.15.0

Just build, flash, and you’re done.

When connecting everything up, you should see an open Wi-Fi Access Point to configure your Wi-Fi and MQTT credentials.

Low-Noise Mod

Note: The intent of this section is only to document that this is possible. I don’t “recommend” doing this nor do I advise against it.

As you might’ve noticed, there’s a fan in there, which is audible even multiple meters away.

For some reason, the Ikea uC firmware decides to toggle the fan on and off every minute or so causing the noise it makes to change and therefore it constantly stays noticeable.

Good thing is that the Fan does spin up fine with just 3.3V, which means that we can run it constantly from the voltage regulator of the D1 Mini.

At 3.3V its noise is barely noticeable from 50 cm away.

3.3v

Having the Fan not connected at all was also tried but proved to mess up all readings completely.

This is of course a more invasive modification than just adding Wi-Fi data logging. Though, given that it is just a €10 device, I’m fine with that.

To make soldering a bit easier, note that the whole outer metal part of the Micro USB connector of the D1 Mini is connected to GND.

Misc

The VINDRIKTNING consists of a custom(?) Cubic PM1006-like Sensor + another uC that does all that LED stuff, which talk via UART. The uC simply regularly polls the sensor and displays the results.

Therefore, to add Wi-Fi connectivity, we just need to also listen to the TX of the Sensor and decode those messages. The Ikea uC will do all that polling stuff for us.

As reported in #16, the transitions from Green to Yellow and Yellow to Red in the Ikea firmware are at around 30 and 100μg/m³.

ToDo

Reconfiguration of a provisioned device without having to OTAU a firmware that clears the settings would be nice.

References and sources

评论

暂无评论