The energy for ionization for hydrogen is 13.6 eV which corresponds to a frequency (using
Let's shine all the frequencies of visible light Fig. "Continuous spectrum of light" on a hydrogen gas.
Only some special frequencies will be absorbed (Fig. "Absorption Spectrum"). If we look at the light after it went through the gas of hydrogen particle we will see this:
These black lines are the lines of absorption. They are also called spectral lines. Spectroscopy is the science of identifying atoms by their spectral lines. These lines are determined by the energy formula, and this formula is different for each atom. For hydrogen it is
If you heat up (with a fire or whatever) our gas of hydrogen, some electrons will move to excited states (n>1). These states are always unstable, and, after a while (usually very short), the electron will tumble back down and, in doing so, the extra energy they had will be emitted as light (see Fig. "Photon Emission").
The electron can go down all the way to the ground state right away, or it can take a leisurely walk passing by every state below emitting a photon for each transition. These steps create special lines of emissions (see Fig. "Emission Spectrum").