An Entire RISC-V Operating System In 2000 Lines

While Microsoft and Apple don’t release the source code for their operating systems, a good estimate is that it takes around 50 million lines of code to run these software behemoths. The Linux kernel alone holds around 30 million lines, with systemd containing over one million lines on its own, which doesn’t include estimates for the desktop environment or other parts of a standard installation. But millions of lines of code, or even hundreds of thousands, aren’t necessary for building a fully functioning operating system. This one sets up a complete OS in exactly 2000 lines of code.

Called egos-2000, short for Earth and Grass Operating System, the diminutive operating system is written for RISC-V computers and while it does contain most of the tools we would recognize in an OS, it was built specifically for computer science students by PhD candidate Yunhao Zhang. The slimmed-down operating system makes it possible for students to easily read and understand every feature of an operating system without it becoming too overwhelming, and can be easily used and modified to experiment with. The name itself comes from its design principles, where parts of the operating system that interact with hardware directly are part of the “Earth” layer and parts that don’t depend on hardware being placed in the “Grass” layer, with applications taking up a third layer.

The OS is available on this GitHub page under an MIT license and works on real RISC-V hardware as well as within various emulators. Building a complete operating system in so few lines of code is an impressive feat, and making it comprehensive enough to teach students with goes well beyond that accomplishment as well. Often when concepts in computer science are reduced to their bare minimum components, we end up with completely illegible (but interesting) experiments like this programming language instead.

Badminton Inspired Heat Shield Aims To Fly This Year

Badminton is not a sport that most of us think about often, and extremely rarely outside of every four years at the summer Olympics and maybe at the odd cookout or beach party here or there. But the fact that it’s a little bit unique made it the prime inspiration for this new heat shield design, which might see a space flight and test as early as a year from now.

The inspiration comes from the shuttlecock, the object which would otherwise be a ball in any other sport. A weighted head, usually rubber or cork, with a set of feathers or feather-like protrusions mounted to it, contributes to its unique flight characteristics when hit with a racquet. The heat shield, called Pridwen and built by Welsh company Space Forge, can be folded before launch and then expanded into this shuttlecock-like shape once ready for re-entry. It’s unlikely this will protect astronauts anytime soon, though. The device is mostly intended for returning materials from the Moon or from asteroids, or for landing spacecrafts on celestial bodies with atmospheres like Mars or Venus.

With some testing done already, Space Forge hopes this heat shield will see a space flight before the close of 2023. That’s not the end of the Badminton inspiration either, though. It’s reported that this device can slow a re-entering craft so much that it can be caught in a net. Not exactly the goal when playing the sport, but certainly a welcome return home for whichever craft might use this system. Of course, getting down from space is only half the battle. Take a look at this other unique spacecraft that goes up in a fairly non-traditional way instead.

Self-Driving Library For Python

Fully autonomous vehicles seem to perennially be just a few years away, sort of like the automotive equivalent of fusion power. But just because robotic vehicles haven’t made much progress on our roadways doesn’t mean we can’t play with the technology at the hobbyist level. You can embark on your own experimentation right now with this open source self-driving Python library.

Granted, this is a library built for much smaller vehicles, but it’s still quite full-featured. Known as Donkey Car, it’s mostly intended for what would otherwise be remote-controlled cars or robotics platforms. The library is built to be as minimalist as possible with modularity as a design principle, and includes the ability to self-drive with computer vision using machine-learning algorithms. It is capable of logging sensor data and interfacing with various controllers as well, either physical devices or through something like a browser.

To build a complete platform costs around $250 in parts, but most things needed for a Donkey Car compatible build are easily sourced and it won’t be too long before your own RC vehicle has more “full self-driving” capabilities than a Tesla, and potentially less risk of having a major security vulnerability as well.

Industrial Robot Gets Open-Source Upgrade

Industrial robots are shockingly expensive when new, typically only affordable for those running factories of some sort. Once they’ve gone through their life cycle building widgets, they can be purchased for little more than scrap value, which is essentially free compared to their original sticker price. [Excessive Overkill] explains all of this in a video where he purchased one at this stage to try to revive, but it also shows us how to get some more life out of these robots if you can spend some time hunting for spare parts, installing open-source firmware, and also have the space for a robot that weighs well over a thousand kilograms.

This specific robot is a Fanuc R2000ia with six degrees of freedom and a reach of over two meters. Originally the plan was to patch together a system that could send modern gcode to the Fanuc controller, but this was eventually scrapped when [Excessive Overkill] realized the controller that shipped with this robot was for an entirely different machine and would never work. Attempts to find upgraded firmware were frustrated, and after a few other false starts a solution was found to get the robot working again using LinuxCNC and Mesa FPGA cards, which have built-in support for Fanuc devices like this.

