05-29-2024 03:29 AM
Hello everyone,
I would like to control a stepper motor with a LabVIEW program by RS485 via Modbus RTU.
There is little documentation on the internet, but the manual is quite good.
I have connected the driver with an internet cable, and it is connected to my PC via a USB to RS485 dongle.
To control the motor, we can use the app MEXE02 and modify the motor data.
Using the LabVIEW program, I would like to execute the Operation Data n° 27 to 36 – as shown in the screenshot below.
I think I can use the manual part 7 – 10 Operation data R/W command (p385).
If I understand correctly, I set:
I created the LabVIEW program just below:
But the motor didn’t react, and I can’t understand my mistake, everything seems to be fine. Maybe it’s more about the structure of the ModBus communication.
I'd be very pleased if you could help me and explain my mistakes.
Thank you in advance.
05-31-2024 01:45 AM - edited 05-31-2024 01:47 AM
Hi,
First of all post the VI, not a screenshot.
First question why the multiply by 64 ?
Show how you connected the RS-485 interface.
Kees
07-04-2024 09:10 PM
Hi juliombg,
I don't think the RTU-Modbus CRC calculation in oriental motor matches the RTU-Modbus CRC calculation provided by the LabVIEW Toolkit.
To ensure correctness, I've implemented the CRC calculation according to the user manual.
11-27-2024 02:02 AM
Hi, you already solve it? I have the solution. But seem like this one is old post so I do not know you still need help for this or not
01-28-2025 07:20 AM
Hi,
Can you please share the solution that you have?
I am currently looking into a project to control a oriental driver with Labview.
01-28-2025 09:01 AM
So you want to execute operation No.1? That would use address register 6208. And are you using the correct VI for writing? The logo has a set of glasses, which suggest reading.
01-30-2025 06:52 PM
Hi,
Firstly, download modbus library on VI Pakage Manager.
to open the connection, its very simple. Set the baud rate to 115200. make sure use the same ID on the driver and software.
Then use Write Single Holding function .Set the direct data operation operation type. I use absolute positioning. 5B(Hex) is the register address and 1 is the range.
To Read the parameter, use Read Holding Registers. Refer to the manual for the read parameter address. Example below is to read position of the motor.
To move or execute the motor. You need to set the position, speed, and lastly to triggered the motor.
Sorry, I do not have a proper VI for this. Just refer to the manual for the address. Let me know if you not working
01-31-2025 02:53 AM
@zulfarid94 - Thank you very much!!!
03-10-2025 04:58 AM - edited 03-10-2025 04:59 AM
Hello, I'm currently working on a similar project and I implemented your code in LabVIEW but I'm not quite sure on how to connect those parts and the modbus instances. Do you maybe have an overview of your VI? Thanks.