Running Linux 6.11 On The ESP32-S3 With A Few Tweaks

With the Xtensa Lx7 twin CPU cores in the ESP32-S3 running at a relatively zippy 240 MHz and accompanying PSRAM of up to 16 MB, you might find yourself wondering whether it could run Linux. As [Paulneja] demonstrates with Linux kernel 6.11, the answer is a ‘yes’, though with the usual caveats.

What complicates matters with the ESP32-S3 is that it lacks certain amenities that spoiled OSes like Linux have come to take for granted, such as a Memory Management Unit (MMU). To deal with this, the NOMMU Linux configuration was used, along with a custom fork() implementation. Although the previous 0.7 version sort-of worked, the current 0.8 release is the first that manages to actually boot reliably and has a usable amount of RAM available after boot.

You can see the comparison between the two versions in the header image, with v0.8 having a blistering 3.7 MB available after booting and with overall resource usage and performance having improved massively. Note that only one core is available to Linux, with the other used by the typical FreeRTOS ESP-IDF stack to provide WiFi and Bluetooth.

This was all run on an ESP32-S3 with the N16R8 configuration, meaning 16 MB Flash that’s also used for writable storage and 8 MB of octal PSRAM. As for practical applications, it’s noted by [Paulneja] that this is a research project, though one could imagine this being an embedded Linux project along the lines of a network router running something like BusyBox.

Fixing A Ubiquiti 16-Port PoE Switch With An Extra Hole

After saving a £300, 16-port Ubiquiti network switch from getting tossed into the trash, [Buy It Fix It] got the honor of trying to repair it. With four ports and their associated PoE function having some major issues it looked like it might take some debugging, but after taking the lid off, the cause seemed rather obvious.

One of the Broadcom BCM5911 controller chips had a rather suspicious chip of the plastic packaging missing, with additional probing of connected components showing that numerous MOSFETs and a diode having had their proverbial guts blown out and were shorted as well. Whatever happened to some connected Ethernet device would appear to have left a serious trail of damage that nearly wrecked the entire switch.

The biggest challenge here was probably to find a replacement for the Broadcom IC, as this isn’t an IC that stores like Digikey or Mouser stock any more. Fortunately it was still available for sale over at AliExpress for £1.84, with the usual caveat that it could be salvage, fake, a factory reject, etc. In this case it appears that it was a legit Broadcom IC, with the four affected ports springing back to life including powering a PoE camera.

With a total cost of about £5 plus the time invested it wasn’t a bad deal to save a pretty nice PoE switch with 16 Ethernet and 2 SFP ports.

Continue reading “Fixing A Ubiquiti 16-Port PoE Switch With An Extra Hole”

How High-Voltage Current Transformers Monitor The Grid

Being able to monitor voltages and currents is essential for many applications, with the national electrical grid being no exception. The obvious complication here is that the voltages and currents are massively higher than for those other applications, making safely monitoring these somewhat of an engineering challenge. The used systems for current monitoring are detailed by [Jordan Taylor], also known as [The Electric Brit], in an explainer of grid-level current transformers (CTs) and associated elements that help to provide galvanic isolation for safe current measurements.

Even if the basic principles remain the same, when you’re dealing with currents of 5 kA and more, the associated clearances and penalties for getting a detail wrong increasing correspondingly. The CTs help to implement over-current protection (OCP), over-voltage protection (OVP) as well as differential protection, which is useful to detect leakage and shorts, which could also happen inside the CT if the windings become damaged.

Any such failure condition can trigger a circuit breaker to be tripped, or other corrective measures to be taken. Incidentally this is also how it can be detected when someone is tapping off power in an illicit manner. As with all transformers they’re never perfect due to issues like core saturation, and thus performing accurate measurements and picking the right type of transformer is an art in itself, as explained in the video.

Ultimately CTs and the associated equipment are what makes an AC power grid responsive to any changes and with it into the reliable foundation of modern-day society.

Continue reading “How High-Voltage Current Transformers Monitor The Grid”

Pulse: A New VHDL Simulator

With VHDL being arguably more deterministic and bullet-proof than Verilog, it’s good to see another open source VHDL simulator joining the fray that is not a variation of ghdl. Written by [Óscar Grimal] in C++ with an MIT license, the Pulse project is a still in progress package that provides the entire toolchain, from the compiler to the requisite waveform output.

