working red and yellow ball mask. Distance code added but data is not very accurate.