Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
tomn
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
12 ms
·
91.
▲
by
tomn
4y ago
> LaserCube Hmm, that looks like a 2D galvo scanner. I was thinking more like a laser pointer and a mirror attached to a motor. > what I'm looking at the moment is a way to verify the intuition about if that's even possible
92.
▲
by
tomn
4y ago
From my understanding, the 5mw limit doesn't necessarily apply when a laser is scanned and has appropriate interlocks. For example the valve lighthouse (VR base station) is classified as class 1, but contains class 3 laser sources. I t
93.
▲
by
tomn
4y ago
Right, sometimes you want that. I suppose my point was that the definition of truthiness works well with the default, most obvious way of indexing a dictionary, which was the original complaint. Perhaps I was a bit harsh -- that exposes an
94.
▲
by
tomn
4y ago
The alternative here (which would make your example work) is that dictionary lookups return some falsy sentinel value when the key does not exist, just like in javascript. In javascript, this has made a lot of people very angry and been wid
95.
▲
by
tomn
4y ago
Nice. They also tidied up the GPIOs a lot, which is such a good quality of life improvement (though I did spend a while hunting through the datasheet looking for the bit where they tell you that GPIO7 can only be used as an output during a
96.
▲
by
tomn
4y ago
The bitcoin comparison seems reasonable from the outside, but IMO misses the motivations of the people behind these services. With cryptocurrency projects, people have a massive financial incentive to build them, promote them, take people&#
97.
▲
by
tomn
4y ago
Yeah, this is great if you're making your own PCBs -- all you need is the ESP32 module, power supply and a USB connector. There's no need for a usb-serial converter, JTAG connector (you can debug over USB), or a serial header with
98.
▲
by
tomn
4y ago
If an individual increases their TX power it would help them, but make others' experience worse. In a situation like an apartment block, if everyone increased their TX power then everyone would have a worse experience. The point of thi
99.
▲
by
tomn
4y ago
but if there was no regulation we could increase the transmit power and have better signal!
100.
▲
by
tomn
4y ago
Surround is a plugin which adds more text objects: https://github.com/tpope/vim-surround cs"': change surrounding quotes, e.g. "foo" -> 'foo' cs([: change surrounding brackets, e.g. (fo
101.
▲
by
tomn
4y ago
For more details on this specific application these pages might be more relevant: https://en.wikipedia.org/wiki/Optical_isolator https://en.wikipedia.org/wiki/Faraday_rotator
102.
▲
by
tomn
4y ago
Back in the days before async/await, twisted (an asynchronous I/O framework) used these to emulate async/await -- you could yield a differed value (like a promise/future), and it would pass it back when the value was ava
103.
▲
by
tomn
4y ago
I used this for a while with the 'alot' frontend[0] (before work moved to a different mail system and broke my set-up). It really does live up to the claims on the home page. If you like TUIs (especially vim) but find things like
104.
▲
by
tomn
4y ago
True, some do, though some don't (and some have both). Even dedicated LED drivers using PWM can be better than simple PWM by using smarter modulation to get high resolution without reducing the frequency to something noticeable.
105.
▲
by
tomn
4y ago
You're right -- look at any LED datasheet and you'll see the efficiency get lower at higher currents. The real reason for PWM dimming is simplicity, expanse and size. Turning an LED on and off is a lot simpler than a real constant
106.
▲
by
tomn
4y ago
That's a development board; if you look at the chip that's on that board (STM32F722ZE), there's no stock.
107.
▲
by
tomn
4y ago
true. using hyperfine on my machine shows that grep is about 2x faster than egrep (and yeah, still nothing, 1.5 vs. 3ms)
108.
▲
by
tomn
4y ago
the overhead isn't even an extra fork, as it uses exec
109.
▲
by
tomn
4y ago
If you look at the disassembly, there's no difference in python 3 (I only tested 3.7+), so it's a matter of style. There used to be a difference in python2 -- the list option would turn into n LOAD_CONSTs and a BUILD_LIST, whereas
110.
▲
by
tomn
4y ago
some more reasons from a UK perspective: - if you want to turn across the road, you have to merge onto the road which can be dangerous and awkward, so it's better to be on the road for longer before you want to turn than you might expe
111.
▲
by
tomn
4y ago
It's not the batteries that have changed, it's the circuitry. In older devices, batteries were required to power SRAM, which uses very little power (just leakage currents). This has largely been replaced by flash memory, so if you
112.
▲
by
tomn
4y ago
My colleague wrote this solution for C++ and cmake: https://github.com/ebu/libear/commit/40a4000296190c3f91eba79... This is a cmake function which generates C++ files using no external tools. It's probab
113.
▲
by
tomn
4y ago
I think Erlang has them for a more specific reason: in general it eschews all forms of data definition (records are just a fancy syntax for tuples with an atom at the start), which makes hot code reloading and transparent network communicat
114.
▲
by
tomn
4y ago
this isn't going to be any better than just loading from the two buffers into registers then storing the other way around, like: a = load(ap) b = load(bp) store(ap, b) store(bp, a) ap += step; bp += step; any instruction
115.
▲
by
tomn
5y ago
Annoyingly this always re-writes commits (i.e. never fast-forwards), which means that if you have branches based on the branch you're merging they will need to be rebased, and git will complain about deleting the branch because it look
116.
▲
by
tomn
5y ago
Thanks! I'm not sure what integrated components you could use for this, as anything useful would probably use more current than the LED can provide.
117.
▲
by
tomn
5y ago
Here's a video of a circuit I made which flashes an LED, using only power collected by the LED: https://youtube.com/watch?v=BM7VDOoFIWI The LED is the component on the left; there's a very dim flash (pretty much j
118.
▲
by
tomn
5y ago
This project generates recipes in this format from a custom language: https://github.com/mossblaser/recipe_grid I use it regularly and it works well!
119.
▲
by
tomn
5y ago
The response to this comment is a bit sad. Yes, "we just needs a sufficiently advanced compiler" is a meme, but 1) not everyone knows that and 2) that's not what this comment is asking for: > but here one domain specific l
120.
▲
by
tomn
5y ago
The TV licensing website says that you can get a refund if you're not going to need it; is that not true? https://www.tvlicensing.co.uk/check-if-you-need-one/refunds-...
More ›