The green laser excites charge carriers in the NV centres, which are then captured by surface states. The scanning tip moves over the surface and measures a potential difference around a NV centre.