Nintendo are always in the research and development phase, revealing recently that 3D tech had been working on the GameBoy Advance.
The new 3DS console is the result of years of hard work, trial and error. Most would assume that development had started during the Nintendo DS era, but in a recent roundtable with Nintendo president Satoru Iwata, he and the team when back to the GameBoy days to illustrate 3D development.

The GameBoy Advance SP, the clamshell version of the console, had an attachable screen that worked in a similar way to how the 3DS does now - a special LCD screen, however the visual resolution/output of the GameBoy and screen were so low that it wasn't the right time to take it forward.
To do that you need high resolution and high-precision technology. We didn't have that to a sufficient degree back then, so the stereoscopic effect wasn't very sharp.
It wasn't just portables that benefited from Nintendo's testing - the GameCube, released back in 2001/2002 has 3D capabilities built into its circuitry. It didn't come to light due to the cost for specific 3D-compatible LCD screens.
If you fit it with a certain accessory, it could display 3D images. What a secret! Nintendo GameCube was released in 2001, exactly ten years ago. We’d been thinking about 3D for a long time even back then.
For more details and the full roundtable, be sure to check out the Iwata Asks: Nintendo 3DS.
Would you have bought a 3D adapter to play GameBoy Advance games made for 3D?