HNHacker News
TopNewBestAskShowJobs

cillian64

811 karma · joined July 14, 2014

Embedded design engineer in Cambridge, UK.
submissionscomments
cillian64··on Microsoft Word just fixed its default paste option
In many contexts Ctrl+Shift+V will paste without formatting, but I’m still a bit hazy on exactly when it does/doesn’t work
cillian64··on Firefox Webserial Addon
If that’s the argument against, it could just be denied by default and require the user to go into settings to allow. The annoyance isn’t too bad given webserial is probably only used on occasion, and it means no concerns about consent spam or fingerprinting.
cillian64··on Bookworm – the new version of Raspberry Pi OS
Rpi-imager and the website don’t really make it clear but these days the 64-bit OS is the preferred one on Pis that support it
cillian64··on Bookworm – the new version of Raspberry Pi OS
32-bit raspberry pi os is based on raspian instead of debian for the architecture reasons explained by a sibling comment. But 64-bit raspberry pi OS is based on actual Debian, with extra repos added for rpi-specific software and patched versions of some Debian software
cillian64··on Oxford study proves heat pumps triumph over fossil fuels in the cold
I was looking into this and one factor is that you still need hot water. So with mini-splits your options are either resistive water heating or having a gas boiler as well. I haven’t seen any systems which do mini-splits and also heat a hot water tank.
cillian64··on Free and open source software projects are in transition
What ChibiOS does is release under GPL3 and then sell a commercial dual license. This is definitely open source and also means most non-open-source commercial use would need to pay for a license. It’s probably also one reason why FreeRTOS is much more popular in business than ChibiOS.

https://www.chibios.org/dokuwiki/doku.php?id=chibios:licensi...

cillian64··on Infrared may no longer be a punchline, as IEEE approves 9.6Gbps wireless light
I think the idea is you have normal wifi as well, so you should never lose the connection but certain preferred positions will go much faster using light.
cillian64··on Vulkan Video Decoding
If you use ffmpeg’s libavcodec interface then you can get it to give you the decoded framebuffers as exported DRM-prime descriptors which you can turn into textures. This is how Firefox does video decode with VAAPI, using libavcodec as a wrapper.

Edit: missed the part about JS ecosystem. You can move DRM prime descriptors between processes, but I assume you can’t do this from the ffmpeg CLI and would need to write your own little C wrapper around libavcodec

cillian64··on Vulkan Video Decoding
On Linux there is already an alternative to VAAPI: The Video4Linux Memory-2-memory (V4L2-M2M) API, which provides a standardised API for hardware encode and decode accelerators (and supports using DMA-bufs for copy-free decoding or using decoded frames as textures). I don't know how much support there is for AMD/nvidia/intel but it works well on the Raspberry Pi at least.

It would feel weird for Vulkan to become the standard API for encode/decode given that (as you say) video accelerators aren't necessarily tied to the GPU (although not necessarily weirder than doing it through an extension of the webcam API).

cillian64··on Zig Quirks
The downside is when reading code you’re keeping in your head information about the type of each variable. If you skim through the code and miss one of these redefinitions then you may be mistaken about the variable’s type.

That said, I still think sparing use of this is justified, especially with an editor which can show types on mouseover.

cillian64··on Contracts you should never sign
Often a company will offer severance more generous than they are contractually/legally obliged to in exchange for the leaver signing some extra restrictions beyond what was in the original employment contract.
cillian64··on Ask HN: Learn C in 2023?
One useful tool is running clang or gcc with —Werror -Wpedantic which will point out a lot of things which are useful to know about, even if occasionally a false positive.
cillian64··on Video codec in 100 lines of Rust
Decoders also have the difficulty that you need to support most of the format’s features before they can support content found in the wild. Also you often need to add hacks to support encoders which technically violate the specification but are commonly used.

In contrast, you can build a very simple encoder using very few of the format features and still have it be usable/useful (albeit with poor quality/compression ratio).

cillian64··on SSHGuard
I experienced this at a previous company. Yocto/bitbake wanted to do a lot of git clones over SSH very quickly, but a firewall interpreted this as a brute force because it couldn’t tell that each SSH connection was actually successfully authenticating.
cillian64··on The pool of talented C++ developers is running dry
I tried to find a book which assumes knowledge of and experience with C++98 and brings you up to speed as far as C++17. Do you know of such a thing?

I read some of Effective Modern C++ but it seemed to be more a list of footguns and poor design decisions in the later C++ editions.

cillian64··on Experiments spell doom for physical-collapse explanation of quantum weirdness
I’m currently reading Anathem so this is an interesting topic.

For simplicity, let’s say that all quantum interactions have two possible outcomes, 0 or 1.

The first point is that we can only talk about what interactions appear to have done in the past in our worldline/universe, which is randomly distribute themselves between 0 and 1. If we happened to be on a worldline where all interactions had always resulted in 0 for the whole history of the universe then that universe almost certainly wouldn’t support complex life. So perhaps there’s an observership bias here: if quantum interactions hadn’t decently distributed themselves between 0 and 1 then we wouldn’t be asking this question (just like the values of all the other fundamental constants).

As far as I can tell there’s nothing in current theories which would rule out all future interactions happening to result in a 0. Let’s hope our consciousness don’t end up on that worldline (unless you believe in quantum invulnerability).

cillian64··on Why Rust?
In theory, if the complexity of libraries stayed the same then pretty much the only advantage of not having recursive dependencies is a simpler license statement, and cargo-license should make that easy to automate.

