Jump to content

jgcode

LabVIEW Tools Network
  • Posts

    2,397
  • Joined

  • Last visited

  • Days Won

    66

Posts posted by jgcode

  1. QUOTE (GraemeJ @ May 26 2008, 09:49 AM)

    Sorry I may have been a bit vague before - LV will perform code for SRTM App Events, but if you need to capture these events for other reasons then you need to use Shortcut Menu Selection (App) not Shortcut Menu Selection (User).

    Now in your code the table is an indicator and it can't access these methods (empty table etc..), it needs to be a control.

    Therefore one solution is to use a control and write to (update) the table using a local variable.

    If you probe the item tags in the new code it will be picking up these events now.

    The only problem I can think of is that the user can enter in values.

    But if you keep your data private in the application and only use the local variable to write to the screen (as opposed to read at any time) this should not be a problem aside from making the table a little ugly if the user types something in.

    You can't disable the table because then you can't access the SRTM.

    One way to handle this is to use a value change event to load the private data back into the table if the user did change it.

    May be overkill in your case?

    I code in LV8.5, I saved this down to LV8.0, if you only have LV7.0, please follow the .PNG.

    post-10325-1211770632.png?width=400

    Download File:post-10325-1211770620.vi

    Code is in LV8.0

  2. QUOTE (Yen @ May 26 2008, 03:40 AM)

    QUOTE (MikaelH @ May 26 2008, 06:22 AM)

    Maybe it's because LabVIEW supports foreground and background colors for colors in development environment, and the Color Boxes gets 2 event one for the foreground and then one for the background color.

    //Mikael

    Thanks guys, a simple edit will make it work.

    Given your two different posts, I am interested to know if it is desired behaviour or a bug!

    post-10325-1211765688.png?width=400

    Download File:post-10325-1211765704.vi

    Code is in LV8.0

  3. QUOTE (tcplomp @ May 25 2008, 01:49 PM)

    I can't open your code, but have you set maybe the 're-initialize all to default on call' in the VI options active?

    Ton

    Thanks for taking a look Ton.

    I have reattached another version in case I made a mistake.

    Code written in 8.5 saved for previous version 8.0.

    When I load the attached in 8.5 then close it, it asks to save changes - so it should be in LV8.0.

    If it doesn't work - may be a property node difference between versions?

    Defineately works in 8.5 if you have it.

    Is the above suggestion found in VI properties?

  4. I had the recently posed the question of accessing the Color Palette: How to do this? using a SRTM and coded a sub-optimum solution (which I was tryign to avoid) by using a popup Dialog VI with Color Box control so the user can access the palette this way (the listbox property nodes code allows me to know which cell was right clicked).

    However, in my simple subVI ColorPalettePopup.vi (which contains the Color Box control) I use an Event: "Color Box": Value Change.

    Every second time the subVI is called it automatically fires the Value Change event without the user initiating it.

    Every other time it functions correctly.

    Am I going crazy? :wacko:

    Am I doing something wrong?

    Does this happen on other people's LV?

    post-10325-1211681781.png?width=400

    post-941-0-01690900-1394602092.png

    Code is in LV8.0

    Cheers

    JG

  5. QUOTE (GraemeJ @ May 24 2008, 09:09 AM)

    Hello jgcode,

    Re: Runtime Shortcut Menu

    Thanks for your advice. I have got it partially running, but am still in trouble.

    For "copy" and "description and tip" each case operates correctly. When either if these is selected in the RTSM,

    a probe on the selector terminal for these cases within the event structure shows the correct Item_tag, and the

    case is then processed. For all other Application Items eg. 'empty table' or 'delete row', the Item_tags do not appear

    in the Event structure.

    I have not been able to figure out how to step through this bit of the code to see what is happening.

    Any further advice would be much appreciated.

    Regards, GraemeJ

    Hi Graeme, no probs.

    Are you handling your custom items with event: Shorcut Menu Selection (User)

    And LabVIEW application shortcuts with event: Shortcut Menu Selection (App)

    ??

    Even if you have a overall custom menu, it can be made up of App and Custom tags so you need to use both events?

    If this does not help please post up your new code.

  6. QUOTE (exoteric @ May 24 2008, 03:16 PM)

    G'day Everyone,

    I figured I'd best put up a post here to introduce myself before I flood you all with questions on other threads. I am an undergraduate mechatronics engineer in Western Australia, and our lab equipment is run pretty much entirely on Labview, mostly for the purposes of remote lab experiments by students. Our resident labview Guru is on study leave this year, so it is a little difficult to ask for help locally. I am attempting to create a new web interface for our biggest, meanest piece of internet-operable equipment, an ABB IRB1400 industrial robot, that does a rather good job of stacking wooden building blocks.

    Nice to meet you all.

    exoteric

    Hi Exoteric, welcome to the forums. I am a WA native too!! Aside from the Guru - do you have a large LV community at Mech Eng UWA? Or are you going solo?

    JG

  7. QUOTE (Gavin Burnell @ May 22 2008, 07:39 PM)

    This sort of data structure is known as a dictionary or associative array or hash array or map in other languages. There's actually quite a few ways of implementing it in LabVIEW. There's a discussion of the efficiency and speed of a number of these in this thread. My personal preference is to use the attributes of a variant to store the data. Essentially, rather than having two arrays, one of data and one string keys, you have a single variant on the shift register and then use the Get/Set/Delete Variant Attributes to manage the stored data - this seems to be one of the most speedy mechanisms up to several 1000 keys.

    Thanks for the link. Variant attributes are one of those things that I know were there but I have never really used. I recoded the FGV subVI and I like the simplicity. I did a quick benchmark (Pentium M 1.6GHz, 1GB RAM) on a simple three element cluster (similar to error cluster) just to see. Compared to the data arrays, it seems no big perfomance hit sub-1000 - but after that then it really start to matter.

    post-10325-1211612782.png?width=400

    Some great reading here and here too.

    Seems the NFGV or using arrays may be old school and the variant attributes are the way to go to manage a DB!

    Thanks Gavin.

    NFGV_LV851.zip

    Code is in LV 8.5

    • Like 1
  8. QUOTE (Aristos Queue @ May 22 2008, 10:50 PM)

    Being able to run on RT systems is not the same as being able to run deterministically inside the real-time loop. I do not know whether any of the toolkits can run deterministically given that there is at least some data locking to prevent concurrent access to referenced objects. But I could easily be wrong. My point is that there's another question that needs to be answered by authors of the GOOP toolkits when we're talking about "working under RT".

    Great point!

    IMHO I would consider a GOOP VI as a Mutex (shared resource) and therefore it would definately be an issue with creating determinstic code (esp wrt a time critical loop!!).

    I guess to understand the inner workings then all the authors of GOOP need to answer that question though... (hint hint :shifty: )

    However to quote The Good Book:

    QUOTE (LabVIEW for Everyone)

    Semaphores having data is the fundamental concept of GOOP

    So at the end of the day if all GOOP uses semaphores (??) then the sempahores themselves are defined as inherently non-deterministic.

    Right now I want to firstly know if GOOP works with LV8.5 RT for its embedded properties.

    Knowing about creating deterministic code would be good also.

  9. QUOTE (Jim Kring @ May 21 2008, 01:55 AM)

    I can't go into how http://jkisoft.com/vipm' rel='nofollow' target="_blank">VIPM works, beyond what's in the documentation. What I can recommend is that, when you feel you are ready for a software activation system, you look for an off-the-shelf solution or keep your system as simple as possible.

    Can Jim or anyone recommend such a system from first hand use?

    Cheers

  10. QUOTE (Gavin Burnell @ May 22 2008, 02:45 AM)

    Its kinda hard to answer the question with limited detail but if you need the dynamically flexibility of an array coupled with the flexibility of handling different datatypes try the Named Funcitonal Global Variable structure.

    Someone showed me this structure once and it is really handy as a tagged dynamic store.

    You assign names to each data element in a store then access them using this name. If a data element exists in a named location it will replace that element, if not it will add it to the array.

    Even if you are only going to use one datatype this can be handy to track elements by name rather than by index. If you do only use one datatype I would place the NFGV in a wrapper VI so I would not have to handle the variant conversions each time.

  11. For your menu questions.

    Yes you need to handle the event.

    Using the Event structure is one way way to handle FP RTSM selections and it is quite easy.

    Add a case called Shortcut Menu Selection (User) or Shortcut Menu Selection (App) for the control and handle the Item-Tag string in a case structure.

    Use (User) for custom items, use (App) for Application items (you cannot edit item name/tag of application items)

    Also I prefer not to execute code in the Event Structure but to queue it out to a consumer loop.

    post-10325-1211334543.png?width=400

  12. Before this thread is highjacked by great sayings.... :)

    Thanks Jim, I thought as much that spilling the beans would be a problem on people discussing such a issue who have implemented it as a custom solution.

    As a young'n I created a psuedo setup whereby I could statically (in code) link a user(s) to the application and I also have a time expiry whereby it blocks out a user. Of course they can wind the OS clock back but I covered that by creating a file (hidden somewhere) on the first time out to know if this occurs. Of course if they did a fresh install with and set the clock back it would work. If they could be bothered I thought good on them.

    At the end of the day it was cheap and nasty. But it worked for what I needed (small volume), I did it ages ago and I still use it now and then.

    Now I am hunting for something a little more professional.

  13. I am trying to find the best method to license custom software written in LV [not a hardware key -dongle - method, just software].

    Following on from this thread, which is a little old, I was wondering if anybody has any new methods they can share (without them feeling like they are giving away their gameplan).

    I was hoping the VIPM team might be able to chip in as they have a nice license setup.

    Is everything done over the web with a authentication license server nowdays for easy management?

    Regards

    JG

  14. QUOTE (orko @ May 20 2008, 04:51 PM)

    SZ Series - Nice! I am running the older S Series, still going strong, but eye off the SZ all the time!

    I rate your workplace if the company PC is VAIOs!

    For me last place was Levono, current work PCs are Dells.

    Even though spec-to-price ratio isn't that great - there is some sexy about the VAIOs and you can't beat those screens.... (mmm VAIOs)

    QUOTE (Jeffrey Habets @ May 20 2008, 05:34 PM)

    I noticed there are some 15,4" notebooks on the market today with resolutions up to 1920x1200.. Does someone have experience with coding on these?

    It seems to me you would need a magnifying glass to distinguish the various functions and VI's on your BD.

    The lead programmer at work has a new Dell with the above specs. When he points stuff out on the BD i can't see it unless I stick my face right up to the screen. He loves it though! I wish he would drop the res when he is showing me stuff. The only thing I have seen its great for is if we have a massive cluster (like the application's status cluster) we pass around. You can see the whole thing easily, you can probe it etc...

    But I don't know if its worth it as it makes my eyes go :wacko:

  15. QUOTE (Michael_Aivaliotis @ May 20 2008, 09:20 AM)

    What model is that?

    Most likely the TZ? - its the smallest at 11.1" - a friend had one, I can't see the damn screen its so small! Would hate to LV on it.

    I love VAIOs, the off putting thing is the price for what you get.

    One problem I had with a VGN-S18GP model was that it could not recognise PCMCIA E series card: 6036E.

    This gave me endless grief over installing drivers.

    Anyone else anyone else had this problem with any VAIOs?

×
×
  • Create New...

Important Information

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