More after the break…

Continue reading “Industrial Robot Gets Open-Source Upgrade”

Tiny Bitcoin Miner Plays The Lottery

Usually when we think of Bitcoin miners, we imagine huge facilities of server racks doing nothing but essentially wasting energy, all for the chance that one of those computers amongst the rows will stumble upon the correct set of numbers to get rewarded with imaginary money. The idea being that the more computers, the more chances to win. But just buying one lottery ticket is the only thing technically required to win, at least in theory. And [Data Slayer] is putting this theory to the test with this Bitcoin miner built around a single Raspberry Pi.

This tiny Raspberry Pi Zero does get a little bit of support from an Ant Miner, a USB peripheral which is optimized to run the SHA256 hashing algorithm and solve the complex mathematical operations needed to “win” the round of Bitcoin mining. Typically a large number of these would be arrayed together to provide more chances at winning (or “earning”, to use the term generously) Bitcoin but there’s no reason other than extreme statistical improbability that a single one can’t work on its own. The only other thing needed to get this setup working is to give the Pi all of the configuration information it needs such as wallet information and pool information.

This type of miner isn’t novel by any means, and in fact it’s a style of mining cryptocurrency called “lottery mining” where contributing to a pool is omitted in favor of attempting to solve the entire block by pure random chance alone in the hopes that if it’s solved, the entire reward will be claimed by that device alone. In the case of this device, the current hash rate calculated when it was contributing to a pool means that when lottery mining, it has about a one-in-two-billion chance of winning. That’s essentially zero, which is basically the same chance of winning a lottery that pays out actual usable currency.

Continue reading “Tiny Bitcoin Miner Plays The Lottery”

3D Design With Text-Based AI

Generative AI is the new thing right now, proving to be a useful tool both for professional programmers, writers of high school essays and all kinds of other applications in between. It’s also been shown to be effective in generating images, as the DALL-E program has demonstrated with its impressive image-creating abilities. It should surprise no one as this type of AI continues to make in-roads into other areas, this time with a program from OpenAI called Shap-E which can render 3D images.

Like most of OpenAI’s offerings, this takes plain language as its input and can generate relatively simple 3D models with this text. The examples given by OpenAI include some bizarre models using text prompts such as a chair shaped like an avocado or an airplane that looks like a banana. It can generate textured meshes and neural radiance fields, both of which have various advantages when it comes to available computing power, training methods, and other considerations. The 3D models that it is able to generate have a Super Nintendo-style feel to them but we can only expect this technology to grow exponentially like other AI has been doing lately.

For those wondering about the name, it’s apparently a play on the 2D rendering program DALL-E which is itself a combination of the names of the famous robot WALL-E and the famous artist Salvador Dali. The Shap-E program is available for anyone to use from this GitHub page. Even though this code comes from OpenAI themselves, plenty are speculating that the AI revolution to come will largely come from open-source sources rather than OpenAI or Google, something for which the future is somewhat hazy.

The Peak Of Vacuum Tube Radio Design

One of the more popular trends in the ham radio community right now is operating away from the shack. Parks on the Air (POTA) is an excellent way to take a mobile radio off-grid and operate in the beauty of nature, but for those who want to take their rig to more extreme locations there’s another operating award program called Summits on the Air (SOTA) that requires the radio operator to set up a station on a mountaintop instead. This often requires lightweight, low-power radios to keep weight down for the hike, and [Dan] aka [AI6XG] has created a radio from scratch to do just that.

[Dan] is also a vacuum tube and CW (continuous wave/Morse code) operator on top of his interest in summiting various mountains, so this build incorporates all of his interests. Most vacuum tubes take a lot of energy to operate, but he dug up a circuit from 1967 that uses a single tube which can operate from a 12 volt battery instead of needing mains power, thanks to some help from a more modern switch-mode power supply (SMPS). The SMPS took a bit of research, though, in order to find one that wouldn’t interfere with the radio’s operation. That plus a few other modern tweaks like a QCX interface and a switch to toggle between receive to transmit easily allows this radio to be quite versatile when operating while maintaining its portability and durability when summiting.

For those looking to replicate a tube-based radio like this one, [Dan] has made all of the schematics available on his GitHub page. The only other limitation to keep in mind with a build like this is that it tends to only work on a very narrow range of frequencies without adding further complexity to the design, in this case within the CW portion of the 40-meter band. But that’s not really a bad thing as most radios with these design principles tend to work this way. For some other examples, take a look at these antique QRP radios for operating using an absolute minimum of power.