Screaming Circuits: Engineer stories

Reminders and Stress

Yesterday, I wrote about how much faster we can get things done in the prototype world than we could back when many of us were starting our careers. I mentioned that the decrease in time from weeks to days needed to re-spin a board and get a new prototype run completed is a double edged sword, but I kind of only mentioned the benefits - time savings, cost savings, quicker time to revenue generation. I didn't mention the down-side.

I also didn't really elaborate on another benefit - higher quality product. Instead of shipping product with PCBs riddled with mod wire, it's fast and cheap to get new boards and new assembled prototypes built and tested. These additional test cycles allow for much more reliable product. It can even improve the quality of firmware - shorter time to get a working prototype built means more time to write and test software/firmware. It's all good.

So, what is that second sword edge that I refer to?

RCA12ax7_sq_arms_smoke Stress. Yes. Stress. Back in the days before email and electronic projectors and speedy prototypes, we could relax more. A color presentation generally had to be sent out to have color transparencies or 35mm slides made up. If the boss wanted changes, they had to be made a week or so ahead of time. Now, with electronic projectors, changes can (and are too often) made at 2:00am the morning before the big presentation.

Since I can build you a prototype in a day or so, now those marketing geeks can, and do, throw changes in just a few days before release to production. Everything has to get done faster and faster. I want it now! We enable faster turns so the expectations increase and then we enable even faster turns and the expectation increase that much more. It never stops.

Duane Benson
Sorry. Sort of...

Reminders are Good Sometimes

I was just recently reading an article on another website that caused me to reflect a bit on where we've been and how far we've come in this industry. The article covered a design engineer's experience with modding a board back in the 80's and being required to ship the board with the mods instead of getting new ones made properly.

Back in the late 80's and early 90's, I worked for a company that designed and built business-oriented displays. One of the products was particularly troublesome to get going and the first production versions shipped with something like 24 different mods. If the company had re-spun the boards, we would have added at least a month to the schedule and payed somewhere in the range of $20,000 to $40,000 dollars. If I recall correctly, one of the biggest problem areas was the PLL (phase-locked loop). We were over-driving the parts a bit and that made all of the support passives and the layout that much more critical. Not smart, but I guess that came from one of those "cost-benefit" analysis type things.

Contrast that today where you can get a new set of boards from a PCB fab company like in a few days for a few hundred dollars, get the parts from Digi-Key overnight and have us (Screaming Circuits) assemble them in a day or two.

Of course, it's a bit of a double edged sword. Like when faxes and later email came along. Written communications cycles that used to be measured in days became measured in hours and minutes. The expectations changed. Can you imagine writing a letter to a company and waiting a couple of weeks to get a response?!! That's the way it used to be.

In the same vein, us here at Screaming Circuits (and some other people too) have changed the prototype cycle expectations. Can you even imagine finishing your layout and having to wait four to six weeks for assembled boards to come back? Yikes! But that's what it used to be like. We're all making things go faster and faster. It keeps getting faster and it won't slow down. But that's good because time = money so less time building = less money spent and more time selling = more money earned. Right?

Duane Benson
I... Just... Need... More... Coffee... NOW!!!!

mbed Development - USB Programming Forever

I'm still fiddling with my mbed. Although, I haven't put it to real use yet. I've got some ideas, but I just don't have the time these days. One of the nice things about its programming system is that if I do have to step away for a while, it's easy enough that I don't have to go through any kind of learning curve again. The plug and go USB programming and online IDE is that easy.

Contrast that to one of my little PIC based boards. I recently wanted to do something with one that I hadn't used for a while. I dug it up and pulled out my programmer. I somehow ended up with two different versions of the programmer software installed on my computer, and I had to try both. My programmer uses the FTDI USB/serial chip, so I had to try and guess which COM port to set my programmer software too.

Six permutations later, I had that figured out. I then loaded up an old known-working hex file and took my best guess at what the fuse settings needed to be and guessed wrong. Tried again and guessed wrong. Tried a dozen different combination and gave up and dug up the PDF of the data sheet. Once I found the setting and translated them to the language used in my programmer's software, I finally figured it out and got it all working.

Granted, if I were using this every day, I wouldn't have forgotten all those silly little details, but think about someone learning for the first time. Or, consider a hardware engineer that rarely uses microcontrollers. Once a year or so, some design does need a controller and some programming. I'm a big fan of PICs, but the programming system for many of them seems pretty archaic compared to a product like the mbed.

Duane Benson
I need gravy for the mashed potatoes in yesterday's post

