NodeMCU boilerplate

NodeMCU and a tricolour led

I’m on a project that requires some feedback after the operation is made. I cannot use an LCD because they are only two pins left and almost no memory. So my mind focused on two LEDs but after a while, I made a choice, I will use tricolour LED.
From what I read there are two types, one with a common anode and one with common cathode. We will go with common anode.

Module added to boilerplate


Daj się poznać / Get noticed – summary

Time is almost over but we have so much more work to do! Of course, we won’t stop our work but let’s summarise was has been done during competition.

The main goal was to build a control node that can gather and display information from different sources/sensors. This node is the Doton project.

But before we could create it we have to do two other projects: a GfxLCD python library, NodeOne sensor and improve one: NodeMCU boilerplate. So, in fact, we have done four projects 🙂


Node One – a multi-purpose node

Today we combine the power of HLK-PM01, PIR HC SR-501, DHT11 and a light detector.
Together they create a nice looking multipurpose Node One. I wanted to do it for some time but the last piece was missing. I didn’t have an idea how to create a box for components.
Few days ago I found a perfect case named Z27. It has all I wanted, socket, plug and enough space for NodeMCU v3.
Python code @ GitHub
LUA code @ GitHub

NodeMCU and light detector – part 4: a module and a handler

We have a nice node that detects light, it works in toilet @ my work 🙂 It does it jobs almost perfectly. There is still a hack for it – leave a light on when leaving the toilet. I have an idea to fix this but first, let’s reforge a lousy code into a module and a handler. After refactor we may safely add it to the NodeMCU boilerplate.

This is going to be our second data node for display.  It will show area lightness and with conjunction with a time, we can tell if an artificial light is on or off.

NodeMCU boilerplate @ GitHub


NodeMCU and PIR HC-SR501 (motion detector)

We have LCDs and we should have a data that can be displayed on them, we need data sources. So in parallel with displaying, let’s work on some sensor nodes.
First will be a motion detector, we gonna use a module with easy to remember name: PIR HC-SR501 🙂.
There are a few variants of it. But the main difference is an ability to use jumpers to change mode. My version can’t do that 😦
As a brain for sensor we will use the NodeMCUv3 board and as a language the LUA.

Module added to NodeMCU boilerplate @ GitHub