Jump to content

eberaud

Members
  • Posts

    291
  • Joined

  • Last visited

  • Days Won

    10

Everything posted by eberaud

  1. Reviving an old thread! It's 10 years later, and the VI rolfk mentioned looks like it hasn't got any love. Any chance you know of an updated equivalent that would support 32 bit depth?
  2. Thanks for all those answers!
  3. Uhm, If I reall y want/need to understand this I guess I need to dig into type descriptors and so on?
  4. I was shocked to see that LabVIEW manages to execute this code properly. Can anybody explain why it works? Aren't clusters and arrays 2 different things?
  5. I second Ned's comment. Moreover I find that most developers naturally associate "True" to "OK" in their minds. But to be fair, my code is probably a 50/50 mix... The most important is to label the indicator such that it is self-explanatory.
  6. It's an example, but there is a an actual real number I can give you when I'll have taken the time to dig into my Excel sheets... Exactly. I don't use Waveforms. Each sample has 3 columns for the time stamp and then X columns for the X channels. So X+3 columns total.
  7. Yes but I'll need a bit of effort to put together something that can be understood easily, since right now it mostly consists of big Excel sheets with raw data. I'll try to post something soon-ish.
  8. I've spent my fair share of time dealing with the Advanced TDMS API to achieve the same thing: decimating the data to plot them in a graph. My benchmarking showed that there is a sweet spot where performing one Read operation for each sample you want to keep (using the Offset hooovahh was talking about) starts being more efficient than performing a single Read operation returning a giant amount of data and then keeping only 1 every 100 samples for example. So I'd recommend looking into that if you go with a TDMS-based solution. And since we are dealing with files on disk: SSD drive!! Forget about HDD, way too slow, your users will have to wait several seconds each time they need to refresh the graphs. And yes, cut the file size by half by using SGL instead of DBL! This only poses an issue for the timestamp since LabVIEW uses DBL. I worked around this by using 3 SGL columns to represent the timestamp. You're on the right track!
  9. Also is "LabVIEW Feedback for NI" the right forum for this?
  10. If most of what you read in that thread is new to you, start with queues. That's really a must-know in LabVIEW, on which many more sophisticated patterns are based.
  11. Well the string selectors listboxes of instrument tuner.vi (Cello Strings, Guitar Strings, and so on) are not related to the ones inside String Selector.vi at all... You need a way to pass their values to String Selector.vi otherwise String Selector.vi will keep using their default value (index 0).
  12. I found the culprit!! Back in the days a coworker of mine had the noble intention of increasing the performance of our application by adding some code that would assign a HIGH priority to its thread in Windows (you can do it manually through the task manager). It took me a while to figure that out, I’ve been stripping code from our application bit by bit, until that little subvi was the only thing remaining! The online documentation does recommend not to modify the priority and warns that unexpected behaviors might occur. So I’m not sure if NI will try to fix anything. But at least you guys should add this to your troubleshooting database so that next time you hear about this symptom you can tell the developer to check this setting. I’m attaching a project that will reproduce the issue very quickly if you set “HIGH PRIORITY”. It will run smoothly all night long if you set “NORMAL PRIORITY”. Closure feels so good, workarounds suck Stop Timed Structure Hang.zip
  13. Wow that's a big deal. Even though he remains chairman of the board, it's still a huge page that is turned in the NI book!
  14. Thanks smithd! I should have mentioned that I'm just running on regular Windows, no RT anywhere. You will probably reply: then why on earth are you using a timed loop? Well back in the days I naively thought that timed loop would be more deterministic and have higher performance, but later on I read that not only is it not more deterministic when run on Windows, it also has additional overhead and end up using more CPU than a regular while loop. Yet we kept it because we liked the possibility to abort, and the fact that we can use the "Actual Start [ i ]" left data node in order to log the time stamp of the actual iteration in our log file. So it seems that you also found stinky stuff with the timed loop eh... Well I might end up getting rid of it altogether, replace it with a while loop, and handle the timing myself...
  15. Bumping this thread as I really would like to see some comments, even if you can't propose any fix. At least I would like to know that I am not the only one who encountered this hang issue. Please
  16. Since the connector panes of a child and its parent need to be exactly the same, you need a way to make the passing of parameters generic: either the path of an INI file, or a variant (the child method will know how to cast it back to a cluster), or a string (XML or JSON)... Keep in mind that the child object will contain both a set of parent private data and a set of child private data. So put any common parameter in the parent private data, and any child-specific parameter in the child private data.
  17. I am experiencing frequent occurences where the Stop Timed Structure.vi hangs. I found online that issue #42CHH33W used to be a possible cause, but it's supposed to be fixed in LV8.2 and I'm using LV2015! I tried hard to identify a pattern for the hanging, and implemented a system based on semaphore that would guarantee that I only abort the loop if it's sleeping (waiting to start its next iteration). If it's awake, I simply rely on a Boolean to exit the loop. Even now it still hangs sometimes. Getting a little frustrated here Anybody has experienced such scenario before? Do you think I should try the suggested workaround (putting Stop Timed Structure.vi in a another timed loop that is in sync with the timed loop I want to abort)? What does "in Sync" really mean? Thanks
  18. Again, thanks Smithd. I will keep troubleshooting this issue later. For now I have another issue which is even worse: the "Stop Timed Structure.vi" itself hangs quite frequently and I can't figure out why. This is getting quite frustrating and I'm on the edge of giving up... Anybody knows what could be causing it? I 100% guarantee that the timed loop itself is running when the call to the "Stop Timed Structure.vi" occurs. The name is correct, and most of the time it works fine, but after a few dozens of cycles (a cycle being start timed loop and abort timed loop 1s later), the "Stop Timed Structure.vi" hangs, with no possibility to recover. So this is worse than any error message EDIT: I started a new thread for this purpose, please reply there instead of here.
  19. Our software now periodically run into critical errors where some resources (most likely DVR) are not released, and many components simply hang. I am highly suspicious that it comes from the Abort Timed Loop function. There are many operations inside the loop that function as pairs (open/release DVR in an IPE, dequeue/enqueue elements,...) and I want to be sure that one operation won't be performed without its counterpart also being performed. If we're unlucky and the abort occurs just after opening a DVR and just before releasing it, is it possible that the DVR dies? The reason for the abort is not too shorten the duration of an iteration, which is always pretty short, but rather to force the loop to stop if it's just sleeping and waiting until it's time to perform its next iteration. At this point the only acceptable solution I see would be to use a semaphore: the loop would acquire it when it starts a new iteration and release it when the iteration is done (before going back to sleep). The code sending the abort would only do so when the semaphore is available. Am I on the right track?
  20. I'm also running Chrome 52.0.2743.116... I'll try clearing the cache. EDIT: It did the trick! Thanks
  21. Really weird, I get signed out each time I hit the Home button. But if I hit one of the sub-item (see example below) then I remained logged in. Everybody else with that issue? The frustration is growing in me Home > LAVA Site Related > Site Feedback & Support
  22. I might be lacking imagination, but I achieved results in my LV code that I feel I could never have done without OOP. I have a plugin architecture where all the plugins share a lot of functionalities, which I have coded inside the parent class. Then a "plugin manager" contains an array of all the plugins, only knowing them as "parent class" and never having to worry about which type of child class they are...
  23. That's a fun demo I wrote for a LabVIEW User Group. FunLVOOP.zip
  24. I see, ok thank you both, that was really helpful!
  25. Oh so it has nothing to do with the DVR node of the IPE? So you're talking about putting an IPE with the simple In Place In/Out node?
×
×
  • Create New...

Important Information

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