A CMOS image sensor with pixel level analog to digital conversion is presented. Each 16µm x 16µm pixel area contains a photodiode, with a fill factor of 22%, a comparator and an 8-bit DRAM, resulting in a total of 44 transistors per pixel. A digital to analog converter is used to deliver a voltage reference to compare with the pixel voltage for the analog to digital conversion. This sensor is required by a visual cortical stimulator, primarily to capture the image which is dedicated to stimulate the visual cortex of a blind patient. An active range finder system will be added to the implant, requiring the difference information between two images, in order to obtain the 3D information useful to the patient. For this purpose, three selectable operation modes are combined in the same pixel circuit. The linear integration, resulting from image capture at multiple exposure times, allows a high intrascene dynamic range. Random accessibility, in space and time, of the array of sensors is possible with the logarithmic mode. And the new differential mode makes the difference between two consecutive images. The circuit of a pixel has been fabricated in CMOS 0.18µm technology and it is under test to validate the full operation of the 3 modes. Also, a matrix of 45 x 90 pixels is currently being implemented for fabrication.