GP2Y0A02 sensor for my project

Hi guys, im using the gp2y0a02 sensor for my project. i have try out the codes but the reading show a bit weird.3690891382?profile=original

 

this is the code im using. the serial monitor does show value but not consistent.

Do u think my codes are wrong? I wan to get the reading

 

 

 

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

This reply was deleted.

Activity

Neville Rodrigues liked Neville Rodrigues's profile
Jun 30
Santiago Perez liked Santiago Perez's profile
Jun 21
More…