Patent attributes
A semiconductor device capable of acquiring high-precision range information in a short time is provided. Alternatively, a semiconductor device capable of acquiring the range information and image information concurrently in a short time is provided. The accuracy of range information is increased by performing infrared light irradiation more than once to acquire a detection signal and making infrared light irradiation periods identical and extremely short. By detecting light reflected from substantially the same points of an object by adjacent photodiodes, the accuracy of range information can be maintained even when the object is a moving object. By overlapping a photodiode absorbing visible light and transmitting infrared light with a photodiode absorbing infrared light, range information and image information can be acquired concurrently.