10-15-2010 10:00 AM
Sub-Micro Nugget: When using a Listbox as an indicator, set the Value of the Listbox to -1, so there will not be a selected item in the Listbox, which would look distracting.
Micro Nugget: Custom Symbols in a Listbox can greatly enhance the user experience by pictorially describing the items. The symbols you provide take place of one or more of the supplied symbols. Find some supplied symbols you are not using and index those locations, and replace them with your custom symbols (shown in the second For Loop).
In the example below, I have a case statement (in the last For Loop) where I apply the proper logo to each motorcycle type. I'm telling the Listbox to use the "open folder" symbol if the motorcycle is a YZF type, and I've previously replaced the "open folder" symbol with my Y.jpg, which us a Yamaha logo.
10-18-2010 10:32 AM - edited 10-18-2010 10:35 AM
Using a Mouse Over feature is a great way to get attention. Often, the tip-strip is all you need. But it can be too slow, not big enough, etc.
A custom cursor might be just the ticket. An animated cursor could tell a user that they need to buy the feature before the button will work, or that they should not try to type in an indicator, etc. I used this recently to show the user that they can't click on a picture.
The attached example shows how I used a big red “X” as an icon to warn the user that the “X-RAY” feature is not available when the “IR” button is on. This is less confusing to a user faced with a grayed-out button that still gives you the finger even though it is disabled.
Open the VI and look for the path constant. You'll see a note about changing the path to the place where you put the x.cur file.
10-21-2010 07:09 AM
Instead of using
@broken Arrow wrote:
Micro Nugget: Custom Symbols in a Listbox can greatly enhance the user experience by pictorially describing the items. The symbols you provide take place of one or more of the supplied symbols. Find some supplied symbols you are not using and index those locations, and replace them with your custom symbols (shown in the second For Loop).
You can use an unused index (>40 or something) no need to overwrite standard icons.
Ton
10-21-2010 09:45 AM
TCPlomp wrote:You can use an unused index (>40 or something) no need to overwrite standard icons.
You are correct Ton, thanks for the clarification. I guess I've always found it intuitive to index using a symbol constant, so that's why I've always done the replace trick.
Note to others: replacing the existing symbol is only temporary, while you are using the VI where the replacement takes place.
10-21-2010 09:56 AM
The picture shown below represents a hypothetical scenario where we know that the Background and the Potassium data will have fewer counts than the other isotopes. It is important to remember that the order in which you build the array effects the presentation on the graph. I had to wire Potassium and Background first, to make sure I would see them in front of the other data.
While we're at it, check out the General Histogram VI. Note that if you click on the output Histogram Graph and then Create > Indicator, you'll be presented with a graph that does not exist on the Graph palette. You could create one from a XY graph, but why? The General Histogram VI allows for a range input, which is ideal to present spectral data as shown.
The VI is attached. (( yes I misspelled Potassium in the code and FP ))
10-26-2010 09:34 AM - edited 10-26-2010 09:35 AM
One common oversight when indexing an array (top) is wiring all of the index inputs when indexing sequentially. Not necessary!
A less common addition feature oversight (bottom) is forgetting that the ADD function will accept an array and a single scalar. Common when adding offset scaling to data.
10-26-2010 09:57 AM
@broken Arrow wrote:
One common oversight when indexing an array (top) is wiring all of the index inputs when indexing sequentially. Not necessary!
A less common addition feature oversight (bottom) is forgetting that the ADD function will accept an array and a single scalar. Common when adding offset scaling to data.
That last trick will also work on brown clusters.
Ben
10-26-2010 11:15 AM - edited 10-26-2010 11:17 AM
Custom numeric formatting:
To force a numeric to always displaying the sign of the number simply put a "+" in the formatting.
To force a numeric to always displaying the period as the separator put a "%.;" in the formatting (this is very hand if you do work on systems where the regional default is to use a comma ",")
For example: %.;%+.3f will format to three decimal places, use the period as the separator, display the sign
10-26-2010 01:34 PM - edited 10-26-2010 01:40 PM
The previous post reminded me of something I tend to learn, then forget, then re-learn. You can specify the order in which you use the inputs to Format Into String by using the #$ specifier, for example %2$f specifies that the second input should be formatted as a float. Great for repeating things, or when you really want to avoid crossing wires.
Edit: This also reminded me of something else, WTF is it an error if too few format specifiers are given to that function. I posted a lets-say not so popular idea request to change this here. I would like it to just use as many specifiers as I give it, and if some inputs aren't used, so be it.
10-26-2010 03:59 PM
I'm going to talk about DAQmx, specifically M-series cards. They are really crazy devices that offer you a lot of different functionality: analog inputs and outputs, digital inputs and outputs, counters. What I think makes them really cool and superior to other devices is: you can combine the functionality and sync them.
For some days I was working on the task of getting analog readings correlated with a moving stage.
See here how to do.
This allows you to move a stage really fast and get readings at several defined positions to obtain a precise mapping.
Felix