6-in-1 soil sensor

It mentions a baud rate of 4800 but I'm still unable to get a response.

Does the manual say that 4800 is the default baud rate?

Below is a drawing of how I have connected up an UNO to an NPK type sensor in the past:

Your pin numbers will be different (D2 & D3 for sw serial & D6+D7 for RE & DE) but it should give you a starting point.

Normally I would suggest using an RS485-USB dongle and a PC to listen to the data on the RS485 bus as that can help pinpoint the issue, but timescales are against you - Friday being tomorrow!

If you run my test program from post #7, then when the sensor responds, you should see 7 numbers after RX: starting 01 03 (assuming device address 01). You may also see the number 01 83 after RX. That is the sensor indicating it doesn't support the specific register we are trying to query.

All I can suggest is that you make absolutely sure that all your connections are correct and that all your wires are good (no breaks in them etc).

...and also short.
Not something like this:

This is the manual
Soil TH-NPK & TH-PH-NPK & TH-EC-NPK & TH-EC-PH-NPK manual_V1.0.pdf (656.5 KB)

I also tried using the circuit diagram, but it still has no RX value.

I'm sorry but I don't know what else to suggest.

Have you discussed the issue with your teacher/tutor? Do they have any suggestions?

Did you verify your wiring follows post #23 (with correct pins)?

Hi @iconicmeso ,

Welcome to the forum..

Can we please get a revised hookup drawing??

Still just getting "no response"??

@markd833 , sorry was recovering from food poisoning.. :frowning:

feeling better now, might be too late though, sorry..

good luck.. ~q

Hello @qubits-us
After fixing up the baud rate, I got this .

Thanks for reaching out., sorry about your stomach. As regards the project, I was given more time when it stopped getting no response and started showing this. Till Monday

You're welcome and thanks, it's better.. :slight_smile:

here the latest sketch i have for these..
Uno7n1sensor

the responses you posted in the last pic, looks like junk..

the baud has to be right..
the Id has to be right..
now, i've seen some sensors that come out of the box and not be id 1..
the sketch i've linked too is set to use a broadcast address, so any sensor should respond..
if the baud or id is wrong, the sensor shall not respond..

you may have to adjust my sketch to use the same pins as you are..

~q

These are the responses that I am getting
20:01:18.644 -> -----

20:01:19.613 -> EC:

20:01:19.696 -> Response in HEX: FF:0:0:FF:0:FF:0:0:FF:0:0:FF:0:FF:0:0:FF:0:0:FF:

20:01:19.798 -> 65280 us/cm

20:02:43.147 -> -----

20:02:44.126 -> EC:

20:02:44.198 -> Response in HEX: 0:0:0:FF:0:0:0:0:0:0:FF:

20:02:44.279 -> 65280 us/cm

20:02:44.279 -> -----

20:02:45.276 -> Ph:

20:02:45.360 -> Response in HEX: 0:0:0:0:0:0:0:0:FF:

20:02:45.441 -> 0.00 ph

20:02:45.441 -> -----

20:02:46.457 -> Nitrogen (N):

20:02:46.457 -> Response in HEX: 0:0:0:0:0:0:0:0:FF:

20:02:46.575 -> 0 mg/kg

20:02:46.575 ->

20:02:46.575 -> -----

20:02:47.607 -> Phosphorous (P):

20:02:47.607 -> Response in HEX: 0:0:0:0:0:0:0:0:FF:

20:02:47.709 -> 0 mg/kg

again, looks like a garbage response..

could be in the hook up..
can you provide a revised drawing please??

~q

I need to leave a college building; please I'll get back to you in about 30 minutes

no worries, i'll be here..
take your time..
~q

It's missing GND connection from arduino?

which nano??
but as @kmin mentions you need a ground from the nano to the max..
i would remove the current connection, use the external supply just for the sensor..

i ask which nano because they are not all 5v, some are 3.3v..

~q

Also, what kind of power supply you use for the sensor?
5-7V... Battery?

I've fixed the Arduino nano ground that was missing. Also, I'm using the +5v from the arduino nano.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.