M5STATION NO RS485 SUPPORT (let alone Modbus RTU) [EDIT: solution w/example inside]
-
Hello,
the main reason i bought the M5STATION was the RS485 support.
I was pretty puzzled when I saw this element not to be included in the examples! - Let alone the modbus RTU implementation.I hope I'm in being mistaken and effectively the support for this port is available because it's the basics for use in industrial environment.
To be fair and concise, at the cost of sounding not so nice :-) : Arduino has a very good Modbus library that any device with aspiration of industrial adoption should support:
https://www.arduino.cc/reference/en/libraries/arduinomodbus/Are there any plans/maybe it's already done to "fix" it to run on M5STATION?
-
I had it working via a roundabout method but the screen has died on mine and so its sat on the desk doing nothing.
-
@ajb2k3 What's the method? I am seriously considering about embedding such devices in an industrial context but I'm having some doubts now.
-
Hello @Caterpillaraoz
your post made me curious and since I have both an M5Station 485 and an M5Unit-ACSSR which has a Modbus mode I've put together an example. You can find it here.
Thanks
Felix -
@felmue said in M5STATION NO RS485 SUPPORT (let alone Modbus RTU):
Hello @Caterpillaraoz
your post made me curious and since I have both an M5Station 485 and an M5Unit-ACSSR which has a Modbus mode I've put together an example. You can find it here.
Thanks
FelixThank you for your time! It's compiling OK, that's a huge step forward for me, I'll take it as a starting point. Tomorrow in the ofice I'll do a live test & update you.
Let's see if I understood correctly... it should be communicating via the RS485 port built in in the station_485, NOT via the ACSSR unit, right?
-
Hello @Caterpillaraoz
yes, my example uses the RS485 port from the M5Station (acting as Modbus client) controlling the ACSSR (as Modbus server).
You will need to modify the example to send out the proper commands to the Modbus device (or devices) you want to control.
Thanks
Felix -
@felmue Seems to be working - at least in producing compliants packets. Thanks again!
-
@felmue Just an udpate: everything is working as intended. Thanks!