Saved By The Bel — Understanding Decibels

If you’ve hung around electronics for any length of time, you’ve surely heard of the decibel (often abbreviated dB). The decibel is a measure of a power ratio. Actually, the real measure is a bel, but you almost never see that in practice. If you are versed in metric, you won’t be surprised to learn a decibel is 1/10 of a bel. Sometimes in electronics, we deal with really large ratios, so the decibel is logarithmic to cope with this. Doubling the number of decibels doesn’t double the ratio, as you will soon see. It’s all about logarithms, and this ends up being extremely useful when measuring something like antenna or amplifier gain.

Besides antennas, decibels are often used to measure sound and light. The reason is that human ears and eyes have a logarithmic response to those quantities. Your ear, for example, has a huge dynamic range. That is to say, you can hear a whisper or a space shuttle launch. That ratio is about 1 trillion to 1, but that’s only 120 dB. This is also why potentiometers made for volume controls have a logarithmic taper. A linear pot would seem off because, for example, a tenth of a turn at one extreme will affect the apparent volume much more than a tenth of a turn at the other extreme. This holds true whether or not those knobs go up to eleven.

Continue reading “Saved By The Bel — Understanding Decibels”

Fixing Fake FTDIs

If you know where to go on the Internet, you can pick up an FTDI USB to Serial adapter for one dollar and sixty-seven cents, with free shipping worldwide. The chip on this board is an FTDI FT232RL, and costs about two dollars in quantity. This means the chips on the cheap adapters are counterfeit. While you can buy a USB to serial adapter with a legitimate chip, [Syonyk] found a cheaper solution: buy the counterfeit adapters, a few genuine chips, and rework the PCB. It’s brilliant, and an excellent display of desoldering prowess.

Why is [Syonyk] replacing non-genuine chips with the real FTDI? The best reason is FTDIgate Mk. 1, where the official FTDI driver for Windows detected non-genuine chips and set the USB PID to zero. This bricked a whole bunch of devices, and was generally regarded as a bad move. FTDIgate Mk. 2 was a variation on a theme where the FTDI driver would inject garbage data into a circuit if a non-genuine part was found. This could also brick devices. Notwithstanding driver issues, the best reason for swapping out fake chips for real ones is the performance at higher bit rates; [Syonyk] is doing work at 3 Mbps, and the fake chips just don’t work that fast.

To replace the counterfeit chip, [Syonyk] covered the pins in a nice big glob of solder, carefully heated both sides of the chip, and slid the offending chip off when everything was molten. A bit of solder braid, and the board was ready for the genuine chip.

With the new chip, the cheap USB to serial adapter board works perfectly, although anyone attempting to duplicate these efforts might want to look into replacing the USB mini port with a USB micro port.

What Voltage For The All-DC House?

The war of the currents was fairly decisively won by AC. After all, whether you’ve got 110 V or 230 V coming out of your wall sockets, 50 Hz or 60 Hz, the whole world agrees that the frequency of oscillation should be strictly greater than zero. Technically, AC won out because of three intertwined facts. It was more economical to have a few big power plants rather than hundreds of thousands of tiny ones. This meant that power had to be transmitted over relatively long distances, which calls for higher voltages. And at the time, the AC transformer was the only way viable to step up and down voltages.

acdc
No, not that AC/DC

But that was then. We’re right now on the cusp of a power-generation revolution, at least if you believe the solar energy aficionados. And this means two things: local power that’s originally generated as DC. And that completely undoes two of the three factors in AC’s favor. (And efficient DC-DC converters kill the transformer.) No, we don’t think that there’s going to be a switch overnight, but we wouldn’t be surprised if it became more and more common to have two home electrical systems — one remote high-voltage AC provided by the utilities, and one locally generated low-voltage DC.

Why? Because most devices these days use low-voltage DC, with the notable exception of some big appliances. Batteries store DC. If more and more homes have some local DC generation capability, it stops making sense to convert the local DC to AC just to plug in a wall wart and convert it back to DC again. Hackaday’s [Jenny List] sidestepped a lot of this setup and went straight for the punchline in her article “Where’s my low-voltage DC wall socket?” and proposed a few solutions for the physical interconnects. But we’d like to back it up for a minute. When the low-voltage DC revolution comes, what voltage is it going to be?

Continue reading “What Voltage For The All-DC House?”

Los Angeles Hackaday Unconference Happening On 3/18

Reserve your spot at the Los Angeles Hackaday Unconference on Saturday, March 18th. The Hackaday community is huge in LA and this event will fill up, so don’t delay.

The Unconference is a unique opportunity to decide the course of the day as it happens. Everyone who attends should be ready to stand and deliver at least eight minutes on a topic they find exciting right now. The energy this creates is the key to a level of involvement that can’t be matched at traditional conferences that have a divide between those presenting and those attending.

LA Joins Chicago and San Francisco

This announcement of the Los Angeles Hackaday Unconference joins two others happening the same day. Last week we announced San Francisco as a host location and the event is now full… but anyone in the area should still get their name on the waiting list. Four days ago we announced Chicago as the second location and that event will likely reach capacity today. [Shulie Tornel] and [Jasmine Brackett] are organizing things at the LA event which is being held at the Supplyframe Design Lab from 1 – 8 pm on 3/18.

Build Something that Matters

You can speak on any topic you want, but sometimes having a theme helps to get the ideas flowing. When considering your topic, keep Build Something that Matters in mind. Have you been looking into a technology, project, or idea that can make life a little (or a lot) better for the world? That would be an exquisite topic.

At the beginning of the day we’ll go around the room and get the talk title or subject from everyone there, then as a group we’ll hammer out a schedule for the day. As presentations progress, we encourage new impromptu talks to spring up, and can even split those off into a second talk space or discussion group. We’ll have food and drink on hand, as well as some interesting hardware to give out as door prizes.

The Hackaday Unconference is the ultimate idea and energy exchange in a crowd of your peers. You’ll have a hard time finding a cooler way to spend a Saturday this year. See you there!

Ask Hackaday: How Should Hackers Handle IP Agreements?

My buddy Harold recently landed a new job at a great technology company. It came at a perfect time for him, having just been laid off from the corporate behemoth where he’d toiled away as an anonymous cog for 19 years. But the day before he was to start, the new company’s HR folks sent him some last-minute documents to sign. One was a broad and vaguely worded non-compete agreement which essentially said he was barred from working in any related industry for a year after leaving the company.

Harold was tempted not to sign, but eventually relented because one needs to put food on the table. Thankfully he’s now thriving at the new company, but his experience got me thinking about all the complications hackers face with the day jobs that so many of us need to maintain. Non-competes and non-disclosures are bad enough, but there’s one agreement that can really foul things up for a hacker: the Intellectual Property Agreement.

Continue reading “Ask Hackaday: How Should Hackers Handle IP Agreements?”

An Eggcelent Eggspriment

After multiple iterations [Keef] has nailed down the fabrication process for an unusual component. Using only a heater water bath, some silicone and easily available reagents, [Keef] demonstrate how he manufactures a gastronomic enigma: the long egg.

The similarities between [Keef’s] process and the typical hacker iteration cycle are eggceptional. He starts out with a goal and iterates, modifying his methods until he gets the perfect long egg. Sound familiar? Cooking can be as much of a science as it is an art.

In his quest, [Keef] utilizes sausage casing, plastic bags, sticky tape, “lots of sweat and almost some tears” to hold eggs for cooking via an Anova Precision Cooker immersion circulator. However, [Keef] notes, the Anova is normally used for sous vide cooking so you might not have one sitting around. In that case, you can use a regular pan on a stovetop along with a digital thermometer, but you’ll have to be quite vigilant to keep the temperature steady.

But wait. Why would one want a long egg in the first place? I’ll leave this explanation to [Keef]. “Well, the main use is in a Gala Pie (a long pork pie baked in a loaf tin and often cut into slices for picnics). Or you could just slice the egg and lay it out on a platter and amaze your friends with how every slice is exactly the same size.”

Go check out [Keef’s] two videos. He has two, one that chronicles the eggciting initial attempts, and another that describes his final method. With [Keef’s] help, the number of long eggs outside of Denmark may substantially increase. But, if you’d rather have some pizza, we won’t be offended.

Reading The Unreadable SROM: Inside The PSoC4

Wow. [Dmitry Grinberg] just broke into the SROM on Cypress’ PSoC 4 chips. The supervisory read-only memory (SROM) in question is a region of proprietary code that runs when the chip starts up, and in privileged mode. It’s exactly the kind of black box that’s a little bit creepy and a horribly useful target for hackers if the black box can be broken open. What’s inside? In the manual it says “The user has no access to read or modify the SROM code.” Nobody outside of Cypress knows. Until now.

This matters because the PSoC 4000 chips are among the cheapest ARM Cortex-M0 parts out there. Consequently they’re inside countless consumer devices. Among [Dmitry]’s other tricks, he’s figured out how to write into the SROM, which opens the door for creating an undetectable rootkit on the chip that runs out of each reset. That’s the scary part.

The cool parts are scattered throughout [Dmitry]’s long and detailed writeup. He also found that the chips that have 8 K of flash actually have 16 K, and access to the rest of the memory is enabled by setting a single bit. This works because flash is written using routines that live in SROM, rather than the usual hardware-level write-to-register-and-wait procedure that we’re accustomed to with other micros. Of course, because it’s all done in software, you can brick the flash too by writing the wrong checksums. [Dmitry] did that twice. Good thing the chips are inexpensive.

The nitty-gritty on the ROP (return oriented programming) tricks that [Dmitry] had to pull, and a good look into the design of the system itself, are all up on [Dmitry]’s blog. We can’t wait to see what other buried treasure he’s going to find as he continues to play around with these chips. And in case you’re wondering what type of mad genius it takes to pull this off, consider that [Dmitry] runs Linux on AVRs, fools nRF24 chips into transmitting Bluetooth LE beacons, and re-writes his own airplane’s GPS.

[Main image is a PSoC4200 dev kit, and [Dmitry] has only been working with the 4000 and 4100 series. Just so you know.]