Interrupting while someone is talking is rude for humans, but smart for computers. [Ivan Voras] shows how to use interrupts to service the ESP32 analog to digital converters when sampling sound. Interestingly, he uses the Arduino IDE mixed with native ESP-IDF APIs to get the best performance.
Like most complex interrupt-driven software, [Ivan’s] code uses a two-stage interrupt strategy. When a timer expires, an interrupt occurs. The handler needs to complete quickly so it does nothing but set a flag. Another routine blocks on the flag and then does the actual work required.
Because the interrupt service routine needs to be fast, it has to be in RAM. [Ivan] uses the IRAM_ATTR attribute to make this work and explains what’s going on when you use it.
…the CPU cores can only execute instructions (and access data) from the embedded RAM, not from the flash storage where the program code and data are normally stored. To get around this, a part of the total 520 KiB of RAM is dedicated as IRAM, a 128 KiB cache used to transparently load code from flash storage.The ESP32 uses separate buses for code and data (“Harvard architecture”) so they are very much handled separately, and that extends to memory properties: IRAM is special, and can only be accessed at 32-bit address boundaries.
This is very important because some ESP-IDF calls — including adc1_get_raw — do not use this attribute and will, therefore, crash if they get pushed out to flash memory. At the end, he muses between the benefit of using an OS with the ESP32 or going bare metal.
If you want to know more about the Arduino on ESP32, we covered that. We also dug deeper into the chip a few times.
If you study the history of computing you might have heard of the FACOM 128B, a Japanese relay computer from 1958. It holds the distinction of being a contender for the oldest computer that still works in its original form, as it resides in a Fujitsu building in Numazu Japan. [CuriousMarc] visited the old computer and created a video about it as well as painting a picture of other contemporary machines. You can see the video below.
[Marc] explains how a relay machine was already behind the times in 1958, and also shows how the 5,000 relay machine is laid out. The machine on display came from a Tokyo university and did the kind of computations you might use a computer for today to do engineering design.
Continue reading “Visiting The FACOM 128B 1958 Relay Computer”
Some people love Amazon, while others think it has become too big and invasive. But you have to admit, they build gigantic and apparently reliable systems. Interestingly, they recently released a library of white papers from their senior staff called the Builder’s Library.
According to their blog post:
The Amazon Builders’ Library is a collection of living articles that take readers under the hood of how Amazon architects, releases, and operates the software underpinning Amazon.com and AWS. The Builders’ Library articles are written by Amazon’s senior technical leaders and engineers, covering topics across architecture, software delivery, and operations. For example, readers can see how Amazon automates software delivery to achieve over 150 million deployments a year or how Amazon’s engineers implement principles such as shuffle sharding to build resilient systems that are highly available and fault tolerant.
The Amazon Builders’ Library will continue to be updated with new content going forward.
Continue reading “Behind Amazon’s Doors Is A Library”
What does Pluto — not the dog, but the non-Planet — have in common with the Vikram lunar lander launched by India? Both were found by making very tiny comparisons to photographs. You’d think landing something on the moon would be old hat by now, but it turns out only three countries have managed to do it. The Chandrayaan-2 mission would have made India the fourth country. But two miles above the surface, the craft left its planned trajectory and went radio silent.
India claimed it knew where the lander crashed but never revealed any pictures or actual coordinates. NASA’s Lunar Reconnaissance Orbiter took pictures several times of the landing area but didn’t see the expected scar like the one left by the doomed Israeli lander when it crashed in April. A lot of people started looking at the NASA pictures and one Indian computer programmer and mechanical engineer, Shanmuga Subramanian, seems to have been successful.
Continue reading “Chandrayaan-2 Found By Citizen Scientist; Reminds Us Of Pluto Discovery”
Microwave ovens are everywhere, and at the heart of them is a magnetron — a device that creates microwaves. [DiodeGoneWild] tore one apart to show us what was inside and how it works. If you decide to do this yourself, be careful. The magnetron may have insulators made of beryllium oxide and inhaling dust from the insulator even one time can cause an incurable lung condition.
Luckily, you can’t get a lung problem from watching a video. In addition to just seeing the guts of the magnetron, there are also explanations about how everything works with some quick sketches to illustrate the points.
Continue reading “A Magnetron Tear Down”
FreeCAD started out a little shaky, but it has gotten better and better. If you are trying to draw a schematic, it probably isn’t the best way to do it. However, it is a great graphical alternative to OpenSCAD for 3D printing and even incorporates OpenSCAD if you don’t want to choose. However, if you have a 3D part — regardless of how you want to create it in real life — having a proper mechanical drawing is very valuable. FreeCAD’s TechDraw workbench makes this very easy and [Joko] has a tutorial that shows exactly how to do it.
Machinists everywhere are used to looking at these drawings that typically show a top view, a front view, and a side view. The program will automatically project the views you select and then allows you to pick dimensions. It creates them and keeps them up to date if you change them in the model later.
Continue reading “FreeCAD TechDraw Workbench Tutorial”
The current state of virtual personal assistants — Alexa, Cortana, Google, and Siri — leaves something to be desired. The speech recognition is mostly pretty good. However, customization options are very limited. Beyond that, many people are worried about the privacy of their data when using one of these assistants. Stanford Open Virtual Assistant Lab has rolled out Almond, which is open and is reported to have better privacy features.
Like most other virtual assistants, Almond has skills that determine what it can do. You can use Almond in a browser, on a Google phone, or as a command line application. It all lives on GitHub, so if you don’t like something you are free to fix it.
Continue reading “Almond: Open Personal Assistant From Stanford”