Jump to content

Yair

Members
  • Posts

    2,870
  • Joined

  • Last visited

  • Days Won

    44

Everything posted by Yair

  1. QUOTE (PaulG. @ Apr 22 2008, 07:26 PM) There are wrappers to allow LVOOP to work by-ref. One example ships with LV. Another is Endevo's GOOP which has some OpenG classes. I haven't used any of them (I'm only getting into 8.x now myself) so I can't comment on how they work.
  2. You should note that dynamic dispatch has nothing at all to do with dynamically loaded VIs. It refers to VIs which override the implementation of the parent class. The VIs themselves are loaded with the rest of the class. The answer to your other question is that the class data type acts like a typedef, so you shouldn't have any problem. LVOOP is a big thing. You should really take the time to read the relevant material, because you can't expect to learn it based on what you already know.
  3. You shouldn't confuse the various GOOP frameworks (which work by-ref) with the native LVOOP, as they are very different from each other. In general, most GOOP toolkits work like this: When you call a constructor you get a reference to a new object. The class methods accept this reference and use it to manipulate the data in a shared cluster. The GOOP framework is responsible for making sure that calling methods from two different places in the code does not cause race condition when working with the shared cluster. The actual methods used by the GOOP tools vary (CINs, reentrant LV2 globs, single-element queues, etc.), but the high level concept is the same and so doesn't require understanding how the framework actually works. That said, most free ones have the source code open (e.g. OpenGOOP, dqGOOP, Sciware GOOP). Most of them don't support inheritance and can't force encapsulation. LVOOP is much newer and works completely differently. It's by-value, integrated into the environment, supports inheritance and enforces encapsulation. Understanding when to use it should be important. Cat, which classes you create depends on your system, but it is definitely possible you will only want one class (or no classes at all). A couple of examples of classes which might be relevant in your situation: Maybe the data server can have all kinds of features (e.g. TCP connection, Serial connection, DLL connection, Data from a file etc.) and so you might want to make it into a few classes. Maybe you have different kinds of data and you want to make each kind of data into a class, all of which inherit from a common data class.
  4. QUOTE (Eugen Graf @ Apr 21 2008, 04:13 PM) You use VIs with dynamic dispatch inputs to override the implementations of parent classes. For example, if you have the class "animal" and a child class "dog" and a grandchild class "poodle" and you create a "speak" method for each class, then wiring a poodle object into the DD input will return "woof" and wiring a cat object will return "meow". You should follow the link Chris provided earlier for more details. Also, Tomi's blog had a tutorial about inheritance in LVOOP. QUOTE And the next question is how can I define class members so, if I add new members or remove some members, all member VIs will update the class cluster? Should I define the class cluster as typedef for it? The class data already acts as a private typedef for all member VIs in the class. That's the encapsulation mechanism.
  5. QUOTE (ASTDan @ Apr 21 2008, 02:47 PM) Looks like you can't. If you wire an application reference to the register node, the timeout event is disabled. What you can do instead is dynamically change the timeout value (e.g. using a shift register). When you don't want it to occur, use a value of -1.
  6. Yair

    cluster

    You connected the cluster to the default value input of a primitive which retrieves a waveform attribute. If that's what you wanted to do, then you did it correctly (although you didn't give it a name or use a waveform). If you want to build a waveform or get the data from it, there are other options in the waveform palette. You should really look at those tutorials and at the examples in the example finder (Help>>Find Examples).
  7. You can find some relevant tutorials here.
  8. QUOTE (ASTDan @ Apr 20 2008, 05:45 PM) There's absolutely nothing wrong with that. In fact, the two event structures can even handle the same events without race conditions (although in that case you should be aware of the consequences, especially if you use filter events). You might have been thinking of two event structures in the same loop. The only real thing you should avoid when doing this is wiring the same event registration refnum into two different event structures because that will cause you to lose events. As you can see, Ton used two event registration nodes to avoid this.
  9. Very nice :thumbup: . I didn't realize that this happens for any input->output combo of an inherited class.
  10. QUOTE (Michael_Aivaliotis @ Apr 19 2008, 01:08 AM) Actually, I seem to remember that we wanted to do something like that about a year and half ago with a specific school, but it didn't work out for reasons I don't remember.
  11. I also think this is good. We have a program going on with a local school for both NXT and LabVIEW. If we can get the local NI office to help with cRIOs, I assume we can get even more out of it.
  12. There might be better ways (I'm just getting into LVOOP myself), but can't you do it manually by creating a constructor VI, wiring the parent object into it and then unbundling and bundling to rebuild the data? Or do you want to avoid having to do it manually?
  13. Yair

    cluster

    You can find more relevant tutorials here.
  14. You can read tags from an OPC server either by using Datasocket or by using the DSC VIs. Searching for OPC in the example finder and on NI's site should provide some results. I suppose it's also possible you can bind a control directly to an OPC tag, but I'm not sure about that one. Binding is done by right clicking the control and selecting the relevant option from the data operations or advanced menu, I can't remember which.
  15. QUOTE (ASTDan @ Apr 15 2008, 04:42 PM) You set symbols for the entire project (by right clicking on the project in the project tree, if memory serves) and then you choose one of the symbols to switch all the structures throughout the project. I assume the help for the structure covers this in more detail.
  16. QUOTE (Eugen Graf @ Apr 15 2008, 05:28 PM) This is probably the single biggest issue users have with LVOOP (at least users who are used to GOOP). The document Chris linked to goes into this in some detail, with the bottom line that in the future, by-ref support might be implemented, but I wouldn't hold my breath. If you want by-ref, you can use the options mentioned by the others. QUOTE If not, I don't see any advantages in use LVOOP. That's because you're looking at it from the wrong frame of reference. You're used to GOOP, which works by reference and is very convenient and powerful. LVOOP can probably do that, with the appropriate wrappers, but it was also designed to do other stuff where you don't care about using a single instance of an object in different parts of your code. There are all kinds of examples you can find online to see where LVOOP gives you more power. Searching through this board should provide you with some. The key is in understanding that the use cases for LVOOP are not necessarily the same as the ones for GOOP.
  17. Usually, devices on a network (e.g. an RS 485 network) have an address identifying them. In this case, I assume the address is either a Modbus address or an address for a proprietary protocol. The address itself is defined in the device, but exactly how depends on the device and the protocol. Looking through the documentation should help. In any case, using 01 usually works. :laugh:
  18. QUOTE (rolfk @ Apr 14 2008, 11:03 AM) If memory serves, some of the private properties still appear in the lists when using the INI keys from 7.x.
  19. I haven't really used it much, so I don't remember the details, but this might help. It's probably wrong, but it's how I remember it: Start the IA server software. Create a new file (I don't even remember the extension). Add your device to it. I think this is done through an option in the edit menu. When you select the option, you get a list of supported devices. You then need to select the one matching yours (I think the DL205 should work for you) and then you get the option to configure its exact settings (port, baud rate, protocol settings, etc.). After you do that, you need to save the file and then, if memory serves, you need to connect to it using the tag engine (at least that was in 7.x, it might work differently in 8.x with the variable manager).
  20. Yair

    Big Game Hunting

    I would have to agree with Chris, but Windows Update also uses the "opt out" route, which isn't nice. By the way, I don't know about the Apple updater, but if you uncheck an item in Windows Update, it stops bugging you about it. QUOTE (Tomi Maila @ Apr 12 2008, 10:01 AM) http://www.joelonsoftware.com/items/2007/06/12.html' rel='nofollow' target="_blank">Not just for you.
  21. QUOTE (billyt @ Apr 12 2008, 06:20 AM) They're probably right about that one, if that's their definition of "real", but that's like saying a Rolls Royce isn't a real car because you can't do "real" driving in it. That said, QUOTE Has anyone generated a generic Layer 1/2 packet using LabVIEW exclusively such that specific values for the Ethernet MAC header and IP header, etc can be all dynamically set or written a LV wrapper around say Winpcap functions? I haven't looked into http://forums.ni.com/ni/board/message?board.id=170&thread.id=175885&view=by_date_ascending&page=1' target="_blank">this, but it might help.
  22. Thanks, since I was recently asked to look into image processing, so that source might be helpful as well. Crystal ball prediction - crelf will post soon suggesting that I read a certain book about image processing.
  23. QUOTE (Götz Becker @ Apr 8 2008, 03:25 PM) This points to the same page. It also links to a (currently not existing) bugfix list.
  24. QUOTE (Yen @ Mar 29 2008, 08:40 PM) OK, to be fair - I just installed a modern version of LabVIEW and when I came back 10 minutes after I started the installation it was complete. That said, that was just pure LabVIEW.
  25. QUOTE (rolfk @ Apr 3 2008, 09:07 AM) Really? How?
×
×
  • Create New...

Important Information

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