|
|
making one ESP8266 able to reboot another Friday, November 22 2024
location: 940 feet west of Woodworth Lake, Fulton County, NY
For the first time ever, I woke up in the cabin without any coffee; I'd forgotten to buy any at the Cairo Hannaford. So I made due with black tea, which is what I would normally drink on a Friday morning back in Hurley.
It was cold and windy this morning, with a thin layer of wet snow covering enough of the landscape to make things pretty. I took Charlotte for a walk (Neville didn't come), but all we did was walk down to the dock via the Mossy Rock Trail and then out across the outflow creek, though the campground, across both bifurcations of the outflow creek within a couple hundred feet of where they bifurcate, and then back to the cabin. I wore rubber boots, because walking in any amount of snow with Crocs is an extremely unpleasant experience.
Since discovering yesterday that my EP8266s can sometimes be recovered from an uncommunicative state by simply rebooting them, I've been figuring out a way to take advantage of the muliple ESP8266s in the basement to make it so they can reboot each other. This required direct wired connections between the device that forces the reboot and the one being rebooted. The easiest way to pull this off in the basement environment for beig able to reboot the most important ESP8266 (the "East Basement Controller," which now controls seven different electrical circuits), I thought I could run a 12 volt power line across the basement from a relay attached to the SolArk Co-pilot. Since this 12 volt line would be providing the actual power to the East Basement Controller at something like 80 milliamps, I needed to use a fairly thick wire to run the 12 volts, as anything too thin would experience an unwanted voltage drop across the forty or fifty feet of wire distance. Unfortunately, the only suitably thick wire was in bundles of romex, and I didn't want to use that. So I added thick single-conductor insulated wire to a mental shopping list along with tiny wood screws (the kind for attaching printed circuit boards to wooden panels) and various wire rope supplies (to help me further improve my dock winterizing gear).
The dogs didn't want to come when I said I was going "for a ride in a car." So I left them at the cabin with a nice fire in the woodstove and drove to the True Value hardware store in Gloversville. There I got most of what I needed, though their wire rope supplies weren't much more extensive than what I have in a can back in my laboratory in Hurley. A 500 foot roll of 14 gauge single-conductor wire cost about $70, but I couldn't buy less than that amount. While I was in Gloversville, I visited the Price Chopper, the place whose customers make the ones shopping at the Ghettoford in Kingston look like soccer moms at a Whole Foods by comparison. Their coffee selection wasn't great, but I found some fair trade whole beans in a thick-walled plastic bag. I don't know how many vegans shop at that Price Chopper, but they had a new vegan cheese for me to try, smoked gouda slices made from olive oil.
Back in the cabin, I began running the new wire from a nice battery-backed 12-volt source (a thick wire running through the foundation wall to the 12v terminal of the Generac generator's lead-acid starter battery) to the unused relay on the relay board beside the SolArk Co-pilot, and then through the joists of the basement ceiling to the east foundation wall, where the East Basement Controller resides. There I needed some way to convert the 12 volts to a 5 volt level, ideally in an easy-to-work-with form like a USB-A connector. I happened to have a four-USB-outlet automotive cigarette plug adapter that was perfect for the job. I use a similar device to power the Moxee cellular hotspot and the ESP8266 that monitors indoor weather and serves as a hotspot watchdog. But the connections to the 12 volt side of the adapter are always a bit of an improvisation, since I don't have sockets for them to plug into. Today, though, I came up with a solid way to attach such wires. I drilled two holes into a curved piece of copper sawed from a 3/4 inch copper pipe and used these to attach that copper piece to the board where the East Basement Controller resides. I then ran a worm-gear-tightened pipe clamp around the copper piece and stuck the cigarette-lighter adapter inside the pipe clamp so that when it was tightened, it gripped it solidly exactly where its ground connectors were exposed. I then wrapped the stripped end of the 14 gauge copper wire around the cigarette adapter's tip, where it could provide the +12 volts, ensuring it wouldn't slip off by screwing down a small L-brace up against the tip. When I powered this all up, it worked great, and after adding a database record to the database that holds the source of truth for my system, I was able to make the SolArk Co-pilot turn the East Basement Controller's power off and then back on. Such capabilities were making my system resemble a probe in deep space even more.
I soon discovered, though, that the new record in the database now made it so I could no longer turn on the Generac generator with the SolArk Co-pilot's other relay. It turned out that I'd made a small oversight when copying the remote control code from the ESP8266 Remote Control repo to the SolArk Co-pilot repo, and all I had to do to make it work as expected was to change a place where I'd hardcoded a "0" in a *-delimited string into a "1."
Not wanted to repeat last weekend's miserable snack-only eating experience, today I cooked up a pot of basmati rice, which I ate with a pouch of pre-packaged curry (which I spiced up with ghost pepper, naturally). I always like to have some sort of flat bread with my Indian food so that I can use it as one does injera in Ethiopian cuisine. For that, I cooked some soft corn & wheat tortillas on the open flame of the stovetop, and it made for a good combination.
Later I ran the generator for awhile, as it had been cloudy all day and I didn't want to run out of power. I then took a bath using the boiler's just-in-time hot water heating function.
For linking purposes this article's URL is: http://asecular.com/blog.php?241122 feedback previous | next |