Codesys

Topics about the Software of Revolution Pi
Post Reply
hence.persson
Posts: 4
Joined: 10 Mar 2019, 07:58
Answers: 0

Codesys

Post by hence.persson »

Hello.

I might want to use your product with Codesys but I have some questions.

1. Does the CanOpen GW work with Codesys? (Is it socketcan compatible)

2. Do you have a recommended UPS as I want the Persistent variables to work.

3. I need Modbus RTU, Modbus TCP and CanOpen to work. So I was thinking of the RevPi Connect as this one has a RS485 port. Any other things to consider?
User avatar
dirk
KUNBUS
Posts: 1926
Joined: 15 Dec 2016, 13:19
Answers: 4

Re: Codesys

Post by dirk »

Hi 1) For SocketCAN use the new RevPi Connect with the new RevPi Con CAN. Today we have the RevPiLib as a testing solution without support for you until we have a real product. We currently do not know if this library works out of the box the with this module. 2) no we don't have a preferred solution 3) yes the connect is perfect for RS485. Regarding the GW-Modbus RTU see 1)
hence.persson
Posts: 4
Joined: 10 Mar 2019, 07:58
Answers: 0

Re: Codesys

Post by hence.persson »

So if I understand correctly. The RevPi Con CAN I can use with socketcan? If so I think I wouldn't need your library as Codesys supports SocketCAN.
User avatar
dirk
KUNBUS
Posts: 1926
Joined: 15 Dec 2016, 13:19
Answers: 4

Re: Codesys

Post by dirk »

Yes, it is SocketCAN compatible. See the tutorial here: https://revolution.kunbus.com/tutorials ... ansteuern/
Regarding Codesys is sure another way but we cannot guarantee or give you support for this - at the moment.

Here are the other tutorials about the Con CAN Module
https://revolution.kunbus.com/tutorials ... i-con-can/
https://revolution.kunbus.com/tutorials ... n-connect/
https://revolution.kunbus.com/tutorials ... chliessen/
hence.persson
Posts: 4
Joined: 10 Mar 2019, 07:58
Answers: 0

Re: Codesys

Post by hence.persson »

The RS485 port on the RevPi Connect is that accesible from /dev/ttyUSB0 or is it another device?
User avatar
dirk
KUNBUS
Posts: 1926
Joined: 15 Dec 2016, 13:19
Answers: 4

Re: Codesys

Post by dirk »

No, it is /dev/ttyRS485
hence.persson
Posts: 4
Joined: 10 Mar 2019, 07:58
Answers: 0

Re: Codesys

Post by hence.persson »

For info:

In CodesysControl_User.cfg

I add these lines and then it works. (It doesnt work with /dev/ttyRS485)

[SysCom]
Linux.Devicefile=/dev/ttyUSB


If I do a cat /dev/ttyRS485 and compare with a cat /dev/ttyUSB0 I get the same output.


Now its the next problem that I get a lot of timeouts on my RS485 Modbus RTU network but I guess that is because of poor cabling (no connected ground, small testwires etc.)
Post Reply