Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Timed Loops on cRIO 9012

Hi, 

   I have an old 9012 cRIO which I found in our store. I want to generate a square wave from it, at up to 25000Hz to control a stepper motor.  

 

  So I have a timed loop in the code, with the clock source set to 1MHz.   However I am getting an error -820, saying that it has been initialised with illegal parameters.

 

Is this true?   Am I stuck with a limit of 1lHz?  

 

  Regards,

 

               Ian

 

0 Kudos
Message 1 of 2
(197 Views)

You are using the Scan Mode with the shared variables. 1kHz is the enforced limit on the legacy cRIO controller.

You can use some C Series Module Support for Specialty Digital Functions in Scan Mode to generate PWM.

If you don't have those modules, you have to generate the square wave using FPGA mode. See examples at Help >> Find Examples >> Hardware Input and Output >> compactRIO >> Signal Generation and Processing >> Digital >> Pulse Width Modulation >> PWM Generation

-------------------------------------------------------
Applications Engineer | TME Systems
https://tmesystems.net/
0 Kudos
Message 2 of 2
(169 Views)