A proximity sensor for identifying a proximal object, comprising: a housing; a strip comprising a plurality of light emitters and light detectors, wherein each of said emitters is situated between different detectors, wherein the plurality of light emitters (E, 101 - 110) are mounted in said housing for projecting light (401, 404) out of said housing, and the plurality of light detectors (D, 201 - 211) are mounted in said housing, and are operable when activated to detect amounts of light (402, 403, 405, 406) arriving at the detectors; a plurality of lenses (301 - 304) mounted in said housing, each lens, being positioned in relation to two respective ones of said detectors (D1, D2), such that light entering the lens is maximally detected at a first detector of the two respective ones of said detectors (D1, D2) when the light enters the lens at an acute angle of incidence (θ1), and light entering the lens is maximally detected at a second detector of the two respective ones of said detectors (D1, D2) when the light enters the lens at an obtuse angle of incidence (θ2); and a processor connected to said emitters and to said detectors, operable to synchronously co-activate emitter-detector pairs, wherein the emitters and detectors are arranged such that for each synchronously activated emitter-detector pair (E, D), when an object is located at a target position p(E, D) (910-914, 939-942, 944, 945) corresponding to the pair (E, D), then the light emitted by the emitter is scattered by the object and is maximally detected by the detector, and configured to calculate a partial contour of an object (801, 802) outside said housing that reflects light, projected by the co-activated emitters back towards said lenses, by determining a reflection value R(E, D) for each emitter-detector pair (E, D), based on an amount of reflected light detected by the detector when the pair (E, D) is synchronously co-activated, and associating the reflection value R(E, D) with the target position p(E, D) in a common plane corresponding to the pair (E, D), generating a two-dimensional pixel image of reflection values ( Rp) at pixel positions ( p), corresponding to the derived reflection values ( R(E, D)) and the target positions ( p(E, D)), identifying the two pixel positions p 1 and p 2 (939, 941) that are outermost, relative to the direction of the housing, and for which their reflection values ( R p) are above a designated threshold; further identifying a maximum reflection value ( R_max p*) at a corresponding pixel position p *; and summing the distances from p 1 to p *, and from p 2 to p*. a housing; a strip comprising a plurality of light emitters and light detectors, wherein each of said emitters is situated between different detectors, wherein the plurality of light emitters (E, 101 - 110) are mounted in said housing for projecting light (401, 404) out of said housing, and the plurality of light detectors (D, 201 - 211) are mounted in said housing, and are operable when activated to detect amounts of light (402, 403, 405, 406) arriving at the detectors; a plurality of lenses (301 - 304) mounted in said housing, each lens, being positioned in relation to two respective ones of said detectors (D1, D2), such that light entering the lens is maximally detected at a first detector of the two respective ones of said detectors (D1, D2) when the light enters the lens at an acute angle of incidence (θ1), and light entering the lens is maximally detected at a second detector of the two respective ones of said detectors (D1, D2) when the light enters the lens at an obtuse angle of incidence (θ2); and a processor connected to said emitters and to said detectors, operable to synchronously co-activate emitter-detector pairs, wherein the emitters and detectors are arranged such that for each synchronously activated emitter-detector pair (E, D), when an object is located at a target position p(E, D) (910-914, 939-942, 944, 945) corresponding to the pair (E, D), then the light emitted by the emitter is scattered by the object and is maximally detected by the detector, and configured to calculate a partial contour of an object (801, 802) outside said housing that reflects light, projected by the co-activated emitters back towards said lenses, by determining a reflection value R(E, D) for each emitter-detector pair (E, D), based on an amount of reflected light detected by the detector when the pair (E, D) is synchronously co-activated, and associating the reflection value R(E, D) with the target position p(E, D) in a common plane corresponding to the pair (E, D),