LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

missing help information?

I find that some labview objects do not link to any description or help information. For instance, when I drop a control, say the "file path control" from the "string & path" palette onto the front panel of a vi, there is "no description" available in the context help panel, there is no "help" option on the associated drop down menu, and there appears to be no corresponding entry in the labview help documentation when searching for "file path control". This seems to be true for most, but not all of the front panel controls. It is also fairly common to have difficulty finding results on search terms entered into the "search the labview help" dialogue. Very often I find quoted help entries on the labview web site that I can't locate on my machine. For instance, I spent a very long time searching the installed help documentation trying to figure out how to convert between the numeric value returned by a color box constant and the actual color contained within. A quick google search returned a Knowledge Base entry on your website titled "How Does a LabVIEW Color Box Interpret a Numeric Value for Color?" This entry quotes help documentation from a Labview product manual that explains how the color box constant is encoded. I realize that the entry on my machine may not be exactly the same as the entry quoted from your published manual, but darned if I can find anything that gives the slightest hint in my installed help documents. Is there something wrong with my labview installation?

global variables make robots angry


0 Kudos
Message 1 of 5
(2,125 Views)
The help information is missing because you haven't put it in there yet. Smiley Wink Controls don't have that in because you, as the user, place the controls on there, and it's up to you to describe what the control is for.

With respect to your other issue: What quoted entries are you referring to? Can you provide an example?

You can search the NI KB using the search box at the top of the web page. With respect to your color box representation I'm not sure what you were searching for, but I found that information in about 5 seconds by opening the Help file, changing to the "Index" tab, and entering "color". Then I selected the color->picker entry. At the top of the page is the information for the color box:

Color Boxes

A color box displays a color that corresponds to a specified value. For example, you can use color boxes to indicate different conditions, such as out-of-range values. The color value is expressed as a hexadecimal number with the form RRGGBB. The first two digits control the red color value. The second two digits control the green color value. The last two digits control the blue color value.

Set the color of the color box by clicking it with the Operating or Coloring tool to display the color picker.


0 Kudos
Message 2 of 5
(2,117 Views)
Sorry, I wasn't very clear in my first post. When I place a pre-written function on the block diagram, a handy description pops up in the help panel,  a detailed description is available in the labview help documentation and it has a nice help option on its drop down menu that I can click on for info. The controls that I select for the front panel are, of course, pre-written functions as well. That is to say; they were created by someone other than me and they do things in a specific fashion that might not be totally apparent (to a dummy like me). Because the drag and drop interface for building the block diagram is similar to the drag and drop interface for building the front panel, it instinctively feels like there should be some sort of description there of the control functions that come with labview, just like the descriptions of the block diagram functions that come with labview. I think what I was looking for might be the help button that I've managed to find by right clicking on the control object, then selecting properties from the drop down, then looking in the lower right hand corner of the properties section. Funny thing is, I read the path properties entry from the file path control that I dropped on the front panel, and I still can't figure out how the control selects the default search folder if it isn't specified, and I'm still not sure whether I can somehow programmatically set the default folder for all "file path controls" on the front panel at once. I'm still searching for that answer in the installed documentation because I feel like I should avoid posting lots of questions to the forum unless I'm sure that the answer isn't sitting right there in the documentation somewhere, which leads me to the second example, the color box constant conversion thing.
 
I read that same help description that you found which is why I was so confused to find that the number I was looking at was not a hexidecimal and had a different number of bytes than the help file specified. It turns out that if you create a color box constant on the block diagram and pick a color, any color, nothing up my sleeve- then create an indicator to output that color, you'll find that the color is not a hexidecimal alphanumeric with six values and three bytes, it is instead represented by a thirty two bit integer. that's one more byte than in the help description, and the integer didn't seem to have an obivious pattern in it that would give away how to turn a red green blue, three byte number into the 32-bit integer that the color box constant shoots out. So here's the official description from national instruments that tells me what the heck is going on with the color box color to integer conversion:
 
