There are more opportunities for photographs than photographer time available. Whilst some might say that this is a good thing -- particularly with the glut of unthinking snapshots brought about by ubiquitos digital cameras -- some photographers achieve amazing results with exposures taken while they're not by their camera. And in other instances, the photographer is simply not able to react fast enough to get the desired exposure. The solution to this problem is to get the photograph to take itself!
Most digital cameras include some form of timer functionality, where one or more exposures can be taken at some delay after the shutter release button is presssed. This can be very useful both as an impromptu camera stablising technique for multi-second exposures (it's much easier to concentrate on holding the camera still when you don't have to press the shutter too), as well as a way that the photographer can be included in the photograph. But most of these in-camera features are limited to triggering a set number of seconds after the shutter release is pressed, and usually only take one exposure or in more advanced models a short rapid-fire set of exposures. So various other techniques are required to cover longer periods of time, or react quickly to get the best result.
For multiple exposures over longer periods of time (minutes, hours), the standard device is an intervalometer, which can be programmed to take a specific number of exposures at a specific interval (and optionally to keep the shutter open for a specific amount of time, in "bulb" mode). Some advanced cameras aimed at professional photographers have features like this built in. But most consumer and prosumer cameras do not have these features built in. Most manufacturers of DSLRs also produce an external intervalometer that can be used with (at least) their professional cameras, via the shutter remote release port, but these are often quite expensive.
Enthusiastic photographers without the money for a brand name intervalometers have come up with various "DIY" solutions. For instance the DSLR Bot is an iPhone application (US$5) that allows it to automatically control many Canon and Nikon cameras via an infrared sender connected to the headphone port (the IR sender is available as a prebuilt module, or build your own IR Sender. (Reviews: 1, 2, 3.) Other iPhone based options, include Time Fugit, and a Rube Goldberg device that uses the flash on the iPhone 4 as a trigger for the DSLR shutter. People have also achieved similar results with a calculator.
Even more dedicated photographers have gone much further and customised the softare running on their cameras. CHDK the "Camera Hack Development Kit" (mentioned previously provised custom firmware for a lot of Canon cameras, including both older VxWorks based cameras and many newer DryOS based cameras (DryOS is a Canon-specific operating system). CHDK provides a lot of extra features, including a scripting functionality which can be used to provide an intervalometer. (The Canon Basic scripting functionality was discovered and reverse engineered by hackers, and presented at DefCon 2010 -- video and audio.) It's also possible to use the USB port as a trigger port with CHDK.
Taking over where CHDK leaves off is Magic Lantern which supports Canon DSLRs, including mature support for the Canon EOS 5D Mark II as well as support for the Canon EOS 550D. Installation on the Canon EOS 550D relies on installing a specific Canon EOS 550D firmware version (currently 1.0.9 -- which includes some movie apeture and auto-lighting fixes), and then installing a custom "firmware image" which enables the (developer?) disk boot feature (the Canon 5D Mark II seems to ship with this feature turned on, so avoids this step). After that a specially formatted SD card (MAC setup tool; Windows setup tool) can be used to trigger loading the Magic Lantern software from the SD card. Magic Lantern includes an intervalometer, which can be used in both still and video mode. (Interviews with core developer: 2010 (AAC), 2011. See also T2i (550D) Forum.)
Others have taken CHDK even further, which adds support for stereo and multi-camera synchronisation, and has been used to create a camera that controls its own mount, using a servo controlled mount. Some soldering required.
For photographs that require precise timing, a device that triggers the camera shutter based on an external event is required. Such as very high speed flash photography discussed previously.