This page briefly describes the sequence of events that happen when Mac OS X boots. Some details of the boot process from power-on until the kernel is up and running are covered in Booting Mac OS X and XNU: The Kernel. To recapitulate:
Tired of waking up to your clock radio? Well, you can use your Mac as an alarm clock, and have it play an iTunes playlist, so you wake up with the right music every day.