12/05/2016 at 12:24 •
Hello open-source and IoT community!
I paused development of mqopen for a while, due lack of spare time. But I got few ideas what to do and I'm in programming mood, so let's continue in development.
I'm experimenting with incubator project. I want to build very simple incubator for my sister. She is breeding cockroaches as feeder insect for her bearded dragon.
So, first some fact about cockroaches, particularly about Blaptica dubia species. They ideal temperature is about 28-30 °C. If temperature is higher than 30 °C, they lifetime is shorter. Also, the will not breed below 20 °C. They generally likes higher humidity. This species don't need that much high humidity, compared to other ones. But, high humidity leads to creating of mold. Recommended humidity slightly above 60 %. Blaptica dubia are sexually adult after 8 - 12 months, so keeping them as feeder insect as quite long term run. If the colony dies, it takes long time to grow new one.
So, incubator should have following features:
- Sensor for measuring temperature and humidity in the colony.
- Relay for controlling the heater.
- 12 V power output for controlling computer fan.
- Alarm to notify user of something goes wrong.
Computer fan is experimental feature. It should ensure better air flow in the incubator box and potentially suck wet and warm air out. It is also supposed to be used in other applications, so 12 V power output can be useful.
Of course, incubator will be connected into network using MQTT protocol. It will report temperature, humidity or state of heaters, and potential alarms. It should be also configured over network connection.
Let me know if you like the project :)
07/12/2016 at 17:30 •
I'm happy to announce that I released new mqspeak version a few days ago. It contains some bug fixes and also some new features. Let'st briefly describe them:
When channel update consists of data from multiple sensors, it may happen that one sensor die. By default channel never will be updated until data from all sensors arrives. Inactive sensor causes channel update will be stalled.
When update waiting enabled, mqspeak will wait defined amount of seconds and then sends out even incomplete channel update.
I have implemented 'onchange' updater for handling asynchronous events, like opening and closing a doors or events from buttons. This updater simply sends every configured MQTT message to ThingSpeak/Phant channel. If events happens too often, mqspeak will store them in local buffer and send them out when remote server can accept new update.
I removed logging to stdout and replaced it by logging to syslog. It provides easier control what the services does and more convenient debugging.
New mqspeak version is already uploaded into pip repository. You can install it by issuing of following command:
$ sudo pip3 install mqspeak
06/16/2016 at 14:49 •
One of the most common sensors is Dallas DS18B20 temperature sensor. It is pretty cheap, accurate, has only one data wire and is available in water-proof package. mqopen has already support for DS18B20, so building simple temperature sensor is really easy.
It comes handy at the start of the summer for monitoring water temperature in a swimming pool. I built a probe very similar to this one, except with water-resistant cable join.
Sensor itself is placed at the bottom of the swimming pool where the water temperature is lowest. Other end of the probe is plugged in ESP8266 node under little roof, protected against rain.Sensor periodically reads water temperature and sends it to my MQTT network. mqspeak then collect the data and updates ThingSpeak channel with actual water temperature. Final graph (from rainy day) looks like this:
06/10/2016 at 13:36 •
I made some progress on my ESP8266 node firmware. My goal is to build single, robust, configurable and reliable piece of code for these little IoT devices, to avoid redundant implementations and unnecessary bugs. You can download it from my GitHub. Users should be able to configure it in kconfig interface and create firmware their own IoT device without need to write single line of code or even modifying any header file.
List of esp8266-node updates:
- Added service topics - I added various service MQTT topics which node sends into network when it connects. This is useful for statistics purposes. debugging or for searching nodes with obsolete firmware or hardware versions.
- Device class - I divided nodes into two basic classes:
- Sensor - Sensor device sends data to network.
- Reactor - Reactor devices reacts to data from sensors and take some actions. I have already implemented some prototype code, but this part is in the main development.
- Asynchronous sensors - I implemented abstraction layer for synchronous and asynchronous sensors. Synchronous sensor periodically sends data. Asynchronous ones waits for some event and sends data only when event happens (with retain bit set). This feature takes advantage of MQTT to save bandwith and improve response time for a other devices. I'm building a door sensor which reports every time when door status changes (open / closed).
- Initial data publish - Nature of asynchronous sensor it that it sends data only when event happens. I implemented logic which sends sensor state when node becomes online, if the state is relevant.
- Various bug fixes - I fixed some bugs in the code and hopefully improved device reliability.
I have lot of ideas for another improvements, stay tuned :) http://mqopen.org/
05/24/2016 at 11:41 •
After I got working kconfig tool for my ESP8266 firmware, I can more effectively implement new kind of sensors. So, the firmware now supports these ones:
Button is special and most recent kind of sensor. It is asynchronous and interrupt driven. It is also be considered to be used as abstraction layer. In future realeases, it should handle other asynchronous devices, such as PIR motion detector. It just detect rising or falling edge and transmits MQTT update message. It is in experimental phase, but it can be very useful.
All necessary configuration steps are done via 'make menuconfig'. You can find more details on my wiki page.
05/19/2016 at 11:10 •
I'm constantly developing my IoT network. Adding new features, fixing bugs, building larger network, creating new software, etc... For that reason I decided to find a name for the project and run a website.
I wrote some HOWTOs and other stuff, homepage, created some pictures and created little website.
You can find it at http://mqopen.org. That't the project name.
04/27/2016 at 11:25 •
I'm currently tinkering about convenient configuration for each IoT endpoint device. Each device have to be configured to correct network settings, it own name, connected sensors, MQTT setting and lot other stuff. When I want to create a device with new sensor, I have to create new branch of source code and make appropriate patches to it.
It's very tedious and stupid approach, so I plan to merge all branches into one solid codebase and provide ultimate configuration tool. I successfully ported kernel's Kconfig tool to my project. It still requires lot of work. But finally, I have my working prototype :)
03/23/2016 at 09:34 •
For last few months I work on device diagnostic and health monitoring software. I have already some prototype which I plan to release. I call it 'mqguard'
Its divided into two parts:
- Backed diagnostics daemon. Written in python. Its responsibility is monitoring MQTT traffic and apply some checking rules to it. It can detect anomalies such as error codes, invalid values, timeouting or flooding and other things.
Here are some sreenshots:
I plan to release alfa version very soon. I'm writing build and deploy instructions, documentation and fixing some minor bugs.
03/16/2016 at 18:47 •
03/09/2016 at 16:17 •
I was refactoring mqspeak bridge. I moved some code into separate library to avoid code duplication in my other software. Most importantly, I used setuptools for package distribution. Now you can install mqspeak with following command:
$ sudo pip3 install mqspeak
To use mqspeak, you need to create configuration file. Example configuration can be found at project GitHub repository. Easiest way how to run mqspeak is start it as systemd service. Sample unit file can be also found in git.
Please let me now some feedback or bug reports :)