In terms of checking over the code, cargo dependencies should result in less duplication and so fewer lines of code for the same level of functionality, and having it split into crates doesn’t obviously make it harder to review and Cargo.lock means the dependencies won’t change unexpectedly.

I do agree that there is a question about whether easy access to pulling in dependencies means libraries are more inclined to bloat and unnecessary complexity. But not having cargo dependencies at all would seem like a very big hammer to solve that problem. I’d much prefer to grow an ecosystem of minimal/simple libraries which don’t try to do everything and which limit their dependencies.

cillian64··on Why Rust?
From my experience in C there are two ways libraries deal with not being able to easily pull in their own dependencies. Some of them include their own reimplementations of lots of things (data structures, logging, error handling, date-times). Others decide to keep it simple and only implement a minimal set of functionality which limits their need for dependencies or reinventing the wheel.

Cargo letting libraries easily have their own dependencies means that many Rust libraries are very rich and fully featured. This has plenty of advantages, but the big dependency tree can be a problem in some circumstances. Crate features can sometimes help but usually not much in my experience.

I’ve seen libraries appearing in Rust which are specifically very simple and minimise dependencies (ureq is an example I like). This gives the developer the choice whether they want libraries which just do a small basic job or whether they are okay with including lots of dependencies in exchange for rich functionality. There’s a risk of segmenting the ecosystem (see also async/tokio) but it seems to be working pretty well to me.

cillian64··on Ask HN: Technical forums that are not dominated by pedantry?
A while back the wireless charger I use for my phone stopped working, a few months after I bought it. Certain that the charger had died I contacted their support for a warranty replacement. They asked my to reboot my phone and I complied just to humour them. Imagine my surprise when the wireless charger then went back to working perfectly (and has been fine since).
cillian64··on “Rust is safe” is not some kind of absolute guarantee of code safety
With Linux you can unload and reload modules (rmmod, insmod) so it’s a little un-monolithic in that sense.
cillian64··on “Rust is safe” is not some kind of absolute guarantee of code safety
From most users’ points of view, a lot of things the kernel does (e.g. a sound card driver) are non-critical so they’d prefer an error in that driver only killed that driver and not the whole kernel. Similarly, I’d be upset if a server rebooted because of a blip in its CD-ROM driver. And if you can just reload the module which errored, all the better.

It would be cool if kernel Rust could implement a panic handler which just killed the offending module, but I’m assuming from the discussion around panics that this isn’t possible.

cillian64··on Turns are better than radians
If you differentiate sin(x) with respect to x then you get cos(x), but only if your trig functions are using radians. Any other unit results in an extra coefficient appearing. That’s not an insurmountable problem, but radians are the fundamental unit here, not just an arbitrary choice.
cillian64··on React I love you, but you're bringing me down
I’m an embedded/backend dev looking to tinker with some frontend stuff for the experience and out of curiosity. I’ve been leaning towards react because it’s so common and what my team use, but I’m finding it pretty hard to get into.
cillian64··on Unicode character “ꙮ” (U+A66E) is being updated
It does raise interesting questions about what counts as decoration/formatting and what counts as part of the actual text. You could view these ocular O characters as purely decorative (like the fancy first character in a paragraph) but they could also be seem as a quirk of spelling which should be represented in unicode.

But the multiocular O really does seem like one monk got bored one time and did some doodling.

cillian64··on Steps to designing an embedded software architecture, Step 1
That’s pretty much my situation, I originally did electronic engineering and firmware but have switched professionally to backend software. Partly because of the pay, but mostly because the tooling and quality of most embedded software is so painful to work with. I’d rather have an overgrown dependency tree than a debugger which crashes more often than not.
cillian64··on What it takes to make a game by yourself
I think one of the biggest problems indie game devs have is putting a lot of focus into art and polish without actually working out whether the game is fun to play. The dev gets to make enjoyable incremental progress without having to confront the difficult questions about whether the game is actually workable. Some games can get by purely on story and art, but in the vast majority of cases I think solo devs would be best served by making an absolutely minimal gameplay prototype and making it fun before thinking at all about polish.
cillian64··on The Next Chapter for Learning on YouTube
The justification some youtubers (LTT comes to mind) use for clickbait video titles/thumbnails is that they feel that so long as the content itself is good then it doesn’t matter what techniques they use to get people to watch it. Their logic is that there’s nothing wrong with lying to get someone to watch your video so long as they enjoy it once they do.

To me it the race to the bottom of clickbait video titles/thumbnails feels dishonest and harmful but it’s hard to see what to do about it other than manual curation and/or alternative platforms which don’t use recommendations to exponentially amplify click rates.

cillian64··on Rsync.net
I run a borg backup from my synology NAS to rsync.net and it was pretty easy to set up. I installed borg and borgmatic from the community repositories and use the synology scheduler to run it nightly. I followed the tutorial at https://docs.borgbase.com/setup/synology/.
cillian64··on AMD Launches Ryzen 7000 Series Desktop Processors with Zen 4 Architecture
IPC means “instructions per cycle”, not “instructions per core”. So the numbers you quote would mean a 0% IPC increase (or slight decrease)
cillian64··on Using Mypy in Production
> Making things "simpler" is making things more complex.

This hits the nail on the head for me with Python. The standard libraries take a very “batteries included” approach but the language constructs don’t, and that means people use the flexibility of the language to do things their own way. I find that really increases my mental workload when reading other people’s software (how have they done this) and when writing my own (which way should I do this).

← PreviousPage 2 of 7Next →