Lorenzo Bérard
Hi there,

I'm trying to communicate between Open-PLC and a motor drive with Modbus TCP.

I don't quite understand which method I should use. I knew how to do it with classic Python code (with the Socket.py library)

But I would like to integrate all that into openPLC.

Here are the telegrams I have to send:
Capture.png

I don't know which address I should use IW%

It also gives me this:
Capture2.png
If someone has a great tutorial to explain me how to do it...
Here is the complete doc of my drive: https://assets.ctfassets.net/oxcgtdo88e20/AQWcl1jIZGhasmYsUkMOW/4da48abc2a6043b56b2eebcbdb64ee65/Operating_Manual_dryve_D1_EN_V3.0.1.pdf

 

Many thanks in advance. I find OPEN-PLC great. But I have some difficulties to understand well the Modbus communications.

A big thank you in advance for your responses.

Lorenzo

Reply 1 0
Lorenzo Bérard
Now... in english :-)
Reply 0 0
Lorenzo Bérard
I'm trying to communicate between Open-PLC and a motor drive with Modbus TCP.

I don't quite understand which method I should use. I knew how to do it with classic Python code (with the Socket.py library)

But I would like to integrate all that into openPLC.

Here are the telegrams I have to send:
Capture.png

I don't know which address I should use IW%

It also gives me this:
Capture2.png
If someone has a great tutorial to explain me how to do it...
Here is the complete doc of my drive: https://assets.ctfassets.net/oxcgtdo88e20/AQWcl1jIZGhasmYsUkMOW/4da48abc2a6043b56b2eebcbdb64ee65/Operating_Manual_dryve_D1_EN_V3.0.1.pdf

 

Many thanks in advance. I find OPEN-PLC great. But I have some difficulties to understand well the Modbus communications.

A big thank you in advance for your responses.

Lorenzo

Reply 0 0
thiagoralves
Short answer: you can't do this. This is not a standard Modbus communication. This device encapulates CAN messages on a special Modbus Function Code 43, which on the Modbus standard should be used to read device identification.
Reply 0 0
Lorenzo Bérard
Tanks Tiago, 

However can I use the the Python Submodule to comuncate with my drive? with python socket fonction?

Regards
Reply 0 0
thiagoralves
Yes, you can. Using PSM you are free to implement anything you can implement using Python. Communication with the PLC program is done through located variables (%QWx, %IWx, etc)
Reply 1 0
Lorenzo Bérard
Where can I find the right manual for PSM? Where can I dowload de libreary ? 
Reply 0 0
thiagoralves
There is nothing to download. To enable PSM simply go to the Hardware tab on the Runtime webserver and select "PSM for Linux" if you are on a Raspberry Pi or any other Linux-based OS, or "PSM for Windows" if you are running your runtime on Windows. Keep in mind that PSM is not available on Arduino and other microcontroller-based boards.
Reply 0 0
William Zhang
Well done!
PSM is a amazing middleware for openplc and 3rd python program.
Reply 0 0
Reply