This waveform output is provided in the form of a text-based user interface (TUI), which at the very least helps a lot with making it cross-platform compatible. As dependencies only a C++20 capable compiler and CMake are indicated.

Of course, with VHDL being a rather hefty language especially once you start piling up the associated standard library, the currently supported language and library features are somewhat limited still so that you’re limited to basic IEEE packages and types, with default values are not supported yet.

Per the roadmap on the GitHub project’s Readme more VHDL language features including generics and additional types will be added, along with an enhanced simulation engine. It’s also said that mixed-language support with Verilog will be added, though SystemVerilog looks to be getting the short end of the stick as usual.

It will definitely be interesting to compare this package to ghdl.

Fly Brain Connectome Used To Trade Stocks And Play Games

Recently researchers finished mapping the central nervous system (CNS) connectome of not just the female Drosophila melanogaster (i.e. fruit fly) brain, but also that of the male D. melanogaster for a comparative analysis. Here the sexually dimorphic changes turned out to induce specific mating behavior that ensures that there will only be smooching between genetically fit D. melanogaster males and females, while the rest of the connectome remained effectively the same.

Of course, with this connectome in hand it led some people to ask themselves what else one can do with this connectome graph of about 160,000 neurons other than make a fruit fly into a fruit fly. So far we have seen [Nftechie] turn this connectome into a crypto stock trader with the Stonkfly project that uses the connectome’s reward circuits to potentially make profitable trades, though [Nftechie] says that they haven’t verified yet how good a fruit fly is at trading stocks, only that it does said stonks.

Over at [PC Gamer] they summarized a number of things that people have also done, including trying to make the connectome control a game of DOOM and Beat Saber. Each game frame stimulates sensory neurons, with the generated outputs then mapped to game controls, with dopamine-producing reward circuits wired in for reinforcement learning.

Although the D. melanogaster brain is only the merest fraction of the size of the human brain, it does provide us with a glimpse of what actual artificial intelligence research may lead to, as we unravel how even a 160,000 neuron connectome is enough to make these terrors of rotting plant matter do their wonderful things.

Re-creating NASA’s Heat Shield Problem

After the Orion capsule of the Artemis I lunar mission returned to Earth, it was found that massive chunks of its heatshield had been ripped off, posing a serious risk to any future missions. In a recent video in which [polymatt] takes a break from repairing old laptop shells and the like, he tries to recreate the Orion’s heatshield using a variety of methods and materials.

For this test a number of samples were created, each using the same kind of segmented structure as the larger Orion heatshield. The filler was created from the published materials for the heat shield by NASA, requiring just serious mixing.

The resulting samples were then cured with thermocouples inserted, before they got blasted with the heat from a propane torch, trying to simulate the various re-entry patterns.

Perhaps unsurprisingly, the results matched the findings by NASA for why the Orion’s heat shield had failed, being the build-up of gases due to the sustained pyrolysis processes that eventually fractured the material. Despite some experimental flaws that injected residual heat from the copper structure, this still seems to be a pretty good setup to test ablative heat shields in DIY lab conditions.

Continue reading “Re-creating NASA’s Heat Shield Problem”

Analyzing The FScale Instruction In Intel’s 8087 FPU

During his continuing analysis of the architecture and microcode of Intel’s highly influential 8087 floating point unit (FPU) co-processor, [Ken Shirriff] has now arrived at the point where he can put together how the 8087’s microcode implements various x87 instructions. One of these, the FSCALE instruction turned out to be far more complicated than assumed, with one might assume to be a straightforward powers-of-two scaling turning out to entail over 140 micro-instructions and three levels of sub-routine calls just to handle all cases.

The annotated die shot in the heading image shows the functional blocks that are used by this one x87 instruction, to give some kind of idea of what amount of hardware even ‘just’ scaling a floating point number involves.

Much like with the x86’s CISC-style ISA, these 8087 instructions break down into individual steps that involve everything from loading values into registers, performing operations, checking for and handling error conditions as well as stack management. As can be seen in [Ken]’s breakdown of the FSCALE implementation in the 8087 it’s all very logical, taking a high-level instruction and doing all that’s needed for a robust implementation, without bothering the developer with the details.

Of note is that the 8087’s implementations led to the IEEE 754 floating point standard, providing what definitely at the time was one of the most mathematically accurate FPUs that somehow still was financially responsible enough to make it into a relatively affordable PC.