Close
0%
0%

IOTA the brain of the house

IOTA is an attempt to bring smart homes back to it's roots. Data accessibility. Knowing what the house is doing not just controlling it.

Similar projects worth following
We bought a house. it's a big building with a lot of stuff happening in it. I'd never thought about just how much stuff I would have wanted to know about my house before I got it. I want to know how much electricity each circuit is pulling from the breaker. I want to know just how cold that room is. WHY IS IT SO HUMID IN HERE? Does the hot tub need to be on all day? Are all the windows closed? Did I forget to lock the garage door? Is today garbage day or is it tomorrow? Gosh I have to be missing something. When's the optimal time to turn the A/C off and on. I wish I had better control over my connected lights.

The internet of things aggregator is an in wall unit that provides up to the minute information about my house, about my power consumption, my task list, have control over my lighting system and trigger events and alerts based on tasks. Plans for a modular architecture, written in Lua, most of all it HAS to look good!

https://bitbucket.org/teamiota/iota

As of right now this project is mostly going to be using Lua as it's main development sctipting language. I am thinking a lot of the information on the custom hardware is going to be relayed via MQTT over wifi but I may be doing some RF->RF server->MQTT bridging. I'm not a networks guy so advice is welcome. I will be using the raspberry pi however the UI software I am using is hardware/os agnostic and can be exported for use on almost any architecture.

The UI Software I'm using is called Storyboard from a company called Crank Software. Full disclosure, I am an applications developer at Crank Software but this is in no means sponsored entry. I have just been given permission to use the software in the development of the project. I can't release the runtimes for storyboard however all my project files and lua code is freely available. If someone would like to try this out on their own systems they are free to get an evaluation of Storyboard from Crank and run the code.

  • 1 × Raspberry pi 3 It's a raspberry pi. WHat more do you want
  • 1 × Raspberry pi official screen 7" screen
  • 1 × Understanding and accepting Girlfriend I'm putting holes in her walls. I mean come on
  • 1 × Udoo Quad It's what I have but I could definitely use something less beefy
  • 1 × Philips Hue system

  • More work on libraries and a list!

    TheBestJohn06/15/2017 at 02:27 0 comments

    So sblua ran the libraries just fine. When I moved over to sbengine to run the UI and the Lua scripts at the same time I had some issues. Every time I tried to run what worked in sblua I was getting a error running the sockets core.so file. It was complaining about not being able to find lua_gettop. This is one of the core Lua library functions and should have been found just fine... Why is it working in sblua but not sbengine?

    Well sblua is essentially Lua, of course it has gettop available. It wouldn't run otherwise. sbengine loads libsblua.so on runtime and doesn't announce it to anyone. These Lua libraries are assuming that they are being run directly by something that makes liblua.so (in our case libsblua.so) available to them by default. I had to go back and clone each library to my local disk, edit the rockspec file to have libraries = "sblua" added to each .so that is exported, run luarocks make "INSERT ROCKSPEC FILENAME HERE".

    What this did was linked storyboards libsblua.so to each library so that it knew where to get the basic functions it needed and re-installed them into their respective folders. With those changes we were golden and I am now able to serve you the following:

    in order to get this i had exported my todoist api key to the environment variable todoistKey. This is pretty static right now but it uses the colors you set it to in todoist and doesn't sync passed the first grab yet. I'm building out the todoist api in Lua as I go so there will always be more to do.

    EDIT: For some reason hackaday wants to send you to websites for .so files

  • Progress on the LuaRocks front

    TheBestJohn06/14/2017 at 01:27 0 comments

    So previously changing the cfg.lua was enough to make everything work. This time I had to open the Makefile and find all the locations where the "lua" bin was mentioned and change it to "sblua" and do the same in the configure file.

    I made those changes then passed the sblua include file and /opt/crank/bin where sblua was located and boom, luarocks using a custom interpreter name.

    Next up was installing some luarocks.

    I installed luasockets, luasec, inspect, and lua-cjson off the bat.

    In order to install luasec I needed to run:

    sudo apt-get install libssl-dev

  • Get set up with storyboard lua

    TheBestJohn06/12/2017 at 23:05 0 comments

    Storyboard uses it's own flavor of Lua so I had to set up luarocks to use it for building libraries.

    first thing I did was install zsh. I just like it better.

    Next I went about cloning the luarocks repo and had to edit src/luarocks/cfg.lua to accept sblua as an acceptable lua binary.

    I've done this in the past but the latest version is giving me issues.

    I do however have the UI proof of concept running on the pi screen and it is interactive.

  • Some Proof of concepts.

    TheBestJohn06/12/2017 at 21:44 0 comments

    I've been working on some of the UI considerations for my Hue lights. The plan for them is mostly to be an input node for events that get triggered. A task on todoist is due? They flash to remind me. The front door is open while my alarm is armed? They all flash red.

    On the user facing side, something simple need to be vetted out. I imagine adding a floor plan onto my UI where you can select the location of the hue light and control it via the touch screen. I'd designed a proof of concept in the past that used something light this with this exact use in mind.

  • Power to the Pi!

    TheBestJohn06/12/2017 at 21:35 0 comments

    So I was thinking about how I'm going to power this wall mounted pi and my first thought was to have mains go directly to a plug in usb power adapter. While that would work the solution is a little bit lackluster and kludgy. I realized that while the pi does have wifi on board it may not be the most reliable when built into a wall. Also, because this particular unit is going to remain stationary, there is no reason why I shouldn't just hook it up to ethernet. Thus PoE is probably the best way to go.

    I have the following parts on order and will attempt to set it up when they get in.

    Those on top of the female ethernet plugs I have should make quick work of my power issues.

  • So what's the plan

    TheBestJohn06/12/2017 at 20:55 0 comments

    In the overall grand scheme of things what do I want this project to do?

    Well for too long IoT has been a buzzword that means "This thing is now connected to your phone". That's not in the spirit of what a smart home or an IoT home should be. A truly connected home means that there is a conglomeration of data in your home where you bring data together in meaningful ways.

    My plan is to build IOTA. The epicenter of data. Somewhat like a local IFTTT. I have seen openHab but that is not what I'm looking for. What I want is something that can make components out of the various IoT devices out there and have them trigger events and respond to inputs in a simple way.

    I am thinking of a block based event constructor like scratch that's written in my favorite scripting language, Lua. The UI will be extensible. I'm using some closed source software for the UI that I cannot release however I can release the Lua source for my project as well as all the project files. I will have to work out a way to add ui elements via Lua in the future to get others input but as it stands it should be something pretty neat in it's own right.

    The main idea is that if there is an open API for the IoT device, we can write a translation layer for IOTA where we extend the block level event I/O

  • Getting a handle on the Grand scheme

    TheBestJohn06/12/2017 at 20:45 0 comments

    Started planning out the project. A good scope first off is to get my electrical usage being monitored and reported to the system. I've been looking into how I want this to progress. Electrical and household thermal/humidity monitoring is a primary goal.

    I've been thinking that for the room to room thermal I can make some form of RF monitors that sip amperage and report on their battery capacity.

    Overall I've decided that my main interface will be with a wall mounted Pi that connects to my server where all the information is stored. Not sure how I want to handle synchronicity with the server and UI.

    On the "convenient" side of things, I want to hook this up to my todoist account. The idea here being that the data in my house helps me populate my todo list automatically. I've got some work done on getting my todo list and keeping it locally in lua. I've also done a bit of work on a Telegram bot that can respond to commands in some form of meaningful way in the future.

View all 7 project logs

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates