This "Lab Book" posting is my thinking about a design problem I've been considering.
Problem: I want a way to display a time interval that can be photographed as part of a test fixture. I'm trying to convey a time value, which can vary from fractions of a microsecond to seconds.
Ideas:
The value that I'm trying to convey can vary over a large dynamic range, but it will always be a "round" number. For example, it might be 10 milliseconds, or 85 microseconds, but it will never be 10.85 milliseconds. Therefore, I really only need a couple of digits to convey the value, plus something to convey the metric time units. Using a two digit LED display, including decimal points, together with a three additional LEDs representing microseconds, milliseconds, and seconds, I can convey 99 seconds down to 10 nanoseconds. For example, here's every decade of 85 from seconds to hundreds of nanoseconds:
85 seconds
8.5 seconds
.85 seconds (850 milliseconds)
85 milliseconds
8.5 milliseconds
.85 milliseconds (850 microseconds)
85 microseconds
8.5 microseconds
.85 microseconds (850 nanoseconds)
.08 microseconds (80 nanoseconds)
Normally, the precision of a number is expressed in the number of significant digits with which is it written. For example, 85 microseconds +/- 10 nanoseconds would be written as 85.00 microseconds. But here, since there are only two digits, the precision needs to be explicitly stated, rather than conveyed in significant digits. Since the timing resolution is independent of the scale, there will probably just be a note on the fixture to the effect of "All times are exactly as stated, +/- 10 nanoseconds."
Because the display is intended to be photographed at any possible exposure time, it needs to be static, with all active LEDs on at all times. It can't be a multiplexed display, the way you'd normally drive a large number of LEDs, because at exposure times shorter than the refresh rate of the complete display, you would only see portions of the display lit in the photo. With 2 digits of 7 segments each (14 LEDs), plus decimal points (two or three* LEDs), plus three time scale LEDs, that's a total of 19 or 20 LEDs that need to be driving simultaneously.
*Why would I want the third, rightmost decimal point? It is not specifically needed, but since the middle and leftmost decimal point locations are so integral to conveying non-full-digit values, it might be useful to explicitly include both leftmost and rightmost so there is always a decimal place on and it is not unclear where it resides:
85 milliseconds displays as 85. milliseconds, to explicitly differentiate it from .85 and 8.5 on the display. This also indicates another problem with this scheme, however, because virtually all 7-segment displays include the decimal point at the right side of the digit. (HEY! A survey of Digikey attempting to verify that assertion turns up this part:
It includes a "Left Decimal Point" and "Right Decimal Point" on the same digit, suitable for use as my leftmost digit. The dual-decimal point feature is sufficiently unusual that it doesn't appear to be mentioned anywhere in the description of the part on the Digikey website... If this or some other dual-decimal point digit is not sufficient for my needs, I'm going to end up having to improvise a left-most decimal point, or I could just add a third digit, and then only ever have right decimal points, but also 7 more LEDs, and a higher explicit precision display. I think I'll make that decision based on other considerations, like brightness, size, color, etc.
Anyway, to make the 19 or 20, or possibly 27 LEDs statically illuminated, I'll need 27 output bits, so I'll probably just drive them directly using a 74AC164 serial in / parallel out shift register. (If I end up wanting to drive my display electronics at 5V but still have a 3.3V MCU driving everything, I might end up instead using a 74ACT164, which requires a 5V supply, but has TTL input switching levels, meaning that my 3.3V inputs would have more margin. Though, really, even 74AC should work fine at 5V with 3.3V inputs.
Showing posts with label Electronics. Show all posts
Showing posts with label Electronics. Show all posts
Sunday, December 9, 2018
Monday, September 17, 2012
"Revolution" TV Show.
This entry is some thoughts about the new television series "Revolution." This latest invention from the imagination of "Lost" creator J.J. Abrams premiered Monday, September 17th, on NBC. The pilot episode was released early on Hulu, so I took a look at it. I'll try to write this entry without spoilers, or at least without any more spoilers than the ads and website for the show provide. Still, if you prefer to avoid even a hint of fore-knowledge, you may want to read this after you watch the pilot episode.
"Revolution" is set "fifteen years after the blackout." In a video on the show's website, Abrams says, “The question the show asks is, 'What would happen if everything powered by electricity suddenly turned off?'” Because I'm interested in worst-case scenarios, disaster preparedness, and knowing what to do when the zombies come, I'm intrigued by ideas like this. But this a problematic scenario... People are really ingenious and given the proper motivation (say, the loss of civilization as we know it), they would come up with some pretty clever stuff. Let's consider how...
While it's true that we use electricity for an enormous number of things, we can still do a lot without it, as we did in the past. Energy can be harvested mechanically in the form of movement, with windmills and water wheels or water turbines. In 1890, George Westinghouse suggested that the energy of Niagara Falls would best be transmitted to Buffalo not as electricity generated on site, but as compressed air. Compressed air can also be used to store mechanical energy in high-pressure gas cylinders.
"Revolution" is set "fifteen years after the blackout." In a video on the show's website, Abrams says, “The question the show asks is, 'What would happen if everything powered by electricity suddenly turned off?'” Because I'm interested in worst-case scenarios, disaster preparedness, and knowing what to do when the zombies come, I'm intrigued by ideas like this. But this a problematic scenario... People are really ingenious and given the proper motivation (say, the loss of civilization as we know it), they would come up with some pretty clever stuff. Let's consider how...
While it's true that we use electricity for an enormous number of things, we can still do a lot without it, as we did in the past. Energy can be harvested mechanically in the form of movement, with windmills and water wheels or water turbines. In 1890, George Westinghouse suggested that the energy of Niagara Falls would best be transmitted to Buffalo not as electricity generated on site, but as compressed air. Compressed air can also be used to store mechanical energy in high-pressure gas cylinders.
Furthermore, a lot of technologies that we think of as “electrical” don't have to be. In many cases, we use electricity to provide mechanical energy that could be provided by other sources. Refrigeration, for example, uses electricity to turn a motor to run a compressor. But there's no reason the compressor can't be turned by a water wheel or a windmill. Or a steam engine...
In the event of a “Revolution” scale blackout, the world would quickly see the return of the steam era. Boiler technology and steam engines would be the next big growth industry. Coal and wood fired steam railroads would quickly provide critical transportation links, first on a small scale as museum exhibits were pressed back into service, but then growing as fast as more equipment could be built. Central steam engines in factories could provide mechanical energy for all sorts of tasks, such as machining, cooling, cutting, building, and so on.
And if the “Revolution” world really just precludes electronics, it wouldn't be limited to steam engines. Diesel engines use the compression of the piston to ignite the fuel-air mixture, without any electrical spark plug. And they can be built to be started using only compressed air. It may take a lot of tedious pumping, but you could prime a compressed air system with a hand or foot pump. Then, once you've got the engine running, you could use it to drive a compressor to charge up the compressed air cylinder for the next time you need to start. All without electricity. Virtually all large scale modern engines are highly dependent upon electronic engine control modules (ECMs) to manage every aspect of their operation. But that's in order to make them as efficient as possible. You can trade away some of that efficiency for a much simpler, all mechanical control system. That's how they all used to be. And there would be enormous motivation for people to return to and advance these sorts of technologies.
Refrigeration also illustrates the case where the current state of the art is only one of many ways to achieve the desired goal, in this case of making things cold. Anyone with a propane fueled refrigerator in their camper knows that you can keep a fridge full of food or drinks cold just fine using a small flame to drive an absorption refrigeration cycle.
A permanent loss of electricity would limit the production of some materials. Aluminum, for example, is refined using an electrolytic process, without which, it is becomes a very precious metal. Fortunately, there is already a significant stock of metallic aluminum in the world that could be recycled almost endlessly. But anything that depends on an electrolytic manufacturing process could no longer be made.
Otherwise, I can think of only a few key technologies that would be impossible to at least approximate in a “Revolution” world: high-speed computing and high-speed, long-distance, and wireless communication. And even some level of both computation and communication can be done mechanically. Mechanical calculators existed for years before modern electronic logic circuits, and I'm sure the world would see new heights of sophisticated mechanical computers being built. It would be a steam-punk enthusiast's dream come true. I can also imagine a telegraph system based on mechanical modulation of something like a metal bar, in order to send messages significant distances at the speed of sound in metal, or around 13,000 miles per hour. Or perhaps we'd just see the return of other pre-electronic communication technologies. Sure, neither of these are as good as what we have now, but they are still a major step above the pre-industrial, agrarian civilization portrayed in the show...
Labels:
Apocalypse,
Communications,
Computing,
Electronics,
J.J. Abrams,
Revolution,
Survival,
Technology,
Television
Saturday, October 2, 2010
Re-Capping A PC Motherboard
Another recent home project, in the category of things that made me unreasonably pleased with myself, was replacing two capacitors that had failed on the motherboard of my Shuttle SN68SG2 PC. I actually first wrote about this computer in the context of the number of restarts required while installing Windows XP. The machine is now 2 years old, and is my primary desktop PC at home. About a week and a half ago, I was working one night when it just clicked off. No warning, no shutdown, just >blink.< This is never a good sign.
After a moment of swearing, I realized that virtually all of the apps I use these days save automatically and so the actual risk of lost data was minimal. I powered back up, and everything worked fine, so I convinced myself that it was just some power glitch on the mains, and nothing to be particuarly worried about.
Two days later, it happened again. And this time I had to admit that it was probably a real problem, and I would have to at least keep an eye out for it. I powered back up, and went back to work... for about an hour. When I powered up following that third failure, I didn't quite get all the way through Windows booting before it dropped dead again. Once the mean time between failures of a PC is less than the boot time for Windows, it is pretty well shot.
Given the nature of the failure, I was almost certain that it must be the power supply. Nothing else, it seemed, was likely to cause such an instantaneous power-off failure like that. So I took the housing apart, measured the power supply, and figured out that there was a replacement available at Fry's. With the new power supply installed it came up, booted to my desktop... and then died. More swearing.
Finally I Googled around and came across this forum posting about my model. Sure enough, upon closer inspection, those same two capacitors in my machine were bulging badly:
When I removed them from the board, one of them also showed signs of electrolyte leakage on the bottom side:
Interestingly, when I measured the capacitance, both the failed caps actually measured *above* spec. The parameter that has gone bad, I suspect, is the equivalent series resistance. These are "ultra-low ESR" caps, meaning, essentially, that they store and release charge very efficiently. Or at least, they used to before their guts started leaking out. I don't have an ESR meter, but that is the usual failure mode. This is an example of the capacitor plague which dates back to the late 90's when some of the Chinese manufacturers got a bit sloppy with their electrolyte formulation. But since the parts only fail after several years of use, there are many millions of them in service.
Getting replacement parts was an interesting challenge. The original caps are 8 mm in diameter and 23mm long, with a capacitance of 1800uF, and a voltage rating of 6.3V. They were also nominally rated at about 0.015 ohms at 100KHz. I could have ordered from Mouser to get some almost exactly the same size and ESR, but it would have taken at least 2 days and cost $38 in shipping, for $2 worth of parts. The closest part I could find over the counter locally was at HSC Electronics Supply in Santa Clara, and they were 1800uF, 0.025 ohms at 100KHz, but rated at 25 volts. This meant they were appreciably larger:
Even the leads on the new caps were larger, 0.2mm wider than the originals, so I had to grind them down with a Dremel tool, and bend them inward to make up for their wider spacing. Once installed, the new caps stood a bit off the board, but it was a situation of "close enough." The off-board mounting proved fortuitous, because their extra height also caused them to interfere with the heat pipe between the processor heat sink and the fan. I ended up bending them over slightly to fit the system back together.
So in the end it was not a particularly clean and elegant fix, but it worked, the parts cost $2, and I was able to get them locally. I put the machine all back together, and it booted right up. And when I came back about 20 minutes later, it was off again. (#$%@!) Then I realized that I'd forgotten to reconnect the power to the fan when I put it all back together, and the machine had shut itself off because it had overheated. I let it cool down, plugged in the fan, and it has now been running for about a week. I'm hopeful that I'll get a couple more years of use out of it before I need to replace it.
After a moment of swearing, I realized that virtually all of the apps I use these days save automatically and so the actual risk of lost data was minimal. I powered back up, and everything worked fine, so I convinced myself that it was just some power glitch on the mains, and nothing to be particuarly worried about.
Two days later, it happened again. And this time I had to admit that it was probably a real problem, and I would have to at least keep an eye out for it. I powered back up, and went back to work... for about an hour. When I powered up following that third failure, I didn't quite get all the way through Windows booting before it dropped dead again. Once the mean time between failures of a PC is less than the boot time for Windows, it is pretty well shot.
Given the nature of the failure, I was almost certain that it must be the power supply. Nothing else, it seemed, was likely to cause such an instantaneous power-off failure like that. So I took the housing apart, measured the power supply, and figured out that there was a replacement available at Fry's. With the new power supply installed it came up, booted to my desktop... and then died. More swearing.
Finally I Googled around and came across this forum posting about my model. Sure enough, upon closer inspection, those same two capacitors in my machine were bulging badly:
When I removed them from the board, one of them also showed signs of electrolyte leakage on the bottom side:
Interestingly, when I measured the capacitance, both the failed caps actually measured *above* spec. The parameter that has gone bad, I suspect, is the equivalent series resistance. These are "ultra-low ESR" caps, meaning, essentially, that they store and release charge very efficiently. Or at least, they used to before their guts started leaking out. I don't have an ESR meter, but that is the usual failure mode. This is an example of the capacitor plague which dates back to the late 90's when some of the Chinese manufacturers got a bit sloppy with their electrolyte formulation. But since the parts only fail after several years of use, there are many millions of them in service.
Getting replacement parts was an interesting challenge. The original caps are 8 mm in diameter and 23mm long, with a capacitance of 1800uF, and a voltage rating of 6.3V. They were also nominally rated at about 0.015 ohms at 100KHz. I could have ordered from Mouser to get some almost exactly the same size and ESR, but it would have taken at least 2 days and cost $38 in shipping, for $2 worth of parts. The closest part I could find over the counter locally was at HSC Electronics Supply in Santa Clara, and they were 1800uF, 0.025 ohms at 100KHz, but rated at 25 volts. This meant they were appreciably larger:
Even the leads on the new caps were larger, 0.2mm wider than the originals, so I had to grind them down with a Dremel tool, and bend them inward to make up for their wider spacing. Once installed, the new caps stood a bit off the board, but it was a situation of "close enough." The off-board mounting proved fortuitous, because their extra height also caused them to interfere with the heat pipe between the processor heat sink and the fan. I ended up bending them over slightly to fit the system back together.
So in the end it was not a particularly clean and elegant fix, but it worked, the parts cost $2, and I was able to get them locally. I put the machine all back together, and it booted right up. And when I came back about 20 minutes later, it was off again. (#$%@!) Then I realized that I'd forgotten to reconnect the power to the fan when I put it all back together, and the machine had shut itself off because it had overheated. I let it cool down, plugged in the fan, and it has now been running for about a week. I'm hopeful that I'll get a couple more years of use out of it before I need to replace it.
Labels:
Capacitor Plague,
Electronics,
PC Repair,
Soldering
Subscribe to:
Posts (Atom)



