Kinetics and mechanism of the photocycle of photoactive yellow protein