I have a small device based on an Arduino and I want to send some data to a PLC that has no RS232 port but can have an optional IO-Link master card. I looked around but found no info about Arduino and IO-Link, are there any projects using Arduino as a IO-Link slave device?
-
\$\begingroup\$ IO-Link is proprietary, so you won't get any opensource protocol stack. \$\endgroup\$– Marko BuršičCommented Jul 1, 2020 at 11:09
-
\$\begingroup\$ Have a look: forum.arduino.cc/index.php?topic=634903.0 \$\endgroup\$– MikeCommented Jul 9, 2020 at 4:40
-
\$\begingroup\$ @Mike: yes I already saw that forum thread, they only suggest to make an IO-Link slave implementation out of the specs. \$\endgroup\$– Pedro NFCommented Jul 9, 2020 at 16:40
4 Answers
IO-Link is a communication protocol intended for industrial environments. It usually involves voltage levels of 24V. Apart for that, you will have to write your own communication stack on the Arduino (as far as I know there is no open source stack, although the standard is an open standard). This has implications both in HW and in FW.
If you are interested in learning IO-Link for the fun of it, go for it. Otherwise I would advise you to install a different communication module on your PLC, something like RS232 or RS485.
-
\$\begingroup\$ It would be an interesting project, add IO-Link to the Arduino, but no time now... so marking this answer as the good one and probably going to add some RS232 board to the PLC. \$\endgroup\$– Pedro NFCommented Jul 4, 2020 at 17:34
Perhaps this light weight IOLink library can be useful to you
https://github.com/unref-ptr/lwIOLink
Disclaimer: I am the author of the repo.
Edit: I have updated the git link to point to the latest version
To do that the Arduino shall be act as IO-Link device so you have to program it with a stack conformal to the IO-Link specification in order to make some test with a real IO-Link master (there are also low cost master on USB port, you can use a PC and connect a single slave to perform some test). There are many stack available around here but all is for commercial use and have some cost so for a simple exercise may be too expensive. Other that you have to define a device profile (IODD file) that shall be understandable by the master to instruct it about the attached device. Best regards.
You only could send data between an IO-Link device and an IO-Link Master (your PLC). Your Arduino don't have any IO-Link functionality (I guess), so you had to find another solution.
-
1\$\begingroup\$ According to IO-Link standard, data can go both ways between Master and Slave. \$\endgroup\$– Pedro NFCommented Jul 4, 2020 at 17:32
-
\$\begingroup\$ Yes of course. But I thought you would like to send data from Arduino to the PLC \$\endgroup\$– MikeCommented Jul 6, 2020 at 13:07
-
\$\begingroup\$ Humm... exactly... as I said, I want to send data both ways, and according to IO-Link specifications this is the normal behavior, server can send data to slave and slave can send data to server. So I'd be able to send data from PLC to Arduino and also from Arduino to PLC. \$\endgroup\$– Pedro NFCommented Jul 6, 2020 at 15:57