![Profile photo of ryan](https://community.controllino.com/wp-content/plugins/buddyboss-platform/bp-core/images/mystery-man.jpg)
ryan
Forum Replies Created
-
I have tested it. I think if i just write two begin with different parity check, they will just crash and no signal is R/W. Is there any way to use the end() function in the struct? I see it but when i tried to use it, it will be a error. I also dont see the detail code for this function.
-
https://www.arduino.cc/reference/en/language/functions/communication/serial/begin/
See the Parameters part. Also, just from my memory and i am not sure about it, the parity config is only valid for hardware serial. If you are using software serial, it won’t work.
-
Hello Lukas,
I did have the sensor connected to the PC through a RS485 To USB. I think it success. At least i got some data that seems valid to me. The problem is that when i tried to connect it to an arduino or Contollino Maxi. It failed. So, it would be great if someone could share some example that successfully connect a sensor to arduino or Controllino Maxi.
-
I am not sure whether you only want to use the board, but ,if you are open to use the controllino only, you should use the Modbus RTU example from the controllino page. You should use the modbusRtu.h that is provided by the controllino team(very important: you should see modified by controllino team in the modbusRtu.h ) After that, all you need to do is change the given example according to your need.
-
It is a temperature and humidity sensor that use Modbus RTU with Data+ and data- wire for communication with PLC. FYI, it is called EE071. Here’s the datasheet for it https://downloads.epluse.com/fileadmin/data/product/ee071/datasheet_EE071.pdf
-
Thank for you response. So, I use the example given by you guy. I have changed the
#define SlaveModbusAdd 247
ControllinoModbusMaster.begin( 9600 ); // baud-rate at 19200
ModbusQuery[0].u16RegAdd = 0x19; // start address in slave
ModbusQuery[0].u16CoilsNo = 2; // number of elements (coils or registers) to read.
These are all the things i have changed. However , the output message doesn’t change at all.
For ModbusRtu.h , I just copy the ModbusRtu.h from the github link you guys said on the website.\
For cabling, I just connect the wire according to the function of them.(VCC to 5V GND to GND A to + B to -)