AJ-SRO4M - unable to get distance

Use this section to discuss your embedded Flowcode projects.
Post Reply
pmwalker999
Posts: 2
http://meble-kuchenne.info.pl
Joined: Sun Jan 12, 2025 2:42 pm

AJ-SRO4M - unable to get distance

Post by pmwalker999 »

Hi all,

i am having a lot of trouble with my AJSR04M waterproof distance sensor.
my main issue is that the sensor is always giving me an error message of 9999 on my lcd.
i have used a flow chart form a working model using the exact same sensor and i am stumped.
i need it to get a distance and display it on my 2x16 lcd so i can reverse engineer it and input the distance into another flowcode so it can be used as a variable for an AND gate.

i am using an arduino R3 uno

i would appriciate if anyone could help me as this has been driving me mad for weeks

(P.S i have tried using the HCSR04 sonic sensor and i can make it work, that is why this is so fustrating)

flowcode file is attatched if needed
Attachments
waterproof sensor test.fcfx
flowcode used on arduino
(12 KiB) Downloaded 17 times

medelec35
Matrix Staff
Posts: 1913
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 619 times
Been thanked: 644 times

Re: AJ-SRO4M - unable to get distance

Post by medelec35 »

Hello.
Have you tried a lower prescaler value e.g. 1:1 or 1:8?
Martin

pmwalker999
Posts: 2
Joined: Sun Jan 12, 2025 2:42 pm

Re: AJ-SRO4M - unable to get distance

Post by pmwalker999 »

Hi,
i have tried to change the values with no effect and i am unsure how that would change my result what do the prescaler and post scaler timings affect?

Post Reply