Add sensor by SoftwareSerial



I want to add my sensor to controller board directly by serial.

The sensor is Conductivity K 0.1.

And circuit is EZO™ Conductivity Circuit.

The manufacturer’s code is below.

I modified that code. Modified code is below.

When I compiled and uploaded this code, there was no error. But, all data streamings were stopped in cockpit.
Could anyone help me ?

What is wrong in my code?


I dont know any about arduino programming, but you say that communication is I2C. I dont see I2C in code, only software serial communication to sensor. And you print results in main serial port, maybe crashing ROV default datastream.


I mistake I2C. I modified it.
I don’t know the cause of crashing datastream.


Arduino send to BBB some data, for examle:
And you code, when it called, insert somewhere unexcepted data:
Software on BBB crashes, datastream stopped.


And you use some pins for com, its free?


I use D14, D15, 5V, GND pin


Do you think it is impossible to use directly serial connection with my sensor?


I think its possible, but you need to insert your data in standard OpenROV protocol, and add some code to process it on BBB side.
You dont need to re-initalize main serial port in Slave::Initialize().
Where is main code calls Slave::Update( CCommand& commandIn)?


I also want to add some sensors on the OpenRov 2.8. So I want to know if your problems are solved.