Bike light design

Sep. 20th, 2017 08:12 pm[personal profile] jack
jack: (Default)
For a while I had the impression my back bike light remembered whether it was on or not when you removed and replaced the battery. And I wondered how that worked. A push-button that moved a physical toggle between three positions seemed implausible. But so did some tiny bit of persistent memory. My best guess is that there was a capacitor which held charge for a short time.

Now, I think I was completely wrong. I think that when you put the battery in, it *always* comes on. I just assumed that it would usually be off and didn't actually check that was true. So I got the impression it was lit *sometimes* on battery-connect, and connected that to the state it had before the battery was removed.

Wow, it's really easy to manufacture evidence for something even when you think you're avoiding that.

Presumably the "power on lit" is so that loose connections don't turn it off. OTOH, that would mean if it has a loose connection when it's being carried about, it might come on and drain the battery. Or maybe no-one thought about it and this just happened to be the case. Or maybe there's a regulation? I don't know.

Long day!

Sep. 17th, 2017 02:46 am[personal profile] azurelunatic
azurelunatic: Polyamory infinite hearts, in a polymer-like grid (polymer)
Breakfast with partner and metamour Leopard Girl.

Seanan McGuire event in Silverdale. We brought tribute, and were briefly Seanan's favorite. (Diet Dr Pepper and candy corn. Seanan is a being of predictable tastes.)

Mini muffin tin quest!

Partner made a note they should chat with our mutual friend in London about stuff. Hooray, viable communities.

Dinner for the extended polycule, with many dishes thanks to Trader Joe's. (Rice, orange chicken with extra zesty sauce but no carrots since we ran out, BBQ pork buns, pot stickers, spring rolls, and green beans. The rice and green beans weren't pre-packaged, and I do a little customization to the chicken by adding orange peel and scallions. The gyoza and bao steam over the rice, and the spring rolls could bake with the chicken. The green beans start frozen and get gently fried with seasonings. Usually it's butter and Montreal steak seasoning, but Stray Puppy Girl is very lactose intolerant, and Leopard Girl dislikes red pepper. So I went for sesame oil, garlic, onion, pepper, salt, ginger, a packet of soy sauce that needed using, and the excess teriyaki sauce from the other night. It turned out well. To my immense gratification, my partner really likes all the iterations of the green beans that I have made so far. Generally they disappear immediately.)

Club night. Without going into excessive detail, one of the groups near the people I was with were having a hilarious time, and kept setting each other off giggling. That prompted our group to giggle. The glee was infectious.

Everyone is spending the night. We hauled the camping pads out of the alleged guest room (it is currently not in a state for guests as my textiles have exploded all over it) and they're set up next to the futon in case it turns from cozy to crowded in the middle of the night. Things are well set up for breakfast, and there should be cheesecake at some point (thus the mini muffin tins).
jack: (Default)
Removing code is good! But everywhere I've worked has had a "pile of makefiles" build system, which have invariably had problems when you remove a file, because the .d files are still hanging around, and make chokes on a source file because it doesn't have the headers it needed last time, even though they're actually not necessary to actually build the file.

And it's a matter of culture whether it's "when you check out code, you often need to make clean or make undepend somewhere to get it to compile" or "when you check in code, you need to find a workaround to make it build cleanly even if you've removed files".

Do people with more recent build tools than "make" avoid this problem?

However, after thinking it through carefully I eventually decided on one of the ways to makefiles cope with this correctly.

The trick

You still do "-include $(OBJ_FILES:%.c=%.d)" or equivalent.

But when you produce a .d file with gcc (usually as a side effect of producing a .o file via -MMD), add an extra line at the end of the recipe, a perl script which edits the .d file in-place and replaces each "filename.o: header1.h header2.h..." with "filename.o $(wildcard: header1.h header2.h...)"

That way, if any dependency has *changed* a rebuild is forced as normal. But only dependencies that actually exist become dependencies within the makefile. (Deleting a header file doesn't trigger a rebuild, but it doesn't with the old system either since the .o file already exists.)

I can share the exact script if anyone wants to see.

Yuletide nominations

Sep. 14th, 2017 10:40 pm[personal profile] jack
jack: (Default)
I nominated for Yuletide. After lots of "how could I possibly choose", I decided that I might as well pick three works I liked and thought would make good fic, and not feel like I had to pick the BEST three. I can probably dredge up more obscure things I loved, and would really love to see fic from, but I find it hard to bring to mind things I've not thought of for ages.

There's lots of things I love, things like webcomics and webfiction which might deserve attention. I eventually chose three I thought would make good stories.

Elements (experiments in character design), the tarot-like cards showing a character for each chemical element. They're just so pretty, each looks like it tells a story. I was sad the physical cards seemed to be sold out and never for sale. They were nominated two years ago, and I was sad to see not last year.

And two webcomics, Leftover Soup (from Tailsteak, the author of the awesome 1/0, ooh, maybe I should submit that instead), and YAFGC (Yet Another Fantasy Gamer Comic, like Oglaf, very not safe for work, but sort of in a surprisingly wholesome way).

Did other people manage to nominate things?

I am also basking in the disconcertingly competent assumption that, I expect to be able to, just get a story done, without a whole lot of putting it off. I'm not at all used to signing up to something with a deadline and not assuming I'll panic but it's worth it!

I looked at my notes from last year for "what might I be interested in nominating next year". It was mostly the same sorts of things. Although one was, "Steven Universe, if it doesn't exceed the limit of number of works", I guess that must have happened now :) Although I find it really hard to predict. I went to look up Vorkosigan, the universe I was surprised was still eligible when I wrote for it two years ago, and it looks like there's more than a 1000 fics on ao3 from before that, am I misremembering how eligibility/search works?
kaberett: a patch of sunlight on the carpet, shaped like a slightly wonky heart (light hearted)
you might also like Heartstopper, an LGBT comic about a British grammar school, which I have just inhaled this evening after one of you all reblogged it on the tumbls xx

(comment I left on the Patreon: 3-2 came across my dash earlier this evening, I have just read EVERYTHING (with laughing-out-loud and misting-up and making-my-partner-read-bits), thank you *so much* for this. -- I am 27, I was in Year 9 when Section 28 was repealed, I was the only out queer in my secondary school of 1000+ students, and I recognise these crushes SO HARD. Thank you so, so much for making this be a thing in the world, and I am really looking forward to reading more. <3)

Profile

corrvin: "this space intentionally not left blank" (Default)
Corrvin

June 2017

S M T W T F S
    123
45678910
11121314151617
18192021222324
252627282930 

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Sep. 22nd, 2017 11:51 am
Powered by Dreamwidth Studios