Ask HN: Have you created programs for only your personal use?
423 pointsCurious to know if anyone has written programs for their own, regular, & personal use. And if so what they are? E.g. A colleague of mine tracks all of his homes energy use through a custom program which disaggregates the energy consumption per device and outputs a report to a tablet.
Comments (651) 385 threads
Earlier comments- I play a lot of chess and I want to click a button to copy the chess PGNs from chess.com easily while playing a game: https://pastebin.com/UKVUXQxc
- Another one is to grab property info from Redfin and paste it in google sheet for easier analysis and comparison b/w properties: https://pastebin.com/EmH66Q0r
I started by matching it to the solar elevation, but ultimately I like it more just on a fixed schedule. I've also programmed it to make a more dramatic warm shift near bedtime, and to fade up a bedroom light when it's time to wake up.
Due to the inevitability of scope creep this system also now tracks the charging status and position of my robot vacuum, and I'm working to expand it to collect the 15-minute-interval usage data from my electric provider's website.
The bridge just hooks up over ethernet and provides a locally accessible no-nonsense REST api that is surprisingly well documented (sadly requires logging in with a free account: https://developers.meethue.com/develop/hue-api/ ).
Authentication is simple. Press the big button on the bridge, hit an API endpoint within 30 seconds, and you get an auth token.
The only other requests I needed were a GET to list the id and status of all bulbs, and a POST per bulb that is on to change its color temperature (you cannot set color temp of a bulb that is off).
- https://news.ycombinator.com/item?id=31026875
- https://news.ycombinator.com/item?id=31026979
Fortunately this was fairly easy to implement since Hue bridges provide a locally-accessible actually-documented REST API for me to use!
The basic loop, run once per minute is:
- Make one API call which returns the id/on/off/brightness of every bulb
- For each bulb that is on, set its color temperature (this has to be one API call per bulb because there is no way to bulk update a list of bulbs. Bulbs can be put into at most one "room" and you can bulk set a whole room but not a subset of bulbs in that room)
As far as scheduling color temperature goes - I just define a few keyframes based on minutes since midnight local time, and then linearly interpolate to get the color temp. Over 24 hours the steps are so small that the change is basically imperceptible.
1. StrongLift 5x5 tracker. This is a python CLI based script that tracks 5x5 (Strong Lift) program. I haven't used it in awhile, but a few friends still do.
2. HNews calendar style home page. I wrote this as a way to reduce my daily HN screen time but don't want to miss anything. So I created an app (django on raspberry pi) that downloads from HN API and group HN articles by date and point in a calendar style page. Pretty useful, but the code is still in Py2 and awful.
3. A crawler that downloads swim school class availability so I can sign my kids up.
Something that scrapes financial transactions from bank and credit-card accounts in a fully automated way where possible, and semi-automated way where necessary, dumps those transactions into a database, automatically categorizes them, and creates dashboards for commonly used views and analyses.
I've blogged a bit about it here: https://sagar.se/blog/where-is-the-money/
All comments shown.
Couldn't load more comments. Check your connection and try again.