08-05-2020 12:26 PM
I would like to get from a programmed Mdrive23 the inside program from customer; I mean the Mcode.
I've already installed the SEM SPI Inerface and the Lexium MDrive Software Suite, drivers for the communication were installed as well (which were successfully, the port17 was detected). and I don't know what else to do to get the code from this Stepper motor. Could you help me please
When I open the Motion Control Interface appears 2 windows by deafault:
-Program1
-Terminal1:: Group1
when I click for options on terminal1, and select open port, it shows an erro message "acces to the port "Com17" is denied
Please I'am new on motion control, I'll appreciate your comments
Best regards,
Oscar V.
02-23-2022 09:43 AM
Hi everybody,
I know it is an old post, but I did not find, how to start a new discussion.
Additionally, I am working also with a MDrive23, so that it can be good to follow this discussion.
I am doing a programm to control the movements of the motor MDrive23 (from the fa. Schneider Electronics).
I am using the commands "MCode" from the manufacturer "SchneiderElectronic".
Firstly I get communication with the motor using a VISA protocol.
In order to set the Zero-Point and the MicroStepping resolution (a quantity, which define the required steps o have a revolution of the motor) in the motor, I send the corresponding commands "P 0" and "MS 250" to the motor using VISA Write (OK - Set zero point botton).
For this I take into consideration, that the motor expects a new line and a return carriage after the command.
It works properly, but when I want to get from the motor the answer of the commands by means of VISA Read, I dont get the expected answer, such as I get using the IMS software from Schneider Electronics.
MCode has also the posibility to get the information saved in the motor with the Command "PR", so that "PR P" should give the position of the motor with respect to the zero in Microsteps.
Therefore, I have programmed an option too, in order to set the position of the motor in microsteps, ok-Move botton, reading the value wich is introduced in the "set New position" field and using the command MA (Movement Absolute), it is, if I want to move the motor to a position 100000 steps downstream form the zero point (2 revolutions), I should use the command: "MA 100000" considering the new line and carriage return conditions.
And using afterwards the command "PR P" I should get the new position.
Unfortunately I dont get allways the properly value of the positiion.
The string, that I get has another format, or it shows another information, which should be correct, but it is not the information that I am asking to the motor by means of the corresponding command.
Has someone a suggestion to get the expected answer from teh motor?
I am attachging hereby the corresponding VI and the sub VI to open the serialport that I am using
Thanking in advance for your help!
03-01-2022 08:22 AM
Have you tried this?
https://forums.ni.com/t5/Example-Code/M-Drive-Motor-Driver-Example/ta-p/3490713
03-03-2022 02:53 PM
Tx! I did, but id did not solve the issue. regards!