Jump to content

Error Handler question


Sarah83

Recommended Posts

Hi Sarah,

I would say that return value (topmost terminal on the right side) of each call library nodes is the status of the function called by the node. Usually this means, that getting a value other than 0 is an error. It might even be that <0 means error, >0 means warning, 0 means OK - like in LV. But it hasn't to be.

As it seems the status output of your vi is probably what you're looking for. Apply the rule mentioned above to this output.

:( Unfortunately there is just one library call (out off 9) wired to the status. Library call 1 (top most) could finish successful while the other are still running and might produce at a later time still an error.

The code could get quite an improvement!

Also wire an indicator to the return value of each call library node and run your vi on different (valid, invalid) conditions to see what the status do.

I would even recommend to find some documentation of the library called by the nodes, even if the docu and/or examples are for C++ or so. It will give you further informations. Often C examples and implementations are better documented than LV.

The variable names of the library calls give also informations.

Didier

Link to comment
Hi Sarah,

I would say that return value (topmost terminal on the right side) of each call library nodes is the status of the function called by the node. Usually this means, that getting a value other than 0 is an error. It might even be that <0 means error, >0 means warning, 0 means OK - like in LV. But it hasn't to be.

As it seems the status output of your vi is probably what you're looking for. Apply the rule mentioned above to this output.

:( Unfortunately there is just one library call (out off 9) wired to the status. Library call 1 (top most) could finish successful while the other are still running and might produce at a later time still an error.

The code could get quite an improvement!

Also wire an indicator to the return value of each call library node and run your vi on different (valid, invalid) conditions to see what the status do.

I would even recommend to find some documentation of the library called by the nodes, even if the docu and/or examples are for C++ or so. It will give you further informations. Often C examples and implementations are better documented than LV.

The variable names of the library calls give also informations.

Didier

1757[/snapback]

...apart from the "cheep" code sponsored by Apex... yes, the code should get an improvement :yes:

Hmm... it couldn't be that true is 0 and false is 200 :o

I made a view element for every return value. I start the vi and if I enter something else then 0 in the numeric element "card" the created elements give back 200. It seems like 200 is false :wacko:

Link to comment

In order of execution, the "Card" input is fed to the top two VI's which output "Status", "ID" and "Handle". Handle is then used for all remaining calls to retrieve hardware information.

If by error checking you want to know that the hardware is valid and connected, what you would usually do is check for an invalid Handle (Handle = 0?). Without a valid Handle, none of the secondary calls using Handle as an input will execute correctly. A second way would be to determine that one of the output values such as Wrap Around Angle always needs to be zero or non-zero, or some other criteria, then check for that, although checking for it to always be zero (as your post stated) doesn't seem to make intuitive sense (but who knows).

One thing that you can try to do is to induce errors into the system and see what number values they produce in the VI. In other words, try running this VI with probes on the different outputs and without the hardware connected. Does Handle always equal some random number when the hardware is connected? Does it always equals zero when it is disconnected? Does status always equal a fixed number when the hardware is disconnected? By seeing what conditions are present with and without the hardware you might hopefully be able to see what to test for.

Link to comment

This is just another question. :)

I didn't know that Apex made synchro cards. I am pricing them out right now and can't find very many sources. Is there a web page or something you could point me to for Apex?

Thanks!

Hi,

the synchro card we bought includes a free vi.

But in this vi were called nearly only libraries.

I made a screenshot from the diagram.

Now I don't know how to add an error handler out of this. Maybe if the vi works and "wrap around angle" is empty.

1753[/snapback]

Link to comment
This is just another question.  :)

I didn't know that Apex made synchro cards.  I am pricing them out right now and can't find very many sources.  Is there a web page or something you could point me to for Apex?

Thanks!

1854[/snapback]

Hmmm, the programm I have is Apex Signal (windows start panel - start -programms - apex signal :rolleyes: )

The website were you can get the driver for this card is here

Link to comment
Hmmm, the programm I have is Apex Signal (windows start panel - start -programms - apex signal  :rolleyes: )

The website were you can get the driver for this card is here

1864[/snapback]

Oops! I forgot that North Atlantic and Apex Signal are the same company. :) So I already got quotes from these guys.

It's interesting. We work on Navy Ships, and I aften wondered if anyone else used synchro. I guess they must use it on helicopters as well?

Link to comment
Oops!  I forgot that North Atlantic and Apex Signal are the same company.  :)   So I already got quotes from these guys.

It's interesting.  We work on Navy Ships, and I aften wondered if anyone else used synchro.  I guess they must use it on helicopters as well?

1870[/snapback]

Hi John,

:D I wondered myself, too.

Yes, we use the synchro in helicopters for our navigation system (used for the angle in flight).

I see, your company have a office in Hamburg :thumbup:

Link to comment
Hi John,

:D I wondered myself, too.

Yes, we use the synchro in helicopters for our navigation system (used for the angle in flight).

I see, your company have a office in Hamburg  :thumbup:

1871[/snapback]

This is straying a little off topic. :) But yes - our office in Hamburg was formerly C-Plath (I think they still use the name). They make some great commercial equipment for marine navigation. Unfortunately not many of us get to travel out there very often. (or to any of our many other world wide offices)

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.