Some time ago my RPi with running Doton crashed. It was quite a surprise but happens:) Reason was trivial, I moved it and SD card was pressed against the wall and ejected 🙂 But after a restart, it crashed again but this time with a fatal error. This hits me! We have no way of showing a temperature that is under zero!
This also remembered me that I didn’t do anything with the project for some time. I still have a window manager to redesign and rewrite.
But let’s start low and first clean up a GIT repository by removing submodules and changing a readme.
This project started its life with Daj się poznać competition but competition is over. Time to clean it up from additional modules and leave only files that are used.
The fastest method was to manually delete .gitsubmodule and directories 🙂
Creating an RFID reader that works in the real environment and not only on my shelf was the very refreshing experience. The whole process went rather smoothly. But life is a life and a few issues occurred. I grouped them in this post.
I mentioned a magical switch to enable configuration mode. In this post, we will write a configuration module for RFID node. Why not for boilerplate?
Because first, we will analyse the problem and create a tailored solution. After gaining some experience we will rewrite module and create a universal configurator.
What is to configure? An AP credentials and an URL for a server.
There are a hardware and a software but this is not all, there is also a case that holds all together 😀 and makes project look good 🙂
The Client wants a nice looking case and this is easy to understand. So new area for me, how to make nice holes for connectors, LEDs, switches and so, last time (with NodeONE) it wasn’t all good.
But today there is no room for failure! Let’s get to work!
- part 1: NODEMCU AND RC522 CARD READER
- part 2: NODEMCU AND RC522 AND REST COMMUNICATION
Last time we made a device that reads RFID card and communicates with devices by broadcasting a message. This implies that on the same network a server must be. We can use another device to work as a proxy between reader and remote server but why? We can communicate directly with the server via HTTP requests and box can inform other devices about the result.
Code added to NodeMCU Boilerplat@GitHub
Some time ago an opportunity knocked on my door. A friend needs a device that would read a card, send the id to the server and react to response.
Today we will work on code and create a class and a handler for the RC522 module.
Module and handler added to NodeMCU boilerplate @ GitHub
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
To use our beautiful ILi9325 display with ProxyLCD we need to manually edit settings.ini. This is not a good way:) Why is that? Because we cannot set a proper size. We are using a selector with predefined values. We need to change it to two text fields.
And we need the formatters, what is that you may ask? You shall see 🙂
Last time we wrote an HD44780 driver that takes GfxLCD compatible display and works with CharLCD package. This is nice because we can use big ILI9486 as a character display.
You may ask, why?
Because with ProxyLCD we can see a big output from Symfony 🙂 And because we can 🙂
Today we will focus on two bugs from a previous part and we will see if all chipsets can work with HD44780 driver.
– Part 1
We have a remote LCD Node that works on NodeMCU board. It has a 40×4 char LCD attached to it and displays text received via a network message. We also can use Raspberry Pi as a remote LCD. But all those LCDs are small. We need something bigger and we have it! This something is an ILI9325 graphical display. There is a huge difference between char and graphic but we can simulate char interface. Our GfxLCD library has an ability to display a text and with a little bit of tinkering, it should work :D.
This could bring nice results, imagine a dump from Symfony with multiline formatting thanks to the ProxyLCD project. Nice 🙂