This excellent content from the Hackaday writing crew highlights recurring topics and popular series like Linux-Fu, 3D-Printering, Hackaday Links, This Week in Security, Inputs of Interest, Profiles in Science, Retrotechtacular, Ask Hackaday, Teardowns, Reviews, and many more.
Hardware hacking can be extremely multidisciplinary. If you only know bits and bytes, but not solder and electrons, you’re limited in what you can build. The same is true for mechanical design, where the forces of stress and strain suddenly apply to your project and the pile of code and PCBs comes crashing to the ground.
In the first half of his workshop, Naman Pushp walks you through some of the important first concepts in mechanical engineering — how to think about the forces in the world that act on physical objects. And he brings along a great range of home-built Jugaad props that include a gravity-defying tensegrity string sculpture and some fancy origami that help hammer the topics home.
In the second half of the workshop, Naman takes these concepts into computer simulation, and gives us good insight into the way that finite-element analysis simulation packages model these same forces on tiny chunks of your project’s geometry to see if it’ll hold up under real world load. The software he uses isn’t free by any definition — it’s not even cheap unless you have a student license — but it’s nonetheless illuminating to watch him work through the flow of roughly designing an object, putting simulated stresses and strains on it, and interpreting the results. If you’ve never used FEA tools before, or are looking for a compressed introduction to first-semester mechanical engineering, this talk might be right up your alley. Continue reading “Remoticon Video: The Mechanics Of Finite Element Analysis”→
Merry Christmas and happy holidays! I took Christmas day off from writing the security roundup, coming in a day early with this week’s installment, dodging New year’s day. The SolarWinds story has continued to dominate the news, so lets dive into it a bit deeper.
Microsoft has published their analysis of Solorigate, and the details are interesting. The added code was carefully written to blend in with the rest of the code, using the name OrionImprovementBusinessLayer.Initialize, which sounds like a perfectly boring-yet-legitimate function. The actual backdoor is obfuscated using zip compression and base64 encoding.
Once this bootstrap code begins, it runs a series of checks before actually doing anything malicious. It waits 2 weeks after installation to do anything, and then checks the system domain name for any indication it’s running in a test environment. It then checks for certain security applications, like Wireshark, and refuses to run if they are detected. This series of checks all seem to be an effort to avoid detection, and to only run in a deployed environment. Even the Command and Control URL that the backdoor uses is constructed to appear benign. Beyond this, it seems that the malware simply waited for instructions, and didn’t take any automated actions. All the attacks were performed manually.
It is not uncommon for a Hackaday writer to trawl the comments section of a given article, looking for insights or to learn something new. Often, those with experience in various fields will share kernels of knowledge or raise questions on a particular topic. Recently, I happened to be glazing over an article on aluminium casting with interest, given my own experience in the field. One comment in particular caught my eye.
And no, the water won’t cause a steam explosion. There’s a guy on youtube (myfordlover, I think) who disproves that myth with molten iron, pouring the iron into water, pouring water into a ladle of molten iron and so on. We’ll be happy to do a video demonstrating this with aluminum if so desired.
Having worked for some time in an aluminium die casting plant, I sincerely hope [John] did not attempt this feat. While there are a number of YouTube videos showing that this can be done without calamity, there are many showing the exact opposite. Mixing molten aluminium and water often ends very poorly, causing serious injury or even fatalities in the workplace. Let’s dive deeper to see why that is.
Designing your own integrated circuits as a one-person operation from your home workshop sounds like science fiction. But 20 years ago, so did rolling your own circuit boards to host a 600 MHz microcontroller with firmware you wrote yourself. Turns out silicon design isn’t nearly as out of reach as it used to be and Matt Venn shows us the ropes in his Zero to ASIC workshop.
Held during the 2020 Hackaday Remoticon, this is a guided tour of the tools used in the Skywater PDK — the Process Design Kit that is an open-source ASIC toolkit produced in a partnership between Google and SkyWater Technology. We covered the news when first announced back in June, but this the most comprehensive look we’ve seen into the actual design process.
Drawing N-channel MOSFET in silicon
Matt builds up the demo starting from the very simple design of an N-channel MOSFET with click-and-drag tools similar to graphics editing software. The good news it that although you can draw your own structures like this, for digital designs you won’t have to. A wide variety of IP has been contributed to the open source project allowing basic building blocks to be pulled in using HDL. However, the power of drawing structures will certainly be the playground for those needing analog design as part of their projects.
As with EDA software used for circuit boards, the PDK includes design rule checks to ensure you aren’t violating the limits of the 130 nm chip fab. There’s some other black magic in there too, as Matt specifically mentions an antenna rules check to safeguard your design from being fried by induced current on “large” (microscopically so) metalized runs during the fabrication process.
Part of a massive logic flow chart for an IC counter design
The current workflow involves grinding through a large number of configuration files, something Matt admits took him a long time to wrap his head around. However, what’s available for proofing your design is very impressing. He demonstrates SPICE simulation to calculate timings, and shows numerous examples of verification drawings generated by the compilation process, either in the form of seeing the structures as they will be laid out, or as logical flow charts. This is crucial as a single run will take 2-3 months to come back from fab — you want to get things right before buttoning up the project. Incidentally, that’s know as “tapeout”, a term you’ve likely heard before and he says it comes from reels of magnetic tape containing the design being removed from the computer and sent to production. Who knew? (This tidbit in strikethrough appears to be incorrect).
But wait, there’s more to this than just designing the things. Part of the intrigue of the Skywater-PDK project is that Google bought into covering a group run about once per quarter so that open-source designs can be ganged onto a multi-project wafer free of charge to the people submitting them. That’s pretty awesome and we’re giddy to hear news of people getting their wafer-level chip scale devices — also known as flip chips — back for testing. Matt is planning a more in-depth paid course on the topic. For now, get a taste of what’s involved from this excellent workshop found after the break.
Visual impairment has been a major issue for humankind for its entire history, but has become more pressing with society’s evolution into a world which revolves around visual acuity. Whether it’s about navigating a busy city or interacting with the countless screens that fill modern life, coping with reduced or no vision is a challenge. For countless individuals, the use of braille and accessibility technology such as screen readers is essential to interact with the world around them.
For refractive visual impairment we currently have a range of solutions, from glasses and contact lenses to more permanent options like LASIK and similar which seek to fix the refractive problem by burning away part of the cornea. When the eye’s lens itself has been damaged (e.g. with cataracts), it can be replaced with an artificial lens.
But what if the retina or optic nerve has been damaged in some way? For individuals with such (nerve) damage there has for decades been the tempting and seemingly futuristic concept to restore vision, whether through biological or technological means. Quite recently, there have been a number of studies which explore both approaches, with promising results.
We’re always pleased to see one of our community’s projects succeed, and we celebrate that success in whatever what it comes. But seeing a company launched to commercialize an idea that started as a Hackaday.io project and a Hackaday Prize entry is especially gratifying. So we were pleased as punch to see that MAKESafe Tools has managed to bring the idea of add-on machine tool braking to market. We’d love to add this to several tools in our shop. Honestly, of all the terrifying ways machine tools can slice, dice, and shred human flesh asunder, we always considered the lowly bench grinder fairly low-risk — and then we had a chance to “Shake Hands with Danger.”
Another great thing about the Hackaday community is the way we all try to keep each other up to speed on changes and news that affects even our smallest niches. Just last week Tom Nardi covered a project using the venerable TI eZ430-Chronos smartwatch as a makeshift medical alert bracelet for a family member. It’s a great application for the proto-smartwatch, but one eagle-eyed commenter helpfully pointed out that TI is shutting down their processors wiki in just a couple of weeks. The banner at the top of each page warns that the wiki is not read-only and that any files needed should be downloaded by January 15. Also helpfully, subsequent comments include instructions to download the entire wiki and a torrent link to the archive. It’s always sad to see a platform lose support, especially one that has gained a nice following, but it’s heartening to see the community pull together to continue to support each other like this.
We came across an interesting article this week that’s was a fascinating glimpse into how economic forces shape and drive technological process, and vice versa. It turns out that some of the hottest real estate commodities these days are the plots of land occupied by AM radio stations serving metropolitan markets. It’s no secret that terrestrial radio in general, and AM radio in particular, are growing increasingly moribund, and the infrastructure needed to keep them on the air is getting harder and harder to justify. Chief among these are the large tracts of land devoted to antenna farms, which are often located in suburban and exurban areas near major cities. They’re tempting targets for developers looking to plunk down the physical infrastructure needed to support “New Economy” players like Amazon, which continue to build vast automated warehouses in areas that are handy to large customer bases. It’s a bit sad to watch a once mighty industry unravel and be sold off like this, but such is the nature of progress.
And finally, you may recall a Links article mention a few weeks back about a teardown of a super-sized IBM processor module. A quarter-million dollar relic of the 1990s, the huge System/390 module was an engineering masterpiece that met an unfortunate end at the hands of EEVblog’s Dave Jones. As a follow-up, Dave teamed up with fellow YouTuber CPU Galaxy to take a less-destructive tour of the module using X-ray analysis. The level of engineering needed for a 64-layer ceramic backplane is astonishing, and Dave’s play-by-play is pretty entertaining too. As a bonus, CPU Galaxy has some really interesting stuff; his place is basically a museum of vintage tech, and he just earned a new sub.
Circuit simulations are great because you can experiment with circuits and make changes with almost no effort. In Circuit VR, we look at circuits using a simulator to do experiments without having to heat up a soldering iron or turn on a bench supply. This time, we are going to take a bite of a big topic: op amps.
The op amp — short for operational amplifier — is a packaged differential amplifier. The ideal op amp — which we can’t get — has infinite gain and infinite input impedance. While we can’t get that in real life, modern devices are good enough that we can pretend like it is true most of the time.
a very simple op amp circuit with some detail omitted
If you open this circuit in the Falstad simulator, you’ll see two sliders to the right where you can tweak the input voltage. If you make the voltages the same, the output will be zero volts. You might think that a difference amplifier would take inputs of 1.6V and 2.4V and either produce 0.8V or -0.8V, but that’s not true. Try it. Depending on which input you set to 2.4V, you’ll get either 15V or -15V on the output. That’s the infinite gain. Any positive or negative output voltage will quickly “hit the rail” or the supply voltage which, in this case, is +/-15V.
Practical Concerns
The biggest omitted detail in the schematic symbol above is that there’s no power supply here, but you can guess that it is +/- 15V. Op amps usually have two supplies, a positive and a negative and while they don’t have to be the same magnitude, they often are. Some op amps are specifically made to work with a single-ended supply so their negative supply can connect to ground. Of course, that presupposes that you don’t need a negative voltage output.
The amount of time it takes the output to switch is the slew rate and you’ll usually find this number on the device datasheet. Obviously, for high-speed applications, a fast slew rate is important, particularly if you want to use the circuit as a comparator as we are here.
Other practical problems arise because the op amp isn’t really perfect. A real op amp would not hit the 15V rail exactly. It will get close depending on how much current you draw from the output. The higher the current, the further away from the rails you get. Op amps will also have some offset that will prevent it from hitting zero when the inputs are equal, although on modern devices that can be very low. Some older devices or those used in high-precision designs will have a terminal to allow you to trim the zero point exactly using an external resistor.
Op Amps Can Provide Steady Voltage Under Variable Load
Rather than dig through a lot of math, you can deal with nearly all op amp circuits if you remember two simple rules:
The inputs of the op amp don’t connect to anything internally.
The output mysteriously will do what it can to make the inputs equal, as far as it is physically possible.
1x amplifier
That second rule will make more sense in a minute, but we already see it in action. Set the simulator so the – input (the inverting input) is at 0V and the noninverting input (+) is at 4V. The output should be 15V. The output is trying to make the inverting input match the noninverting one, but it can’t because there is no connection. The output would like to provide an infinite amount of voltage, but it can only go up to the rail which is 15V.
We can exploit this to make a pretty good x1 amplifier by simply shorting the output to the – terminal. Remember, our rules say the input terminals appear to not connect to anything, so it can’t hurt. Now the amplifier will output whatever voltage we put into it:
You might wonder why this would be interesting. Well, we will learn how to increase the gain, but you actually see this circuit often enough because the input impedance is very high (infinite in theory, but not practice). And the output impedance is very low which means you can draw more current without disturbing the output voltage much.
Comparing voltage divider performance with and without a 1x amplifier
This circuit demonstrates the power of a 1x amplifier. Both voltage dividers produce 2.5V with no load. However, with a 100 ohm load at the output, the voltage divider can only provide around 400mV. You’d have to account for the loading in the voltage divider design and if the load was variable, it wouldn’t be possible to pick a single resistor that worked in all cases. However, the top divider feeds the high impedance input of the op amp which then provides a “stiff” 2.5V to whatever load you provide. As an example, try changing the load resistors from 100 ohms to different values. The bottom load voltage will swing wildly, but the top one will stay at 2.5V.
Don’t forget there are practical limits that won’t hold up in real life. For example, you could set the load resistance to 0.1 ohms. The simulator will dutifully show the op amp sourcing 25A of current through the load. Your garden-variety op amp won’t be able to do that, nor are you likely to have the power supply to support it if it did.
What’s Being Amplified?
This is an amplifier even though the voltage stayed the same. You are amplifying current and, thus, power. Disconnect the bottom voltage divider (just delete the long wire) and you’ll see that the 5V supply is providing 12.5 mW of power. The output power is 62.5 mW and, of course, varies with the load resistor.
Notice how this circuit fits the second rule, though. When the input changes, the op amp makes its output equal because that’s what makes the + and – terminals stay at the same voltage.
Of course, we usually want a higher voltage when we amplify. We can do that by building a voltage divider in the feedback loop. If we put a 1:2 voltage divider in the loop, the output will have to double to match the input and, as long as that’s physically possible, that’s what it will do. Obviously, if you put in 12V it won’t be able to produce 24V on a 15V supply, so be reasonable.
Non-inverting amplifier example
This type of configuration is called a non-inverting amplifier because, unlike an inverting amplifier, an increase in the input voltage causes an increase in the output voltage and a decrease in input causes the output to follow.
Note that the feedback voltage divider isn’t drawn like a divider, but that’s just moving symbols on paper. It is still a voltage divider just like in the earlier example. Can you figure the voltage gain of the stage? The voltage divider ratio is 1:3 and, sure enough, a 5V peak on input turns into a 15V peak on the output, so the gain is 3. Try changing the divider to different ratios.
What’s Next?
While it isn’t mathematically rigorous, thinking of the op amp as a machine that makes its inputs equal is surprisingly effective. It certainly made the analysis of these simple circuits, the comparator, the buffer amplifier, and a general non-inverting amplifier simple.
There are, of course, many other types of amplifiers, as well as other reasons to use op amps such as oscillators, filters, and other even more exotic circuits. We’ll talk about some of them next time and the idea of a virtual ground, which is another helpful analysis rule of thumb.