From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Academic Hardware Products (myDAQ, myRIO)

cancel
Showing results for 
Search instead for 
Did you mean: 

myRIO-stopping the system safely

 

Hello,

 

I'm new here and I have in my possession a myRIO.

I'm looking for a way to safely stop the myRIO from running the program that has been downloaded to the device.

I know there is a STOP function but does this do the trick and is there a START function that can be used to start the program again?

 

Thanks

 

Lars

0 Kudos
Message 1 of 4
(6,709 Views)

Hey Lars,

 

Are you asking about how to stop a an RT startup application that has been deployed to the myRIO, or a VI that is running on the myRIO in interactive mode (click the run button in LabVIEW)?

 

If you are using interactive mode you could hit the abort button to stop the executing VI.  Keep in mind this will not stop the FPGA and any configured outputs will continue to run (for example if you were generating a PWM signal the signal would continue even after you click abort).  Ideally you should never have to use the abort button and should instead architect your program to terminate safely and reset all outputs to safe states.

 

If you've deployed an RT EXE to the myRIO and are running your application headlessly you'll need to build a shutdown routine into your code.  For example you could monitor the myRIO user button and when the button is pressed stop your main loop, or some other 'safe state'.  You could also use shared variables, to transfer a stop trigger to your application running on the myRIO target.

 

Let us know if that makes sense or if you have any more questions.  If you provide some more details on your setup and application we can give more specific suggestions.

 

Thanks!

 

-Sam K

LabVIEW Hacker

Join / Follow the LabVIEW Hacker Group on google+

Message 2 of 4
(6,702 Views)

I will be using the myRIO on a robotic project so the abort button in Labview is not an option.

Creating a safe-state or good stop function is my best option than.

 

thanks for the reply

Lars

0 Kudos
Message 3 of 4
(6,693 Views)

No problem.  Let us know if you have more questions about this as you develop your application.

 

Thanks!

 

-Sam K

LabVIEW Hacker

Join / Follow the LabVIEW Hacker Group on google+

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