Sun sensor.

so you are already using a photodiode...

I suggest you check your circuits and come back with an update on that once you have worked out what the current issue is.