- Fri May 20, 2022 7:49 am
#94571
vinaykumar wrote:hi,
the code is taken for testing from the doc in the below link :
https://wiki.dfrobot.com/A02YYUW%20Wate ... %20SEN0311
I have recently taken a A20yyuw ultrasonic sensor . I have been testing sensor by interfacing with esp8266 on the serial monitor its getting the "ERROR" readings, so i have print the values its getting the same value every time even when i have changed the direction of the sensor its not detecting and values is not varying .i have checked it by giving 5V also. Please help me by giving the suggestions.
thanks in advance
Your link didn't return a valid page from the site. Also your A20yyuw reference didn't bring up any hits on Google, so I can't advice you on that specific sensor. If it acts similar to the HC-SR04 may be your problem.
The HC-SR04 is a 5V sensor and has problems trying to work from the 3.3V logic that an ESP8266 uses.
The HC-SR04P is a 3.3V sensor and works flawlessly with the ESP8266.
I have seen a hack to modify a regular HC-SR04 to work with the 3.3V properly, but you'll need to do a Google search to find it.
Hope this helps.