Jakub Jon
Jakub Jon

Reputation: 53

executing system command in Matlab without waiting

I am trying to operate three instruments using one Matlab GUI.

While running each instrument independently, works fine. Also first together with second works fine. But while above command runs, second instrument stops sending data while first continues. Each sensor is operated from different function.

Could it be caused due to: "The operation waits for the command to finish execution before returning the exit status of the command to the status variable." (mathworks/system)? In that case why the first instrument is still running?

Upvotes: 2

Views: 3630

Answers (1)

smn
smn

Reputation: 558

You can run an external command in background mode by appending & to the operating system command ! for example:

!notepad.exe test.txt &

will open test.txt in notepad and return control to the command window immmediately.

Run External Commands, Scripts, and Programs

Upvotes: 4

Related Questions