Jump to content

drjdpowell

Members
  • Posts

    1,964
  • Joined

  • Last visited

  • Days Won

    171

Everything posted by drjdpowell

  1. Look into “local variables” and “Property nodes (Value)”. Both can read or write to both controls and indicators.
  2. LAVA was down for some kind of upgrade around the new year. I suspect the problem is associated with that.
  3. Tried it from a totally different location on a different computer. Same thing, same symptoms. Could someone else have a go at trying to upload something to the CR? You don’t have to actually complete the submission; just try and upload a file.
  4. No. The static VI just calls the dynamic VI, passing in the class instance and so allowing dynamic dispatch. Below is the static VI I use:
  5. I still have the problem, and I can’t even upload images to the CR. Tried both uploaders and multiple browsers.
  6. I am having a problem uploading a new version to the Code Repository, but you can download it from bitbucket. It is extended to work with multi-D (rectangular) arrays.
  7. Now I can upload images to a post, but still not upload a new file to the CR: attachment=7615:ThisUploadFailed.png]
  8. Are they “orthogonal”? Actors encapsulate their internal data, and messages to the actor can be thought of as methods of an object.
  9. Hello, I’ve just found that I can’t upload files to the LAVA CR. I was trying to submit a new JSON LabVIEW version and I kept getting a “This Upload Failed” error message. See below: ... Well, I was about to attach a png image to this post to show the error, but I couldn’t, as I have the same error when attaching files to posts Anyone else have the same problem? — James
  10. Surely your class has some non-private member VIs in it, or it can’t be used by anything else. Presumably this is you loop/process VI? I don’t see anything wrong with it.
  11. Yes, that’s how I (and many or most others) would do. I would have dynamically-launched VIs as “components”, which I think of as “parallel processes” or “actors”. I use LVOOP for the inter-process communication (“messages” and “addresses”), with each parallel process being represented by-reference to its LVOOP address object. The address is effectively by-reference because it wraps some communication reference like a queue, user event, or TCP client. Note that an “actor” is effectively like a by-reference, asynchronously-accessed, active object, which is not the same as standard OOP objects in text languages, which are by-reference, synchronously-accessed, non-active objects. One can create the latter using a DVR in LabVIEW, but whenever I’ve considered using one I’ve always decided that stepping up to an actor is better (one concern, though, would be speed; straight DVR access will be fast compared with a request-reply exchange of messages via queues).
  12. bsvingen, are you using “singleton” in the same meaning as in OOP; something of which there can only very be one instance of? Because I don’t see how that is useful in something like a PID controller, which one might easily want multiple of. Do you perhaps use “singleton” to mean any by-reference thing?
  13. As ShaunR’s SQLite package in 2009 was not satisfactory for you then I assume you need before 2009. In which case, “no”, as I use features of 2009 or more recent. You should be able to back save Shaun’s stuff, though.
  14. Is there a link to the wiki from LAVA? Perhaps there should be a prominent one. I always forget the LabVIEW wiki exists, and had to Google it to find it.
  15. If you can give me a 1d array, and the dimensions to calculate the offsets, it will be easy to recursively convert to nested JSON arrays inside of JSON arrays (and it will work for any number of dimensions). — James BTW> One other issue that occurs to me is “ragged” arrays, arrays of other arrays of varying size. In LabVIEW, I would make a ragged array from an array of clusters containing arrays; in JSON, it would be just an array of arrays of varying length. I would probably try and add support for conversion between these types, too, if we’re going to support multi-D arrays.
  16. It looks like it can be done with a little OpenG gymnastics (though not trivial). But this is making more work for you if you want to avoid an OpenG dependancy. How do you want to proceed with that?
  17. I had not considered multi-dimentional arrays. JSON doesn’t have a multi-dimentional array type, but we could just have arrays of arrays. I will look into supporting it. Thanks.
  18. Can you list some other examples? “Singleton” is the most obvious one, but Singleton is far more “by ref” than it is “object oriented”. Any non-reentrant VI is a singleton.
  19. I’ve used that recently. Though a private global isn’t really “global".
  20. You can use SQLite entirely in memory by using “:memory:” as the filename. Also note that SQLite uses a caching mechanism that makes it effectively in-memory as far as reading goes, as long as the database is smaller than the cache size (2 MB by default).
  21. Property nodes are notoriously slow. There’s an advanced technique called “Defer Panel Updates” that can be used to speed things up.
  22. You could consider a hierarchal structure of nested LVOOP objects similar to the one we used in the JSON package. Another thought would be SQLite, though I have never done a hierarchal structure in it so it might be more complicated. But you would have the advantage of fast lookup on URLs and just about anything else you wanted fast lookup of.
  23. I assume you have no control over the format of the message? Objects are best flattened/unflattened upwards from child to parent, which means the child information should precede parent information in the message. Your messages are the opposite. I suspect you can still parse it without “downcasting”. You’d have to generate a “type” object to call a parse method, but rather than set the private data of the parent type, the parse method would call further parse methods on the remaining bytes to actually return the subclass. So the parse method called on the “type” object would actually return a different object of the final subclass. Does that make sense? It’s a bit like the onion skin of recursion; instead of calling methods one after the other, you call them one inside the other, going all the way down to the final subclass, and then rising back up through the inheritance hierarchy setting the private data of each level. — James
  24. I need to install the latest LabVIEW version to look at your code, but some of what you describe sounds very similar to what I’ve done. My Transports are called “Messengers”, and I have “Actor” objects that contain a Messenger that is the method to send messages to a process running in parallel. But other stuff mystifies me. It sounds like you have message classes as the children of your Process classes; but aren’t messages and processes entirely different things.
×
×
  • Create New...

Important Information

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