LED Lighting Assembly

When I first attached a 280 ohm resistor in series with a 5mm red LED, the word on the street was that LEDs were low power, forever-lasting devices that would just about completely replace incandescent bulbs for simple binary indicators. LEDs spent a brief period as the numerical display device of choice too, until supplanted by the LCD. Regardless, the bottom line was that LEDs were really easy to work with. Just put that resistor in series - usually, you didn't even need to do the ohms law calculation - rules of thumb were good enough.

Lots of LEDs

Well, for simple binary indicators, that still holds true, but the big noise in LEDs these days has little to do with binary indicators. It's in illumination, and in illumination, all the rules are different.

800px-2007-07-24_High-power_light_emiting_diodes_(Luxeon,_Lumiled) High-brightness LED illuminations devices are some pretty seriously engineered systems. Most have current regulated power supplies. Portable applications often have buck/boost supplies allowing for constant brightness over the life of the battery. And most have serious thermal design work put into them as well. LED lighting designers not only need to worry about all those power supply issues, but also about heat sinking and exotic design techniques such as metal core PCBs and heavy copper. Though it's just an LED, the layout and assembly issues are far from trivial.

Duane Benson
Wear shades 'cause when you're cool, the sun always shines.
Or maybe someone's just trying to blind you with a bright LED flashlight because your ego got too big.


How do you keep your MOSFETs running cool?

  • Flyback diodes?
  • Managing the PWM frequency?
  • Big heat sinks?
  • Fans?
  • More MOSFETS in parallel?

Duane Benson
Remember, no matter where you go, there you are.

Ye Hardware Engineer on Quest for Firmware

I've been spending some time with the mbed here and I'm convinced that there are a lot of good uses for this little thing. One in particular popped in to my head with a lot of vigor.

