At the heart of operation of p-n (or p-i-n) junction photodiodes is the absorption of photons leading to generation of electron-hole pairs. If the diode is, e.g., reverse biased, then the motion of these electron-hole pairs due to the electric field constitutes a reverse current in the external circuit. The electric field is essential for the transport of these charged carriers in a specific direction.
A p-n junction can support an electric field only in the depletion layer, so only electron and holes generated in this region or its vicinity can contribute to the current.
However, the depletion layer is also the region which contains mainly fixed charges -- positive ions on the n side and negative ions on the p side.
I am confused because this should then imply that the mobile charged carriers are actually generated from these positive or negative ions, whereas, the-normally-used-statements, such as "an electron in the valence band is excited to the conduction band leaving a hole behind...", seem to apply to the doped atoms.
It is also not easy to imagine the negative/positive ions giving electrons/holes due to the impinging photons.
Can anyone elucidate upon this confusion?
As such, the same question also applies in the case of impact ionization for avalanche diodes, where highly energetic electrons/holes create electron-hole pairs due to collisions, and this process must also take within the depletion layer.