High voltage applied across mercury vapour accelerated free electrons which collide with mercury atoms, these electrons in the mercury are excited and de-excited, which releases a photon. The tube's coating absorbs the photons and the electrons become excited, and emit visible light photons.