Even structure/​Mouse Selection
This is my first attempt at a .vi that seems to need an event structure. I am a student in a research lab and my LabView experience is really learn as you go up till now. The program is designed to track a scanner using two linear pots and read in the voltage measurement. I am using an intensity graph to show the values recorded. What I was told to look into doing was replacing the intensity graph with picture functions so that we had more freedom in the movement of the scanner, which so far seems to be true.
Currently I am blocking the analog measurements because we don't have the parts, and modeling the movement with controls. The step I am working on now is to be able to select part of the picture and get the data from it. This can be done by saving part of the picture or reading in the data itself corresponding to that part of the picture or (preferably) both. I don't have any experience thus far with even structures except for playing around with them to try to get this to work. The way I have it set up currently seems to completely bog down the system because with it enabled the other functionality appears lost (or just takes forever).
So basically I'm looking for help to correctly implement what I have attempted here. As usual I would also appreciate general design critiques (gently).
Solved!
Go to Solution.
Attachments:
Scan software.zip 74 KB
ScottC. wrote:
To avoid starting another thread, I am attempting to better explain what I was doing in the above posts. Here is a much simplified trial code that is doing only what I am having problems with. Basically, we will be having data read in and displayed on a picture so that we have more freedom than with the intensity graph. We then want to be able to select part of the picture and zoom in for more detail. I think I did a poor job explaining this before and so didn't get much out of the replies.
The block diagram does this how we want it (or at least close enough that I know I can modify it), with one exception. The picture will never update unless the mouse is clicked to allow the while loop to complete another cycle. If it would update continuously and still allow the same zooming functionality I would be well on my way to getting what I want, but I don't understand enough about triggering the events to know how to go about this.
Ah cardinal sin of new LabVIEW users. I have a post on the forum from my early days where I did the same thing. No need for two event structures in one loop. You can add multiple event cases by right clicking and choosing add event case. Then add your mouse down event to the same event structure as the mouse up event is in already. However, I know why you are doing it. It is so the rest of the code doesn't execute until the mouse up event happens. If you have only one event structure, as soon as you press the mouse down your code will execute, but you won't have the mouse up coordinates. Yes, this will create a problem . However, a better (more complex, but better) way to do this is to dynamically register and unregister mouse events. This is demonstrated in an example that ships with LabVIEW called "dynamically register for events". It is easier to understand than it may seem when first looking at it, but if you need help, continue to post questions.
And to answer the bold part, it sounds like you need parallel threads. Look at producer consumer architecture which will allow the graph to keep updating while the user is clicking around. The forum is littered with posts on this.
Message Edited by for(imstuck) on 06-07-2010 03:26 PM
CLA, LabVIEW Versions 2010-2013
Similar Messages
-
How do I change the settings on my ipod so that it plays continuous music. Right now, it plays the same song over and over, even if I select the shuffle icon. It used to show the continuous play icon, it doesn't anymore.
Right click on a movie(in iTunes), and click "get info" then go to album artwork and add the artwork that you want...
-Messymeese -
Hi When i create the downpayment process in the invoice i get amount as value but my requirement is in percentage even after i select the percentage basis milestone billing please help what can be done
downpayment percentage , so if i want 50 percent of order value to be paid and when i go to faz type the invoice is created for 0 value that 50 percent of the amount is not getting calculated , where as when i enter in order same as 50 percent in amount it gets calculated in invoice, any help ?
-
I CAN SEE ALL SHIP TO LOCATIONS FOR THE CUSTOMER EVEN IF I SELECT ONE BILL
Dear,
I CAN SEE ALL SHIP TO LOCATIONS FOR THE CUSTOMER EVEN IF I SELECT ONE BILL TO
Steps:
Create customer name "customer 1"
Under this customer, I create 2 new address
"Customer A " with tow business purpose
1-bill to –> customer A
2- ship to-> customer A after that I link ship to with bill to customer A , I CHECK THE PRIMARY SITE CHECK BOX
FOR THIS SITE
"Customer B" with tow business purpose
1-bill to –> customer B
2- ship to-> customer B after that I link ship to with bill to customer B
Now when I navigate to (N) Order management ->order organizer ->new order
I select the "customer 1" from customer field name I tab to other field bill to
location it is coming by default as primary site customer "customer A"
I OPEN THE LIST I SEE tow customer A AND B I SELECT 'B' AS bill to
When I tab to the other ship to field in also I can see the tow customer " A" and "B" but in real
setup I link the customer "B" WITH ONE SHIP TO ALSO CUSTOMER"B" WHY I CAN SEE
ALL LOCATION FOR THE CUSTOMER EVEN IF I SELECT THE ONE BILL TO .
WHAT THE BENIFIT FROM LINK CUSTOMER SHIP TO FIELD WITH BILL TO IF I CAN SEE ALL LISTS
FOR CUSTOMER SITE
Expected Behavior:
Once I link the ship to location with bill to location I must see when create sales order only the ship to location
link with the specific bill to already specified
Business impact:
This give the user entry ability to enter wrong data or give him the confusion any site I must enter
thanksThat is expected behavior.
You can see the all addresses of account in the list as long as the purpose condition is satisfied. Linking is only for defaulting and not for controlling. If you do not want to see you can create a different account for the B address.
Thanks
Nagamohan -
My open tabs are not being remembered when I close and re-open Firefox 4 even though I selected this feature in Options. Can anyone tell me why?
App tabs and Tab Groups (Panorama) are stored as part of the session data in the file sessionstore.js in the [http://kb.mozillazine.org/Profile_folder_-_Firefox Firefox Profile Folder]
* http://kb.mozillazine.org/Session_Restore
Make sure that you do not use [[Clear Recent History]] to clear the "Browsing History" if Firefox is closed. -
Query: how to use structure and selection and what's the difference between
Query: how to use structure and selection and what's the difference between these two?
Would be appreciated if some experts here give examples to demenstrate on how to use structure and selection in query and what's the difference between these two?
Thanks in advance!Hi Kevin,
1. Well by default all the KF that you include in your query go into a Key Figure Structure. You can additionally have another structure for defining how your chars are laid out. A common example is a Calmonth structure where you have selections for 12 months, quarers and YTD values. This would be a char structure with different selections (for each month, qtr etc)
2. Yes, a selection with a KF is the same as restricting a KF. You can use am RKF is you have one on the left hand side, or if you need to do this locally in the query, right click the structure and choose New Selection, then proceed to choose your KF and reqd char values.
Hope this helps... -
How to run my vi from a front panel control without using even structure in the vi
Hello, I would like to run my vi from a front pannel control instead of the tool bar RUN botton. I am using LV6.1 without the even structure feature, so I can't do as proposed by a previous posting by setting the vi to run at open in a "do nothing state" then taking the front panel control event and switching the vi into another ("running") state. I wonder is there some other type of solutions to this problem. Your help is greatly appreciated.
BryanHi Dennis, thank you for the reply. I tried with the attached vi. It can only run once (also not in the correct state I want), as the control i placed on the front pannel will stop the VI. I want to have the vi do nothing when it is opened and start counting when the start botton is pressed. Then i want it stop counting when the botton is pressed again...and so on... I must need a different structure to get it work, or did I miss something simple? Thanks again.
Attachments:
StartVI.vi 16 KB -
Even when I select a playlist, I cannot find the burn disc option under the file tab. How do I go about finding it? It has always worked previously, or at least until the latest version of Itunes installed.
Hi Hatethecloud
Have you tried to make a control+clic on the playlist name ?... -
After loading the new OS my songs do not play correctly, is anyone else having this issue? Titles are wrong on songs and it just doesn’t play certain songs in random play or even if you select them individually. What’s up? Kind of frustrating!!!
I had the same issue. In fact I posted it yesterday, but didn't get any replies. I physically synched my phone to PC iTunes. on the PC, under the phone/music tab, I unchecked the synch music box and then the apply button to remove all of the music from my phone. Then once that synch finished, I went back and selected all music, and synch music and apply to put it back on to the phone. So far, I haven't had an issue again, but I also haven't listened very long. Hope this helps!
-
When I print pictures from my IMAC to my Hp C8180 they are grainy, even when I select the Best Quality- Why can't I get good quality printing from Imac ? Use the same printer with a PC and printed the same picture files- they are printed with high quality- Why can't the IMAC do the same?
Does this involve iPhoto for the Mac?
How exactly are you printing these photos?
LN -
It only does this on Reading Rainbow DVDs so far: Using DVD Player, the show goes back to menu after every chapter, even though I selected "Play Entire Episode". It does this whether the laptop is plugged in or is using battery power. How do I get it to play all?? Thanks.
Turns out it was NOT the software or the Mac. I bought a portable DVD player and this problem happens with it, too.
-
How to Return the Index of a Mouse-Selected Array Element in the View Interface of Diadem
Hello,
Does anybody have an idea of how to obtain the index of a mouse-selected array element in the View interface of Diadem??
Thanks!Hi Ovidius,
Keep explaining. The only way I know of to trap a selected cell value in VIEW is to embed into the desired VIEW area a second non-modal SUDialog that has a Table control or an XTable control displaying the values of certain data channels. There are callbacks in both table controls for cell selection, and you can configure the table control to allow only single cell selection if that's what you want. The regular table control will be easier to program, but the XTable control will perform much better for larger channels.
But what happens with that value the user selected? Is it used for a calculation? Is it added to a report? Why would the user select that cell in a table rather than selecting the corresponding feature in a graph with the crosshair cursor?
Brad Turpin
DIAdem Product Support Engineer
National Instruments -
Cannot see the video behind the title even though I select the option to do so, what am I missing?
hauntnh,
I assume you're referring to the fifth video, "Add a title to your video." Did you drag the title to the V2 track, as explained at 2:33 in the video? Also, if your main video in the V1 track is not sitting below your title clip in V2, you won't see the video behind the title because there won't be anything behind your title.
HTH,
Stefan -
"Color Range" isn't even listed under "Select"?
"Color Range" isn't even listed under "Select"? I'm trying to isolate an image onto a white background, and the steps I'm following says
Select duplicated layer and go to Select > Color Range. Select white background with eye dropper and increase fuzziness to maximum amount.
BUT I don't even see that listed!There's a clever trick to simulate it in PSE (credit to Douglas Nelson - third reply at http://www.clearps.com/photoshop-forum/index.php/m/283867/.
Select the color you want to select with eyedropper
Make a new solid color layer filled with the eyedropper color
Set the blending mode of that layer to Difference (everything in your original the color of your eyedropper color will now be black)
Use a Threshold adjustment layer to expand or contract the area to be selected.
Use magic wand (low tolerance, contiguous off) to select black areas
There's your color selection. You can hide or delete the layers created for this procedure as long as you don't deselect, and you'll still have your selection active.
To avoid accidental deselection, save the selection frequently.
Cheers,
Neale
Insanity is hereditary, you get it from your children
If this post or another user's post resolves the original issue, please mark the posts as correct and/or helpful accordingly. This helps other users with similar trouble get answers to their questions quicker. Thanks. -
Even when I select a specific media type (or multiple media types) for ingest, Prelude imports .JPG etc. I want to only import video files within a section of subfolders.
please help
adobe prelude cc2014Prelude will ingest only the files that you have selected (checked the box next to) in the Ingest Dialog. Can you provide more information or screen shots of what you Ingest Dialog looks like BEFORE you ingest and what your Project Panel looks like AFTER you ingest?
Thanks -
Michael
Maybe you are looking for
-
how do I add an ipad to devices in my itunes account which was previously associated with another account?
-
FTP over explicit TLS bug?
I have a FTP server that supports encrypted sessions. When I approach this server from the internal network, encryption works fine. However, when I approach the server from outside only non-encrypted sessions work. With the FileZilla FTP client I get
-
Error while using the variable name "VARIABLE" in variable substitution
Hi Experts, I am using variable substitution to have my output filename set as a payload field value. It is working fine when I am using the variable name as fname, subs etc but channel goes in error when I am using the variable name as "VARIABLE".
-
Problem faced in running the process chain
Hi All, I am having a process chain having few warning.. But I want to schedule that process cahin but I am not able to do so, when I schedule it , it throws a message as "chain changed, schedule in display mode not possible".. So how can I schedul
-
While trying to download and run itunes 10.5, I get an error message that says itunessetup.exe is not a valid win32 application. When I click ok, it stops downloading.