Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by LogMAN

  1. Do you use an USB-Serial converter? They have become less and less reliable the past few years in my experience (might depend on the chip though). Try a PCI card or the on-board port.
  2. Check my last VI above. The terminal is set to 2 => Always include commented out diagrams
  3. No. I just checked with a dummy project. Any code within unreachable cases is ignored. It doesn't matter if it's directly in the main VI, an inline VI, or a normal sub-VI. You can use Booleans, Numerics or whatever you like. Put code in an unreachable case and it is not listed by Get VI Dependencies. Maybe I should file a CAR and see what NI thinks. In my opinion the dependencies should either be listed, or the VI should break.
  4. Okay, finally found a minute to do this. Here is the same VI but this time with a legit invoke node that doesn't require internet magic: I find the execution speed slower by a huge magnitude (minutes vs. seconds). That's obviously because everything is being loaded into memory. It can be made faster by unchecking some of the options though. Anyways, this VI returns even more Orphans than the original one which it really shouldn't (it recognizes VIs in conditional disables which the old one didn't). That was very confusing until I found the reason for it: "Get VI Dependencies" will ignore code that is inside a case structure with a constant wired to it (at least if that's the case in the top-level VI). Don't know if this is intended, but that's how it works.
  5. By the sounds of it your solution is more solid and works with more complex projects, which is very nice. I'll play around with that node for a bit, might prove useful for future cleanups... Actually the "Linker.Read Info From File" reminded me of how the VIPM generates packages. VIPM has the same issues regarding conditional disables, so I think it uses the same mechanism.
  6. Hello everyone, I want to share a VI that I recently created to search for orphan files in a (very! ) messy project. As it turned out it's actually very easy to do that (if you find super-secret stuff on the net): This VI will find files (VIs, Controls, Classes, etc...) in your project folder that are not linked by a given top-level VI. This is done by comparing the call-chain of the top-level VI with the files on disk. It assumes your files are in folders relative to the specified root directory. This also means that files outside the hierarchy will be ignored (vi.lib and such). Be aware of (at least) two things: This VI will return false friends if you happen to have any "Open VI Reference" call with constant VI names or paths connected to it (not a problem if you use static VI references). VIs in diagram disable structures are not listed in the call-chain. So if you use conditional (or regular) disable structures this VI will return false friends. Does anyone know a solution to number 2. actually? Hope this proves useful to you too.
  7. Way better Still you perform many write operations by executing the SQL in a loop without a transaction. The more values you have, the slower your loop becomes. Your current implementation might result in incomplete data in case of SQL errors (you can't undo your actions)! Try to add a transaction around your loop (It's very easy to do, costs nothing and is at least worth a try): Transactions will prevent file-writes for as long as they are not committed (this is why it might save you some more time). By calling the Commit VI at the end, all data will be written in one go. In case of errors you can just reverse everything by doing a rollback (The Commit VI will do a rollback on error automatically).
  8. Use a prepared statement and a transaction. Your current implementation requires writing for each iteration which is slow obviously. Check out the "Insert many rows code template" on the SQLite Library >> Code Templates palette. The prepared statement will allow you to use binding which is very useful as it maintains data types in your application. See following Picture for an example (I can't test it right now, but it should work like that):
  9. LAVA used to float the marked answers on top of everything. It's just that hardly anyone marked a post as answer. Maybe it was not obvious enough how to do it, or the nature of the topic did not allow for a single post to be THE answer.
  10. The VI does exactly what jj321 said it does, access the control of a clone VI. I think the reason why nobody is answering is because there is no question, just someone sharing news with everyone Here is the snippet of the VI: I don't know why anybody would want to access the controls of a clone VI like that since you would normally pass data while calling it. On the other hand if you need access to information from the VI there are other ways like notifier or queues. I have used a similar approach to call LabVIEW applications via ActiveX and sending information between the caller and the executable, but never from within LabVIEW... @jj321 would you care to explain the use-case of your VI?
  11. Now that's a very good point. I didn't notice until now and I like it very much! Because we missed said feature?
  12. Me too, but people don't like when I down-vote them, so I do it ~stealthy~ Damn you logic! You are in my way! You are right of course, I can't argue against that. Now where is my (:brokenheart: Dislike this) button?
  13. Figured. Funny thing is I actually wrote a couple of sentences about that, but deleted them in the end This is what I dislike about the voting system (it's an extreme case, but a case nonetheless): http://meta.stackexchange.com/questions/228358/why-my-questions-on-stackoverflow-are-getting-downvotes-without-explanation The system can only work if used the intended way. By the way, is it possible to disable the "voting-down" button and leave the "voting-up" button active?
  14. Isn't that more or less what our good old (♥ Like this) button is for? It serves its purpose just fine - even though we cannot filter for that right now (*hint*)... In my opinion the best answer is the one that answered the question of the one who asked and not the one everyone else votes as the best answer. There might even be an answer that is very well written, explains an important aspect or is especially funny and ends up as the top answer without even answering the initial question. The possibility to vote someones answer down on the other hand is misunderstood very quickly and will alienate people who fear "bad scores". It also hinders dialog as people just need a single mouse-click in order to judge someones answer. So how about posting the initial question in the General forum and let the voting score decide? Where is the voting system when you need it?
  15. Amen. Thanks Neil I was attempting to write the exact thing right now (though I had trouble finding the right words) One thing I want to mention related to the graphs from above: Maybe there are less topics started overall, however the existing ones are extemly helpful as is and being continued on a regular basis (even ones that are over 10 years old). This forum provides a tremendous amount of knowledge, ideas and funny things which lure me to come back every day (sometimes even on holidays ). Also: Don't trust statistics you didn't forge yourself
  16. I too had some issues a couple of hours ago (see attached picture), but it's better now.
  17. Have you checked your settings here?: https://lavag.org/notifications/options/ email notifications were disabled for me, maybe it's the same for you too.
  18. Not sure if this helps, but hooovahh secretly explained the XNode editor on YouTube (I recommend watching the entire video btw ): It is closely followed by a quick introduction to the Variant Repository https://www.youtube.com/watch?v=R2En7yMANi8&feature=youtu.be&t=34m44s Wow, new Lava embeds videos now
  19. The Articles area looks very broken to me (see attached picture): https://lavag.org/index.html/ Any other page is fine though.
  20. I think you have no choice but to try and re-produce all steps your user has taken to get to that kind of issue (you could connect via remote desktop and let the user show you). With the little information we have there are at least two things I would check: 1) Check if the correct RunTime-Engine has been installed. 2) Check if all necessary files of your application are present. (The dialog clearly states two are missing) There are two types of RunTime-Engines available for LV2012, minimum and standard. Standard is the one your user needs. I'm not sure what happens if you install the minimum one, but it's worth mentioning. If your application consists of separate folders with VIs next to your executable, some of them might be missing. The same goes with external plug-ins and such.
  21. The way your VI is implemented is the correct way to dispose of objects (or any given non-reference type in LabVIEW). The wire has "loose" ends (after the last VI), so that particular copy of the object is removed from memory automatically. Only reference-types must be closed explicitly (like the DVR). So your final VI just has to take care of references within that object to prevent reference leaks.
  22. Okay, this is getting a bit off-topic as the discussion is about a specific problem which is not necessarily sqlite related. So I guess this should be moved to a separate thread. drjdpowell alredy mentioned, that sqlite is not the best solution if your data is not structured. TDMS on the other hand is for use with graph data, but creates index files in the process and stores data in a format readable to other applications (like Excel). That is what slows down your writing/reading speed. As far as I understand you want to store an exact copy of what you have in memory to disk in order to retrieve it at a later time. The most efficient way to do that are binary files. Binary files have no overhead. They don't index your data as TDMS files do, and they don't allow you to filter for specific items like an (sqlite) database. In fact the write/read speed is only limited by your hard drive, a limit that cannot be overcome. It works with any datatype and is similar to a BLOB. The only thing to keep in mind is, that binary files are useless if you don't know the exact datatype (same as BLOBs). But I guess for your project that is not an issue (you can always build a converter program if necessary). So I created a little test VI to show the performance of binary files: This VI creates a file of 400MB on the users desktop. It takes about 2 seconds to write all data to disk and 250ms to read it back into memory. Now if I reduce the file size to 4MB it takes 12ms to write and 2ms to read. Notice that the VI takes more time if the file already exists on disk (as it has to be deleted first). Also notice: I'm working with an SSD, so good old HDDs will obviously take more time.
  23. @drjdpowell: I installed the latest version of your library (1.6.2). There is a new VI called "SQLite Database Path" which is missing the output terminal for "Last INSERT RowID":
  • Create New...

Important Information

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