My PC is probably a lot like yours. It takes about two and a half minutes to boot, an eternity to most people. Here are ideas for improving boot up delays in your designs.
My PC is probably a lot like yours. It takes about two and a half minutes to boot. That's 150 precious seconds slowly ticking away from the time I switch on the power until the time it's ready to use. And I'm probably a lot like you in wondering, “what in the world is it doing all that time?”
Now, granted, 2.5 minutes out of my life isn't a big deal. That's less time than it takes to nuke a frozen burrito. But I still begrudge my PC its boot-up time, silently but creatively cursing the programmers who developed the BIOS and the operating system. My processor–not the fastest I confess–runs at 1.6GHz and so, by my calculations, should rip through nearly a billion instructions every second. Does it really take 150 billion instructions to boot the machine? How hard can it be?
Okay, I understand the processor will slow down temporarily because of cache misses and external memory references. I know it has to investigate PCI nodes and grope its way through I/O addresses looking for new hardware. Maybe it's spinning in wait-loops while some hardware becomes ready. Maybe it's taking union-mandated breaks; I don't know. All I know is that 150 billion instructions (give or take a few billion) seems like an awful long time to say, “here I am.”
Boot-up delays aren't just limited to computers, either. Plenty of embedded systems have long boot-up times, but we ought to limit those delays as much as we can. Few things are more frustrating than waiting for a device, appliance, machine, or user interface to “warm up” before we can use it. The machine is supposed to serve us, remember, not the other way around. If your device takes a noticeable amount of time to boot, maybe it's time to rethink your bootstrapping procedure.
One thing I like about my old Nintendo 64 game is that it starts immediately. There's virtually no boot-up time. The machine is ready before my finger leaves the power switch. A PlayStation 2, on the other hand, boots like a PC–slowly. That's one of the disadvantages of booting from rotating memory, such as a CD, instead of from ROM.
You can hide a lot of your boot-up time with a user-interface sleight of hand. In other words, distract your user. If you've got a display screen, show something on it immediately, even before you've run your self-tests or diagnostics. Show that the machine is alive, right now. Change the screen frequently to demonstrate progress. If your start-up times are predictable (or at least calculable) show a progress thermometer to indicate of how much time remains. (Don't do this if your estimates are off; bad progress indicators are worse than none.)
Better yet, don't take so long to boot. The homily about first impressions is true of embedded systems, too. Your users will form their first impressions of your device based on their first power-up experience. And they'll relive it every time they have to turn the machine back on, which may be hourly, daily, or yearly. Make it a good impression. Treat the user's time as precious and don't antagonize them before they've even had a chance to use your product. There's a lot you could do with 150 billion instructions.
Jim Turley is the former editor in chief of Embedded Systems Design.