Posts

Showing posts with the label Home Server

Solar Cameras

Image
During the COVID-19 time, stuck at home with no travel, I upgraded my home automation sensors with photovoltaic energy harvesting . After five years now, I can definitely say this has been working. Practically I'm left with just one battery-powered sensor: it is in a bathroom, and the photovoltaic energy budget there is close to zero (no windows, lit by two dim lightbulbs only very occasionally). All others have been "just running", doing their daily jobs. But this application (pushbutton wireless switches and occupancy sensors) has very low energy requirements. This summer I was attracted by the concept of solar-powered wireless cameras. I have a couple of PoE cameras made by Reolink (they are good and do not require any subscription). I was skeptical about a solar panel ability to power a device like a WiFi camera, but - surprisingly - it works. The camera has been strapped to a tree and overlooks part of my property and the bundled 3W solar panel has so far proven to ...

Nixie Sync

Image
The Karlsson Nixie clock (by Peter van der Jagt 1997) is very stylish. One of the first of the kind and definitely setting the trend. Unfortunately it does not hold the time after a power outage. For quite some time I was thinking of adding a time synchronization module. Initially the idea was to use the long wave radio receiving the DCF77 signal. DCF77 is increasingly more problematic as the 77kHz frequency is impacted by the totality of high frequency digital power supplies that generate lots of radio noise. The alternative is of course fully digital, relying on an Internet time source, based on the NTP protocol. Surprisingly (or not) the NTP-based module has proven to be super easy to build these days (...with the help of AI). Actually I wanted to kill two birds with one stone: have the bloody clock display the right time and also test Claude's capabilities as a junior embedded software / electronics coworker. Both goals have been achieved. I found it entertaining, educating, ...

DALI+ over Thread: Capacity

Image
The post on  Bluetooth NLC vs DALI+: Capacity and Performance has generated very valuable feedback. I promised to shed some more light on my network capacity calculations, so here they are. The key assumptions are: - The Thread network operates at 2.4GHz using IEEE 802.15.4 data links at 250kbps; - Transmitting nodes use Carrier Sense Multiple Access with Collision Avoidance (CSMA/CA) method to manage the shared communication channel; - Each unicast transmission is acknowledged - There are two hops (say: sensor → router and router → lighting controller) - The minimum data frame at PHY is 50 octets (+6: preamble + SFD), so ~1.8ms - The ACK frame (including the SIFS time) is ~0.5ms - The average CSMA/CA overhead is ~1.4ms That gives us 3.7ms per hop total. So with two hops we have the channel occupancy of 7.5ms. At full 100% channel occupancy that would give us capacity of 135 end-to-end messages per second (one way). But... 100% would simply kill the network. Thread is very fr...

Virtual Solar

Image
Utilities move slowly. But ultimately they do. Half a year ago I installed the Home Assistant multi-channel energy meter which has  clearly shown the energy usage patterns. I had known before my addiction to hot bath every day cost me dearly. And it was really the lowest hanging fruit. Water boiler is the most efficient and available energy storage . After seeing the usage patterns, I was planning to switch to variable energy pricing plan. But filling the related paperwork was tedious enough to procrastinate. Until the utility offered the helping hand: switch to energy pricing with just a single "yes" click on their web site. No paperwork, no nothing.  A couple of days later the confirmation of the switch arrived. Plus I have online access to the formal energy meter readings. No Home Assistant integration yet, but the patterns and values match with what I have, which is reassuring. I need to get used to this a bit (although the main patterns have already been preprogrammed)....

Home Assistant Brings the Watch Battery Down

Image
This one is quite interesting and I am yet to collect the hard evidence on what really happens. Long story short: Home Assistant can, behind the scenes, drain battery in a smart watch. It all leads back many months ago when I started seeing my Garmin fÄ“nix  watch dead every morning. I mean ALMOST every morning. Normally it can run for 1-2 weeks on a charge and suddenly every morning it was dead, despite being fully charged on the day before. I tried different things - software/firmware update of course, changing some parameters (but it had been working fine before) - no lasting improvement. Until this June (after having extensive travel period - US West Coast, twice to China and then Europe), when I realized that it did not lose the battery when I was away from home. I started thinking on what was so special at home that the watch, left for the night on my bedside table, was losing the charge completely. There was one idea that came to mind: Home Assistant. And to be precise: ...

