HackerTrans
TopNewTrendsCommentsPastAskShowJobs

danielszlaski

3 karmajoined 4 เดือนที่ผ่านมา
I build cloud-powered backends and polished iOS apps - clean code, thoughtful design.

Submissions

Show HN: iOS widgets that read your solar inverter over local Modbus TCP

danielszlaski.com
3 points·by danielszlaski·เมื่อวานซืน·1 comments

[untitled]

1 points·by danielszlaski·3 เดือนที่ผ่านมา·0 comments

comments

danielszlaski
·เมื่อวานซืน·discuss
Hi, I built this to scratch my own itch: I have a Solis hybrid inverter with a 14.2 kWh battery at home, and the official monitoring app was too slow and clunky for the one thing I actually wanted: glancing at my phone to see "how full is the battery?" That felt like a widget problem, not an app problem.

The first version used the vendor's cloud API, which worked but bothered me: my inverter is 10 meters away, why is my data doing a round trip through a server in China? So I added local Modbus TCP support. The app now talks directly to the inverter's datalogger over the LAN, no cloud account needed, works when the internet is down, and updates are near-instant instead of the 5-minute cloud polling interval. (Still I'm limited by around 15 min iOS Widget polling)

Some things that turned out to be harder than expected:

Writing a Modbus TCP client in Swift with Network.framework. There isn't much prior art for Modbus on iOS, and dataloggers are picky — some drop connections if you poll too aggressively, some only accept one concurrent client.

Register maps. Every vendor (and sometimes every firmware revision) lays out registers differently power values as 32-bit across two registers, inconsistent signedness for import/export, scaling factors that differ between models. A lot of the work is a growing library of per-model register definitions. I've already received some good feedback from other than Solis users that tried that app. Once I'll get more valuable feedback I could extend list of supported Inverters. Although it's all depend if Modbus is available.

WidgetKit's refresh budget. iOS gives widgets a limited number of refreshes per day, which is fundamentally at odds with "live" energy data. I ended up with around 15 min invervals.

I've also added recently GameCenter support, so now everyone can compare their installations and how it works with other (fair algorithms are included so small good positioned installation beats bigger)

It's a paid app - but basic usage (no live widget support) are free.
danielszlaski
·3 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·3 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·3 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·3 เดือนที่ผ่านมา·discuss
Very cool! Nice to put it as a side window for live status (which do not take too much attention compared to YT)
danielszlaski
·3 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·3 เดือนที่ผ่านมา·discuss
Nice and clean.
danielszlaski
·3 เดือนที่ผ่านมา·discuss
I love the idea of a CLI for groceries. Do you have plans to support 're-order' scripts or meal-plan integration? I can imagine a workflow where a recipes.yaml file gets piped into your CLI to automatically fill the cart with everything needed for the week. Much faster than clicking through a mobile UI.
danielszlaski
·3 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·3 เดือนที่ผ่านมา·discuss
Nice. The trojan horse framing works well, once you see that any 2D state is just coordinates + a value, it’s hard to unsee it. Did you consider using this to enforce move legality via CHECK constraints or triggers, or did that get too hairy?
danielszlaski
·4 เดือนที่ผ่านมา·discuss
[dead]
danielszlaski
·4 เดือนที่ผ่านมา·discuss
Terminal Minecraft with brewing and dragon progression in Rust. Didn't expect to want this, but here we are. Bookmarked.
danielszlaski
·4 เดือนที่ผ่านมา·discuss
Broken English from someone who actually shipped the thing beats polished prose from someone who just asked an LLM about it.
danielszlaski
·4 เดือนที่ผ่านมา·discuss
[dead]