Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

command stepper motors with crio

Dear Sir/Madam,
I am Khalil Hamza, an engineering student in electronics and communication from Tunisia. I'm in my final year of studies and my graduation project is about to make a 3 axis robot (pick and place robot).
I want to control the stepper motors with a compactrio 9068 without using the Stepper Drive Interface Module NI 9512 because I have already made their driver board.
The purpse of this control is to command the 3 axis of the robot according to a precise position.
 
I am a beginner in LabVIEW programming and it's the first time that I use a compactrio.
Could someone guide me in my project?
 
I look forward to hearing from you soon.
Best regards.
0 Kudos
Message 1 of 6
(5,051 Views)

Hello Khalil, sounds like you are working on a fun project.  From what I understand, you are only using the cRIO 9068 and LabVIEW with your own driver board.  How are you planning on interfacing with the driver board?  If you are not using any NI motion modules, I do not think you will be able to utilize NI SoftMotion to help with your motion.  If you were planning on using analog I/O to control via your driver board, then you will need some AIO modules to do that.

0 Kudos
Message 2 of 6
(5,007 Views)

Hello Kelle,

Thank you for your reply!

 

Yes, that's what I'am thinking. I want to work with AIO modules but I'm confused on how to program them with LabVIEW to control the stepper motors. Like I've said on my first message, I'm a beginner. I've only programmed an Arduino before with LabVIEW.

Is there any exemples to send me? I've searched and I don't find something that can really help me in my project.

 

I look forward to hearing from you soon.
Best regards.
0 Kudos
Message 3 of 6
(4,981 Views)

Khalil, to use the cRIO, you will need at least the LabVIEW Real-Time Module.  If you look in LabVIEW Help>>Find Examples >> Search >> Analog Output - Scan Mode.  That gives you a project that shows you how to do an analog output using scan mode.  Since you have designed your own driver, basically whatever you ouput using the AO module will just have to match what your driver can accept.  Here is a link that I found that walks you through how to set up and run a VI in scan mode:  https://wikihost.nscl.msu.edu/attpc/lib/exe/fetch.php?media=crio_tutorial_-_basics.pdf.  Do you have any output modules available to you currently?

0 Kudos
Message 4 of 6
(4,955 Views)

Hello Kelle,

For rectification, I think that I need digital I/O modules for my driver not the analog ones. In the company where I'm doing my graduation project, they gave me the digital I/O modules NI 9476 and NI 9425.

Have you any idea about how to use digital I/O to control stepper motor?

0 Kudos
Message 5 of 6
(4,928 Views)

Khalil, since you already have a stepper drive board designed, how you control your stepper motors is going to depend on what the intakes of your board are defined as.  Some stepper drives take in 3 wires, a signal wire, a direction wire, and a ground.  You will have to look at your board to determine what it needs as inputs and give the corresponding inputs.  If it has a signal and direction input, then you will do the signal and direction output from your digital out module, and if you have encoder feedback, that will go into your digital input module.

0 Kudos
Message 6 of 6
(4,910 Views)