Embedded Rust Hack Chat

Join us on Wednesday, May 12 at noon Pacific for the Embedded Rust Hack Chat with James Munns!

Programming languages, like fashion, are very much a matter of personal taste. Professional developers often don’t have much say in which language they’ll use for a given project, either for legacy or team reasons, but if they did have a choice, they’d probably choose the language that works best with the way they think. Some languages just “fit” different brains better than others, and when everything is in sync between language and developer, code just seems to flow effortlessly through the keyboard and onto the screen.

One language that consistently scores at the top of developers’ “most loved” lists is Rust. For a language that started as a personal project and has only existed for a little more than a decade, that’s really saying something. The emphasis Rust puts on safety and performance probably has a lot to do with that. And thanks to its safe concurrency, its memory safety, and its interoperability with C and other languages, Rust has made considerable in-roads with the embedded development community.

To learn more about Rust in embedded systems, James Munns will stop by the Hack Chat. James is an embedded systems engineer, with a history of working on software for a wide range of systems, including safety-critical avionics, and rapidly prototyped IoT systems. He’s a founding member of the Rust Embedded Working Group, as well as a founder of Ferrous Systems, a consultancy focused on systems development in Rust, with a specialty in embedded systems development. James also used to write for Hackaday, so he must be a pretty cool guy. So swing by the Hack Chat and find out where Rust might be able to help you out with your next embedded project.

join-hack-chatOur Hack Chats are live community events in the Hackaday.io Hack Chat group messaging. This week we’ll be sitting down on Wednesday, May 12 at 12:00 PM Pacific time. If time zones have you tied up, we have a handy time zone converter.

Click that speech bubble to the right, and you’ll be taken directly to the Hack Chat group on Hackaday.io. You don’t have to wait until Wednesday; join whenever you want and you can see what the community is talking about.
Continue reading “Embedded Rust Hack Chat”

South Australia Vs. Too Much Home Solar

Once upon a time, the consensus was that renewable energy was too expensive and in too sparse supply to be a viable power source to run our proud, electrified societies on. Since then, prices of solar panels have tanked, becoming more efficient along the way, and homeowners have been installing them on their rooftops in droves.

Where once it was thought we’d never have enough solar energy, in some cities, it’s becoming all too much. In South Australia, where solar output can be huge on a sunny day, electricity authorities are facing problems with grid stability, and are taking measures to limit solar output to the grid.

Isn’t More Usually Better?

The problem faced by South Australian utilities is one of how to properly control an electrical grid with many thousands of distributed power sources. Typically, in conventional modern power grids, voltage and frequency is controlled within set limits by carefully matching the supply from major power plants with the demand from users. Fast-response plants can be brought online to meet shortfalls, and switched off when demand drops, and everything hums along nicely.

Unfortunately, solar power isn’t so easy to throttle, and even less so when it’s coming from thousands of separate households each with their own rooftop install and an inverter to feed back into the grid. This has led to authorities contemplating measures such as charging homeowners to export energy to the grid in peak periods in an effort to slow the huge uptake of home solar systems. Export limits have also been proposed for suburbs with the highest concentration of home solar, as substations in certain residential areas struggle to cope under the huge inflows of energy. Continue reading “South Australia Vs. Too Much Home Solar”

Hackaday Links Column Banner

Hackaday Links: May 9, 2021

Well, that de-escalated quickly. It seems like no sooner than a paper was announced that purported to find photographic evidence of fungi growing on Mars, that the planetary science and exobiology community came down on it like a ton of bricks. As well they should — extraordinary claims require extraordinary evidence, and while the photos that were taken by Curiosity and Opportunity sure seem to show something that looks a lot like a terrestrial puffball fungus, there are a lot of other, more mundane ways to explain these formations. Add to the fact that the lead author of the Martian mushroom paper is a known crackpot who once sued NASA for running over fungi instead of investigating them; the putative shrooms later turned out to be rocks, of course. Luckily, we have a geobiology lab wandering around on Mars right now, so if there is or was life on Mars, we’ll probably find out about it. You know, with evidence.

If you’re a fan of dystopic visions of a future where bloodthirsty robots relentlessly hunt down the last few surviving humans, the news that the New York Police Department decided to stop using their “DigiDog” robot will be a bit of a downer. The move stems from outrage generated by politicians and citizens alike, who dreamt up all sorts of reasons why the NYPD shouldn’t be using this tool. And use it they apparently did —  the original Boston Dynamics yellow showing through the many scuffs and dings in the NYPD blue paint job means this little critter has seen some stuff since it hit the streets in late 2020. And to think — that robot dog was only a few weeks away from filing its retirement papers.

Attention, Commodore fans based in Europe: the Commodore Users Europe event is coming soon. June 12, to be precise. As has become traditional, the event is virtual, but it’s free and they’re looking for presenters.

In a bid to continue the grand Big Tech tradition of knowing what’s best for everyone, Microsoft just announced that Calibri would no longer be the default font in Office products. And here’s the fun part: we all get to decide what the new default font will be, at least ostensibly. The font wonks at Microsoft have created five new fonts, and you can vote for your favorite on social media. The font designers all wax eloquent on their candidates, and there are somewhat stylized examples of each new font, but what’s lacking is a simple way to judge what each font would actually look like on a page of English text. Whatever happened to “The quick brown fox” or even a little bit of “Lorem ipsum”?

And finally, why are German ambulances — and apparently, German medics — covered in QR codes? Apparently, it’s a way to fight back against digital rubberneckers. The video below is in German, but the gist is clear: people love to stop and take pictures of accident scenes, and smartphones have made this worse, to the point that emergency personnel have trouble getting through to give aid. And that’s not to mention the invasion of privacy; very few accident victims are really at their best at that moment, and taking pictures of them is beyond rude. Oh, and it’s illegal, punishable by up to two years in jail. The idea with the QR codes is to pop up a website with a warning to the rubbernecker. Our German is a bit rusty, but we’re pretty sure that translates to, “Hey idiot, get back in your frigging car!” Feel free to correct us on that.

