ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

system exec

Hello,

I have a problem with the system exec, in many cases i will not get the output from the command.
I am executing many snmp commands and when i will execute them manually i will see the output but with the system exec the standard output will be empty.
Is there a way to make sure to "pull" out all the exec output?
0 Kudos
Message 1 of 8
(4,438 Views)
Hi Alvarion_...,
how do you call this function? Can you show your code? If it works it should always give you the output.
Mike
0 Kudos
Message 2 of 8
(4,437 Views)
Hello mike,

The problem is that it will show me the output in some cases but there are many others when the output will be empty.
I will attach the vi but you will have to have Alvarion's equipment for the snmp script to work.
Download All
0 Kudos
Message 3 of 8
(4,435 Views)
Hi Alvarion_...,
can you upload your code with some values in it? You don´t need to use local variables in your code, create shift registers.
Mike
Message 4 of 8
(4,431 Views)
Hi,

The only value you should insert is this :
snmpget -v2c -cprivate 10.0.3.218 .1.3.6.1.4.1.12394.1.20.3.51.7.1.2.2
in the script text box.
0 Kudos
Message 5 of 8
(4,419 Views)

You do not need Local Variables to pass data from one part of the code to another.  It is better to use wires and shift registers.

As a matter of fact, since there are no decisions involved in the state machine, it is rather used to force a sequence of actions.  You could even group parts of the code together or have it coded without a state machine at all. (No loop / no case structure).  The code is small enough to support that.  And then wire everything directly. 

The initialization case is not really required either.

R

Message 6 of 8
(4,405 Views)
Hi Alvarion,
here is your vi without local variables. Please fill in some data and save it as default. Can you also upload the missing vi´s?
Mike
0 Kudos
Message 7 of 8
(4,331 Views)
WOW....
I thought you forgot about that....
Thanks but i already found a solution.
0 Kudos
Message 8 of 8
(4,329 Views)