A week or so ago I was struggling to get everything I wanted in one ESP8266 running Tasmota – for example, the tasmota-sensors.bin file has lots of sensors and very little display capability while tasmota-display,bin has very few sensors. One of the guys suggested I tackle doing my own Tasmota builds – the idea of which horrified me.
Well, all of that has changed overnight and more. Let me go through this:
I’m a Windows 10 user primarily and dive into Linux only when need be to work on routers, Raspberry Pi and the likes.
So, I was pleased to discover TasmoCompiler – check the readme in that link to the left. No downloading of compilers etc, the online software instructs you to press a key to get the latest Tasmota, then lets you select from a list of tick options including various sensors, displays, IR control and more. Once that’s done it lets you download a firmware.bin (or firmware.bin.gz) file to your local machine with only the stuff you wanted in the compilation as well as your WiFi credentials.
Add to that, ESP Flasher Windows 64 binary – and you can now flash custom ROMs on (in my case) ESP8266 (example NODEMCU with auto-reset and flashing, so no pressing buttons) or ESP32 boards. ESP-Flasher isn’t very pretty but it is VERY easy to use.
But that left me with how to do OTA as the Tasmota web interface assumes you have an http server with the ROMS sitting in it. To the rescue – HFS – you may remember I wrote about HFS some time ago. I was in the UK at the time and my friend Antonio (MrShark) helped me get it set up so I’ve downloaded it again onto my PC here in Spain. A tiny amount of HFS setup to create a virtual file system (seconds worth of work) and attach it to a real file system so that a folder (for example) c:\users\user\downloads\firmware on my PC becomes part of the HFS server – I changed the port from 80 to 81 to avoid interfering with any other web server activities on my PC and finally saved the new system as well as telling HFS to come up automatically when my PC powers up.
Click on that folder – click “open in a browser” and there it is – my very own OTA server for Tasmota – my folder names and the name firmware.bin can of course be changed.
And to use with an ESP8266 (or ESP32) that has been flashed once with the custom Tasmota firmware and ESP Flasher – after changing the software or making it use Theo’s latest dev or release version of the basic code:
I’ve also learned a little about Tasmota rules – a first crude attempt at diaplaying the time regularly (every 5 seconds) on an ILI9341 meant getting to grips with the Tasmota file system menu, Tasmota RULES and RULETIMER as well as DISPLAYBATCH. Note that ruletimer1 1 would not work – must be pushing it for the software.
ruletimer1 5 rule1 on rules#timer=1 do backlog displaybatch display5.bat; ruletimer1 5 endon rule1 1
The file display5.bat contains:
and the startup rule to trigger that timer and initialise the display (I didn’t know how to do this until now…)
rule2 on dimmer#boot do backlog displaybatch display.bat; displaybatch display1.bat; displaybatch display2.bat; ruletimer1 5 endon rule2 1
And now for something completely different
Also this weekend I managed to flash my first ESPHOME ESP8266 – just to check it out. I used ESPHOME stand-alone at first – then installed HOME ASSISTANT and plugged in the ESPHOME add-on – and then flashed an ESP8266 from there, at first serially on the RPI – from within the package – and subsequently OTA. All good stuff but I’m not sure it’s any better or even as good as Tasmota at this point – so just a bit of fun, really.
What I DO like about Home Assistant and ESPHOME is the map of my house – where our road is only partly detailed on Google Maps, this map even has the dirt track going over a hill behind our house. I’m impressed 🙂