Estimating the distance from a surface is a well-known problem for all kinds of applications involving robots moving in an unknown environment. For flying robots this issue is often coupled with weight constraints, from which the importance of carrying out the estimation of distances with minimalistic equipment. In this study, we present a method to exploit the optic flow divergence cue in order to assess the distance from a surface by means of an Extended Kalman Filter. First, we demonstrated mathematically that the optic flow divergence can be assessed by computing the subtraction between two local optic flow magnitudes. Then, we tested this method on a test bench consisting of two on-the-shelf optic flow sensors performing a back-and-forth oscillatory movement in front of a static or moving panorama. Our findings showed that the optic flow divergence measured as a subtraction of two local optic flow magnitudes was in line with the optic flow divergence computed theoretically under two different lighting conditions. Thus, we were able to use the optic flow divergence measured to assess the distance from the static or moving panorama for low (120lux) and bright (974lux) illuminance respectively. Future work will focus on the implementation of this method on a micro-flier to estimate the distance from a surface, with little mass and computational power.