Back in December of 2008, I listed ten (Octal) things to do to help get through a lousy economy (read #3). If you're pretty much a pure hardware engineer, now might just be a good time to develop some firmware skills.

In my mind, one of the biggest problems going from hardware to firmware isn't the programming itself. That's not really as tough to pick up as you might think. But it's the environment. The tool chains. The configurations. Make files, environment variables, linked libraries, boot loaders, ICSP, flag bits... There's a load of ancillary junk that gets in the way. Some micros require purchased proprietary compilers. Some use open source. Should you use C or C++ or ASM? Too many choices.

Well, here's something that gets rid of all of that extra junk. Plug in an mbed and in minutes you can be experimenting with C programming on an embedded micro controller. Use the onboard LEDs and sample programs to get instant gratification. Plug in some external LEDs or a sensor of some type (maybe from sparkfun) as you get a little more versed in the language. Save the data to the FLASH and graph it in Excel or something.

My personal feeling is that a hardware engineer is much more employable these days with the ability to write firmware. I haven't found a better way to get started then with an mbed. You can worry about all of the other details later, but use this little guy to teach yourself to code.

Duane Benson
It's been a soft day's night, and I've been coding like a frog

My mbed Is Up

I wrote about the new mbed development board a while back and mine just arrived over the holiday weekend. I have to say, true to it's promise, It was the easiest piece of development hardware that I've ever brought up:

  1. Take it out of the shipping box
  2. Plug in the USB cable to the board and my computer
  3. Wait a minute for it to be recognized and open up like a USB thumb drive
  4. Double click on the web shortcut in the drive
  5. Register
  6. Click the Compiler link
  7. Pull up a code sample and modify it a bit (I didn't need to modify it, but I did anyway)
  8. Click the compile button
  9. Save it to the mbed as though it were a USB thumb drive
  10. Press the reset button on the mbed board

That's ten steps, but it's only ten steps. There was nothing else to do. Nothing. The longest step was number seven which took me about two minutes. I programmed a "Knight Rider" sweeper with the four on-board LEDs. I made one of those for my Jack-o-lantern back at Halloween, so it was the first test program that popped into my head.

I built the Jack-o-lantern sweeper with eight LEDs and an 8 bit PIC16F819. The PIC I used came in an 18 pin thru-hole DIP package, costing $3.22 at Digi-Key, and I hand soldered it all on an old perf board. It runs at 20MHz, has 16 GPIO, 3.5K program code space, 256 bytes of FLASH and 256 bytes of RAM.

Mbed pinout The 32 bit NXP LPC1764 runs at 100MHz in a 100 pin LQFP and costs $8.70 in quantity of one at Digi-Key. (The dev board, of course, costs more then that) It has 512K of program FLASH and 64K of RAM. The dev board can have up to 25 GPIO (the chip can have up to 70 GPIO with your hardware) along with the standard assortment of peripherals that can be configured, including six hardware PWM channels. The mbed dev board is like a breakout board configured as a 40 pin 0.1" DIP so it will be easy to prototype with.

The processor, being a fine-pitch package really isn't hand-solderable like the PIC except for by the most adventurous of folks, but that's where Screaming Circuits comes in. Why wait for your custom hardware before starting on the software. Get one of these mbed dev boards to work on your software while the EE folks are designing the custom hardware. Then, when they're done, we'll assemble up the prototypes and you can integrate it all together. Take some time out of your development schedule that way.

I've wanted to try out an ARM processor for quite a while, but prior to this, haven't found the right way to do so while keeping within the limits of my time availability and skill set, but this looks like it could very well do the job.

Duane Benson
Robots rule!

Pour Or Not - Just What Is My Opinion?

I posed a question about using copper pours (AKA flood) a not long ago. The premise was a simple microcontroller board with a 20MHz clock and no special requirements.

Cooper pour exampleI had a couple of different comments on the post with some very good insight. Myself, I generally don't use copper pours. My only reason is that I think it usually looks better without. Although, I do like the look of the cross-hatch pour on the Arduino. A well done flood can be pretty cool, but still my inclination is to only use it if it's needed. If it's a shop doing the PCB, the metal will be recovered and recycled, so the conservationist in me is pleased.

If it's a home etched deal, then a pour is probably a better idea because it will reduce the amount of etchant needed. Although you do need to be careful to keep plenty of space between things to prevent solder bridges. Solder bridging isn't such a big deal on a PCB with a good solder mask, but it certainly is on a board with no mask or thin mask.

If there is a good reason, I will. Like a high-current motor driver - I use the pour to keep the current capacity up and the kelvons mellow. Heat sinking is a good reason for a pour. Hi speed stuff usually benefits from a flooded plane of some sort too and in four-layer boards, using the inner planes for power and or ground is nice and convenient. But you all know that. I'm just rambling now.

Duane Benson
Does high speed stuff on a flooded plane require a speed boat?
Will too much heat sink it?

To Pour, Or Not To Pour. That Is The Question

Pcb w o pour Pcb w pourI know there are plenty of times when a copper-pour ground or power plane is a good idea, sometimes even a requirement. But, is it always so? Take a simple embedded microcontroller board. It has a 20MHz clock speed. Nothing too dramatic. No big power drains anywhere. Just milliamps going here and there.

Does it still help? What about the "greenness" of it? If more of the copper is etched off, more metal will be recovered from the fab company's chemical vats. Or does the additional etch time and and acid required for clearing the board of copper outweigh the benefits of the additional recovered copper?

Looking at all of the boards we get through our assembly lines here, I can't really tell a general industry preference. It's hard to detect an internal plane visually and surface pours don't seem to be any more popular then the lack of them. So, I don't know what the world says.

Any thoughts on this? Anyone? Anyone?

Duane Benson

A New Place To Find Screaming Circuits PCB Assembly

Screaming Circuits and Sunstone Circuits have partnered for board fab and assembly for many years and now, we've made things easier for our common customers. You can order Screaming Circuits Assembly at Sunstone while your order your board fab.

Just order your boards from Sunstone like you always have, but on the quote page (for PCBexpress or Full Featured PCBs), check the box labeled: "NEW! Quote & Order Assembly" as shown in the screen capture below.

NEW quote

Check the box pointed at by the big red arrow I added in to the screen capture above. Then, you'll get a Assembly options_cbox to pop up with two choices: "Drop Ship Assembly" and "Bundle Assembly". If you select to drop ship with the button "Select Assembly", after your boards are fabbed, they will be sent directly to Screaming Circuits. With this option, you'll have to go ahead and come to our website and place your order separately before the boards get here. We've had that option for quite a while.

If you choose the new option, to bundle, by clicking "Quote Assembly" you will see a quote form and you'll be able to quote and order your assembly rightAssembly quote_c then and there. The order will be placed with us, the boards will be shipped to us and you'll get fully assembled boards from us. You will still have to send us the parts and make sure we have all the files we need though. We'll get your order ready in our system and give you a call to make sure that we have everything that you need.

You can, of course, still order your boards and your assembly separately. That's not a problem at all, but if you are getting your PCBs fabbed by Sunstone Circuits, we hope this added feature will make your job just a little bit easier.