"A color is represented by a 32-bit integer, with the lower three bytes representing the red, green, and blue components of the color. For a range of blue colors, create an array of 32-bit integers where only the values of the low bytes change (the low byte contains the blue component). To create a range of gray colors, you need to create an array of 32-bit integers where the red, green, and blue values of each element are the same."
 
so you see there are four bytes with one byte empty that you have to assemble into an integer. or decode by doing the reverse.
 
and the quoted description is from the LabVIEW Picture Control Toolkit Reference Manual Version 1.0. But of, course, the description of how to convert from an integer into a color and vice versa must be in the regular documentation somewhere, because it's a fairly fundamental thing. So I looked in my installed help documentation again to see if I could construct a search phrase to find it, so I would be a little wiser about how to search for specific info in the help files, but I'm just not able to locate it. And, of course if I create a color box control and go into the properties and find the properties help button for the Framed Color Box Properties Dialog Box it doesn't actually say anything about what happens between you picking a color and it shooting a number over to the block diagram, which makes me think "Ok. there is a description of this pre-made control somewhere else, and I'm just not looking in the right spot to find it, because who would give you a big ol' palette of these pre-made controls to use, and leave you wondering what the heck some of the controls are doing when you use them?"
 
So I was thinking that I'm not looking in the right spot for documentation, or I'm not searching in the best way, or that maybe I'm missing part of the help documentation or something.

global variables make robots angry


0 Kudos
Message 3 of 5
(2,108 Views)
OK. Let's handle this one item at a time:

Controls
The controls that you place on the front panel are not "pre-written functions". They're just, well, controls. There's a difference between the description of the control, which you, as the programmer, have to enter, to explain how to use it for your VI, and its programming information, which you, as the programmer, need as you seem to be describing. For the latter, as you noted, clicking that "Help" button in the Properties for the control is one way to get to it. Having a "Help" menu item on the right-click popup would be beneficial for first-time users. I would suggest submitting it to the Product Suggestion Center.

Color Box
The number that is displayed can be formatted to be seen as decimal, hexadecimal, or binary (or a combination of these). The way you see the number doesn't change its underlying value. The statement in the Help file is not inconsistent or wrong. For instance, here's 3 different format displays for the same number:

With respect to the number of bytes: Since the color constants use the RGB scheme, it's 24 bits. However, since there are no 24-bit integer data types in LabVIEW, you have to store a 24-bit value as a 32-bit integer, hence the extra byte.

With respect to converting between an integer and a color: There is no need to do this, since they're the same thing. A color is an integer, so this conversion is meaningless. The color constant/control is merely a convenient way to pick a color. Ultimately they both generate an integer value. You can, however, extract the individual RGB values, which is sometimes required. For this you can use the Color to RGB and RB to Color VIs/functions (in the Graphics & Sound -> Picture Functions palette).

Missing Documentation/Right Way of Searching
Bottom line: You're not missing documentation. With a language as complex as LabVIEW and with the huge number of functions available it can be sometime overwhelming for the first-time user to actually find what they're looking for. Believe me, I've been there before. Even those who have been programming for years find out new stuff all the time. So in that regards, I would suggest using the Index and Search tabs for the Help file directly. In my experience I've found what I'm looking for 99% of the time using either or both of these. I almost never use the "Contents" tab.
0 Kudos
Message 4 of 5
(2,099 Views)

OK, thanks for relieving my paranoia about missing documentation. We were writing code to randomly generate different colored crosshairs for tracking hundreds of multiple targets in a video, and it was easy once we figured out that colors are internally represented in the labview programming environment as 32 bit integers with the high byte empty instead of the low byte. I didn't even know there was an rgb to color function that we could have used instead of bit manipulation.

As for whether or not "The way you see the number doesn't change its underlying value." ....

"There are 10 kinds of people in the world, those who understand binary, and those who don't." 🙂

 


global variables make robots angry


0 Kudos
Message 5 of 5
(2,090 Views)