[Editor’s note: “Stop. Rubbernecking kills”.]

Reinventing The Wheel

You’ve got a perfectly working software library to do just exactly what you want. Why aren’t you using it? Some of you are already yelling something about NIH syndrome or reinventing the wheel — I hear you. But at least sometimes, there’s a good enough reason to reinvent the wheel: let’s say you want to learn something.

Mike and I were talking about a cool hack on the podcast: a library that makes a floppy drive work with an Arduino, and even builds out a minimalistic DOS for it. The one thing that [David Hansel] didn’t do by himself was write the FAT library; he used the ever-popular FatFS by [Elm-ChaN]. Mike casually noted that he’s always wanted to write his own FAT library from scratch, just to learn how it works at the fundamental level, and I didn’t even bat an eyelash. Heck, if I had the time, I’d want to do that too!

Look around on Hackaday, and you’ll see tons of hacks where people reinvent the wheel. In this superb soundbar hack, [Michal] spends a while working on the IR protocol by hand until succumbing to the call of IRMP, a library that has it all done for you. But if you read his writeup, he’s not sad; he learned something about IR protocols. This I2C paper tape reader is nothing if not a reinvention of the I2C wheel, but isn’t that the best way to learn?

Yes it is. Think back to the last class you took. The teacher or professor certainly explained something to you in reasonable detail — that’s the job after all. And then you got some homework to do by yourself, and you did it, even though you were probably just going over the same stuff that the prof and countless others have gone through. But by doing it yourself, even though it was “reinventing the wheel”, you learned the material. And I’d wager that you wouldn’t have learned it without.

Of course, when the chips are down and the deadline is breathing hot down your neck, that might be the right time to just include that tried-and-true library. But if you really want to learn something yourself, you have every right to reinvent the wheel.

Hackaday Podcast 117: Chiptunes In An RCA Plug, An Arduino Floppy Drive, $50 CNC, And Wireless Switches

Hackaday editors Mike Szczys and Elliot Williams discuss the latest hacks from around the Internet. 3D-Printed linear rails don’t sound like a recipe for a functional CNC machine but there was one this week that really surprised us. We were delighted by the procedurally generated music from a $0.03 microcontroller inside of an RCA plug (the clever flexible PCB may be the coolest part of that one). There’s an interesting trick to reverse engineering Bluetooth comms of Android apps by running in a VM and echoing to WireShark. And we look at what the buzz is all about with genetically engineered mosquito experiments taking place down in the Florida Keys.

New this week is a game of “What’s that sound?”. Use the form link on the show notes below to send in your answer, one winner will receive a podcast T-shirt.

Take a look at the links below if you want to follow along, and as always, tell us what you think about this episode in the comments!

Direct download (~55 MB)

Places to follow Hackaday podcasts:

Continue reading “Hackaday Podcast 117: Chiptunes In An RCA Plug, An Arduino Floppy Drive, $50 CNC, And Wireless Switches”

This Week In Security: BYOVD, Spectre Vx, More Octal Headaches, And ExifTool

I learned a new acronym while reading about a set of flaws in the Dell BIOS update system. Because Dell has patched their driver, but hasn’t yet revoked the signing keys from the previous driver version, it is open to a BYOVD attack.

BYOVD, Bring Your Own Vulnerable Driver, is an interesting approach to Windows privilege escalation. 64-bit versions of Windows have a security feature that blocks unsigned kernel drivers from the kernel. The exploit is to load an older, known-vulnerable driver that still has valid signatures into the kernel, and use the old vulnerabilities to exploit the system. The caveat is that even when a driver is signed, it still takes an admin account to load a driver. So what use is the BYOVD attack, when it takes administrative access to pull off?

SentinelLabs is witholding their proof-of-concept, but we can speculate. The particular vulnerable driver module lives in the filesystem at C:\Windows\Temp, a location that is writable by any process. The likely attack is to overwrite the driver on the filesystem, then trigger a reboot to load the older vulnerable version. If you’re still running Windows on your Dell machines, then make sure to go tend to this issue. Continue reading “This Week In Security: BYOVD, Spectre Vx, More Octal Headaches, And ExifTool”

Julius Sumner Miller Made Physics Fun For Everyone

Let’s face it — for the average person, math and formulas are not the most attractive side of physics. The fun is in the hands-on learning, the lab work, the live action demonstrations of Mother Nature’s power and prowess. And while it’s true that the student must be willing to learn, having a good teacher helps immensely.

Professor Julius Sumner Miller was energetic and enthusiastic about physics to the point of contagiousness. In pictures, his stern face commands respect. But in action, he becomes lovable. His demonstrations are dramatic, delightful, and about as far away from boring old math as possible. Imagine if Cosmo Kramer were a physics professor, or if that doesn’t give you an idea, just picture Doc Brown from Back to the Future (1985) with a thick New England accent and slightly darker eyebrows. Professor Miller’s was a shouting, leaping, arm-waving, whole-bodied approach to physics demonstrations. He was completely fascinated by physics, and deeply desired to understand it as best he could so that he could share the magic with people of all ages.

Professor Miller reached thousands of students in the course of his nearly 40-year teaching career, and inspired millions more throughout North America and Australia via television programs like The Mickey Mouse Club and Miller’s own show entitled Why Is It So? His love for science is indeed infectious, as you can see in this segment about the shock value of capacitors.

Continue reading “Julius Sumner Miller Made Physics Fun For Everyone”