Home Energy Revisited

Image
It has been almost 6 full months since (after long procrastination) I finally completed the home energy monitoring project . In short: Home Assistant + Circuit Setup energy meter based on ESPHome. Long story short: all has been working flawlessly. There have been multiple routine firmware updates (they are released ~monthly). To be honest I have not paid (almost) any attention to them. Luckily nothing got broken, but equally Home Assistant could be releasing one update per year. This is a side observation, but generally people are fed up with software updates. Even if they go flawlessly, there is always the risk of something getting broken. I've been hearing the same from our customers: you release too frequently (we used to every 6 months, but now there is the pressure to release at most once a year). Ove the 6 months I have learned quite a lot about my usage patterns. Daily hot bath is an energy hog, but I can easily run the boiler when the energy is least expensive (=middle of ...

Power Over Data

Image
Delivering power over wired data lines has been one of the most obvious extension to many legacy protocols. It is hard to comprehend why many of these protocols did not have the power option from the beginning, requiring the connected devices to be fed power over a separate line (and a separate cable). Less cables is always good. My own journey with cutting power cables started about 40 years ago when I designed my first commercial product - a software protection dongle. The dongle was using the PC printer port for communication. Unfortunately the printer port never had power lines in it, but I managed to harvest sufficient energy from the data lines.  Next in line was USB , and the inclusion of power was a very significant (if not the most significant) contributor to the success of the standard. Now with the Power Delivery (USB-PD)  capable of carrying up to 240W of power, the PD is the king of power-over-data standards. HDMI is the one that really failed to do this properly....

Home Energy Monitoring

Image
It took me a while. It all started quite some time ago when I came across this vide on DIY Whole Home Power Monitoring with ESPHome & Home Assistant . Things have changed (mostly improved) but the basics still apply. The video is a great start to Home Assistant and ESPHome learning curve. When I started I knew almost nothing about this stuff. Knowing this would be a difficult project (well maybe not THAT difficult, but such when you can make many mistakes on the way and even do not recognize them until very late), I took quite systematic approach.  Started with Home Assistant Yellow . It is a great option for a Home Assistant box, as it has Zigbee / Thread radio bulti in and can be powered via PoE. Also has plenty of storage. Setting up Home Assistant is a breeze, as there is a dedicated image available to be installed via the Raspberry Pi imager. The next step was ordering the CircuitSetup boards (the main board and 3 add-on boards for 24 channels in total). I also ordered (v...

Digital Fragility

Image
Everything is digital and therefore software-driven today. And that software is getting super complex, with tons of layers and dependencies. This complexity, statistically, leads to many failures which in the end are unavoidable. No matter how thorough the testing is, it is impossible to cover and catch every possible scenario. Even simple stuff like alarm clocks sometimes fail to go off. Something unthinkable in the old days of mechanical alarm clocks. And there are times when a working alarm clock is critical. Such that when you have an intercontinental flight to catch early in the morning. Just recently Apple has confirmed the iPhone alarms may not go off due to a software bug. That is why even being a digital gadget geek, I have a rule to set up an analog alarm clock just in that case - an early morning flight. To regular people this is something close to unthinkable - the most premium mobile phone, with millions of users and billions of R&D and QA budgets behind - can still ...

Not NAS

Image
Facing the loss of archived data - the last week's post - I needed a quick decision on the alternative solution. The straightforward way would be to upgrade the old Networked Attached Storage (NAS) server. It clearly has been failing and despite a bunch of bulged capacitors in the power supply unit (PSU), replacing the PSU did not solve the problem. Of four disks one was declared dead almost immediately after start and a second one was being flagged as dead shortly after. I could stuff the old chassis with new disks, but two disks dying at the same time smells like the problem is elsewhere. On top of that the software on the NAS has been no longer maintained (another civilization disease) and there have been issues using it with newer versions ow Windows (I think it was Windows 10 which officially declared the old SMB protocol fundamentally unsafe). But another angle of the NAS story is also important. Historically the NAS server was the home multimedia server with stored music an...

Backup the Backup

Image
I somehow have sentiment to old digital content. I mean the one which I created, as this is something the Internet will not take care of automatically. Being lost in managing all the detailed files and directories with source code, experiments, configurations, photos, notes etc, I resorted to having sufficiently large backup storage to just "backup it all". Especially as even with digital photos contributing to most of the bulk, the economically accessible storage capacity outpaces my creation velocity. In short: today it is affordable to backup everything. The storage capacity increase unfortunately is not matched by the reliability increase. In other words: hard drives (and be it mechanical or solid state) still keep alarmingly failing. This failure rate is what makes the redundant systems alive - have a RAID disk array and it will manage your failing drives proactively notifying you about imminent failures and letting you replace the (inexpensive) drives on the fly. The q...

End Of Life

Image
Google sent me this "Christmas gift" message three days ago. Yes I had heard the rumors. And it is both sad and surprising. I have been using the OnHub WiFi for several years and it has been great and flawless. After experimenting with several WiFi access points, this one has been the first one to fully cover the house. And I never ever needed to reboot it. It has been invisible. The best technology is invisible - it just works. But due to the support / end-of-life policy I will have to go through the hassle of selecting / installing / troubleshooting a new device while trashing the perfectly functioning one. This is the insanity of the Internet era. I can - to some extent - understand the upgrade cycle of devices which do gain significant functionality. Smartphones are among them but even they hardly need replacements every year or two. But WiFi? At some point it is just good enough and replacing an access point just does not make sense. Vendors really do need to start think...

Local Autonomy

Image
Cloud-based is the new normal and it works most of the time. The problem, however, is when it does not. And these things tend to happen when we need them the most. Not long ago Tesla went down preventing people from opening their cars . Then Amazon outage kept people out in the cold as they could not enter their (dis)connected homes. Cloud is nice and solves a lot of problems. Provided it is available. This is why features considered foundational should run autonomously without any cloud connectivity. It is a bad idea to connect switches and sensors to lights via cloud. But people are doing it, as from the integration perspective this often is simply easier. But latency is introduced, which contributes to bad user experience. And worst of all, the Cloud becomes the point of failure for even the most basic functions. Bluetooth mesh has been winning the markets since it became available in 2017 and the most prominent feature is the resilience of this system. This is due to the groundbre...

HDMI CEC

Image
I think not many of you have heard the term HDMI CEC. It stands for Consumer Electronics Control , which again, does not say much. It is a very useful standard though and helps audio-visual devices function much better and become much more friendly and easy to use. But there are two problems with CEC. The first: not every piece of equipment implements it. Some do and some don't. And the second: every vendor has it's own name for this feature. Anynet+ (Samsung), BRAVIA Link (Sony), EasyLink (Philips), SimpLink (LG), EZ-Sync (Panasonic) to name just a few. In other words, a jungle. CEC is one example why things should not be optional in standards. HDMI as such does not have the best reputation. Problems with cables, connectors, version compatibility, copy control have earned it the "problematic" label. Sure it is better than VGA, as at least pins in cable connectors do not bend, but overall HDMI has not solved the "Looking for an active signal source" problem ...

Smart Lights

Image
It was December 2016 and we were entering the last straight to finalizing the Bluetooth Mesh specifications . I felt we were missing the crucial part of the architecture though, We had lights and sensors and other stuff specified. All good. The lights could react to on.off, dim level, color temperature and hue / saturation. And I was especially happy about how we defined sensors, reusing the wealth of data already defined by Bluetooth such as (GATT) Units - things like Celsius temperature or catalytic activity concentration (katal per cubic metre), and GATT Characteristics, giving us instantly definitions of close to 200 sensor types .  But lights and sensors had been in separate domains. Sensors could report occupancy and (too) low light level, while lights would still remain off, waiting for an "on" or "dim up" message to arrive. This is how everybody else have been doing things, from Z-Wave to ZigBee and DALI. There the protocol defined and messages within that p...

Energy Testing

Image
It turns our winter is a great time to test renewable energy systems. Both on a state scale - like in Texas last week and on a private [smart] home scale. Last year I upgraded all my battery powered sensors and light switches to photovoltaic with the goal to have them running forever . I opted for supercapacitors rather than rechargeable batteries, as supercapacitors supposedly have infinite life span. A 5F capacitor at 4.5V (discharging down to 3.6V) is able to power a radio transceiver for two days. The sun rises everyday - I thought - so that would be 100% extra margin. Which turned out not to be enough.  My mistake was making the upgrade in springtime and it all worked beautifully throughout Summer towards Autumn... In November problems started popping up. As the days were shorter and I stopped getting any direct sunlight (I live in a valley) and the sensors started falling out of the network. Quick voltage check showed there was not enough charge to keep them going. In most c...

Dynamic Electricity

Image
The problem with electric energy is not that it is scarce or expensive. The problem is it is very difficult to store. Batteries are super expensive and their capacity is low. Also the distribution network capacity is limited. This all means dynamic management of the demand is really the key. At the same time it is extremely surprising how slow the rollout of dynamic demand management has been. Especially considering the [potential] efficiency gains and the fact all technologies needed have been around for many years now. Definitely we need communication standards for that to happen - every water boiler, every washing machine should be able to respond to supply side signals. As a matter of fact, every appliance which can consume its energy "later" (when demand should be decreased) or "now" (when demand should be increased) should be able to understand and respond to the energy provider's indications. Open ADR has made some inroads in some geographies - mostly in...

Long Term Support

Image
Long Term Support is another aspect that true standards bring much confidence into. This is especially important for commercial buildings, as the systems, once commissioned, will stay there not for years, but decades. When proprietary systems are considered, it is unlikely their manufacturers will maintain full backwards compatibility for an extended period of time. The reason is cost, and when you do not need to care about a broader audience, it is easy to make a decision to deprecate older versions. For customers this means the proprietary system which look nicely today, will have to be scrapped prematurely, as soon as one of it components ages and stops functioning. And while manufacturers may claim 5- or 10-year support, such period of time can hardly be considered long term. So how about 30 years? Open standard-based system is probably the only assurance you will be able to find compatible spare parts when something breaks. The original vendor may be out of business or will have s...

Multi-decade Stability

Image
One of the failures of the widespread silicon - software technology surrounding us is it is very short lived. Ad-hoc reboots, battery replacements, even device replacements are part of our daily lives. Software updates used to be a nightmare too, but thanks to the widespread connectivity they have become less annoying, moving to the background. This is interesting like the continuous improvement in software maintenance and testing has made this task that was so annoying and tedious a much more bearable operation. Something that has become fully automatic, to the point is is almost invisible. None of us can say today which software version is running on their phone or a personal computer. The answer is - probably the latest. So we may say the software problem has taken care of itself, as vendors will continue delivering in the background well-tested upgrades, as long as it is economically feasible for them. And when it becomes not feasible, the device is left on its own. As long as it c...

Detecting Intentions

Image
Most full-featured smart homes are failures. Users hate them. The key reason - based on my observations and the experience with my own full-featured smart home is the behavior of the "system" quickly starts irritating the users. The reason is there are very static (even if complex, still static) behaviors. Configured with certain scenarios in mind. And people at home are fairly dynamic. By dynamic I mean their behavior (and expectations) change. The simplest example is a party, that usually lasts long into an evening, and people are caught by the HVAC switching to the night mode and lights stopping to react to motion sensors (as they are programmed not to turn on when you turn in bed) and so on... The other day I wanted to program my water heater timer to avoid it heating the water 24/7. I programmed the week-day hours (morning showers) and afternoon/evening cycles. Then it all failed when on another day I had to wake up early for a morning flight and went to the shower...