Jump to content

All Activity

This stream auto-updates

  1. Past hour
  2. In various part of my application I want to allow users to open a setup dialog and when that setup dialog is open they should not be able to shift to another window, so the dialog should be modal... However, I also want the callers to continue to update as the user might then discover something critical in those displays while in the setup and exit the setup. The easy (/correct) solution to this is to have a separate loop in the callers that calls these setup dialogs, because then the setup dialog can be called statically/syncronously and have its window set to modal....I then get both updates in the caller's display and block access to GUI operations in the caller window. Now the downside to that is that you have to have such a dedicated loop and for various reasons some of the updates happen in the same loop here, so instead I thought I could call the dialog dynamically. This invalidates the modal behaviour though as it will not be modal in relation to the caller anymore. Setting the dialog "Always on top" is one option, but then it will stay on top even of file dialogs it calls(!) so unless you turn off the always on top setting every time you call a file dialog you have another problem. Setting the dialog to floating on the other hand does not block access to the caller's window. I can alternatively live with that by adding code to close the dialog if the parent gets closed etc, but a true modal behaviour would remove the need for such additional code and would be preferable. So, the question is, is there a way to call a VI asyncronously, but still force it to behave modal in relation to its caller (or "globally" (for the application))? Or should I just capitulate and make sure these calls happen statically in a loop that can wait?
  3. Today
  4. First search result for "labview loop tunnel mode": Auto-Indexing Tunnels with For Loops and While Loops in LabVIEW In your case:
  5. Yesterday
  6. Last week
  7. Unfortunately, it fails. The original error I posted is from within the MATH.vi so it would make sense that nothing downstream of that would work.
  8. Unfortunately not, as it's description mention it only goes from Volume 1 to 4... Issues included are: Volume 1, Issue 1 (Spring 1993) Volume 1, Issue 2 (Summer 1993) Volume 1, Issue 3 (Fall 1993) Volume 2, Issue 1 (Winter 1994) Volume 2, Issue 2 (Spring 1994) Volume 2, Issue 3 (Summer 1994) Volume 2, Issue 4 (Fall 1994) Volume 3, Issue 1 (Winter 1995) Volume 3, Issue 2 (Spring 1995) Volume 3, Issue 3 (Summer 1995) Volume 3, Issue 4 (Fall 1995) Volume 4, Issue 1 (Winter 1996) Volume 4, Issue 2 (Spring 1996) Volume 4, Issue 3 (Third Quarter 1996) Volume 4, Issue 4 (Fourth Quarter 1996)
  9. I checked that it works for me, in LabVIEW 2021. Does code this simple fail for you:
  10. Sorry for the delay - we had to go out of state for a bit. ShaunR; I connected two ports together using the same USB to RS-232 adapters as used in the Write/Read example I posted above. When I click Set Break, the receiving port connector flashes but the Detect Serial Break Event VI does nothing. I am not sure what a "Break" is in serial communication. I have ARSL End Out and ASRL End In both set to "Last Bit". I tried other combinations as well. The Read vi I made is displaying what I send (I did add decimal and hexadecimal array displays to make sure the ASCII is absolutely correct). The data returned from my Write command exactly returns what the working exe sends and returns. There must be something fundamental I am missing here and for the life of me, I don't know what it is. The radio demands 4800 Baud, No Parity, No Flow Control, 1 start bit, 8 data bits, and 5 bytes - that is it. Is there something that LV appends (or doesn't) which could cause my problem? Thanks, John
  11. You did mentioned the articles are included on this particular CD: https://archive.org/details/labview-technical-resource-library-of-back-issues-windows-macintosh-v1.0
  12. Not sure what that is. Can you please guide me?
  13. Just in case the previous info was a bit vague, this is what I mean: SQLite version 3.50.1 2025-06-06 14:52:32 Enter ".help" for usage hints. Connected to a transient in-memory database. Use ".open FILENAME" to reopen on a persistent database. sqlite> sqlite> .load "C:/Program Files/National Instruments/LabVIEW 2025/vi.lib/drjdpowell/SQLite Library/SQL Connection/extension-functions_64.dll" ...> The DLL seems to work fine and can be loaded into sqlite, but the LabVIEW method seems to have a problem.
  14. Yes, the DLL is there. Furthermore, when calling it directly from sqlite3 it also works.
  15. Does that DLL exist at the stated path?
  16. If the time appears for each channel, then you didn't set the loop tunnel mode to last value.
  17. I tired using Format into string, but then the result text file includes time stamp 4 times for each line of data, instead of doing just once.
  18. Hi @drjdpowell! I ran into an issue using the library on LV2024 Q3 64 bit and LV2025Q1 64 bit (only tested it on these two versions). It appears to have something to do with the "Load Extension" functions. Error 402860 occurred at SQLite.lvlib:Connection.lvclass:Execute SQL (No results).vi:3980001:Step SQL--> "SELECT load_extension('C:\Program Files\National Instruments\LabVIEW 2025\vi.lib\drjdpowell\SQLite Library\SQL Connection\extension-functions_64.dll');" MAIN db name-->"C:\Projects\A Project\A Project_Config\Unit_SomeUnitId\database\hse_test_sqlite.db" SQLITE_ERROR(1): The specified module could not be found. Possible reason(s): SQLite returned SQLITE_ERROR(1), see www.sqlite.org/rescode.html#error Any suggestions towards solving this would be greatly appreciated. Thanks!
  19. @sts123 You can explore the String palette where you will find an array of string formatting nodes. The simplest for you is to replace the date/time string with Format into string, and configure for scientific number.
  20. I have this .vi that converts the .TDMS to ASCII. However at the moment the time format is "00:00.000001 5.2041 0.2388 -0.0004 0.9106" for each line. How can I make it in seconds in scientific format so the data will show as "1e-6 5.2041 0.2388 -0.0004 0.9106"? Also how can the headers be added into the ASCII file? to_Asci_2.vi
  21. Earlier
  22. They use the same channels. OK, thanks. Good to know I cannot run two task with same channels simultaneously.
  23. Use probes to check if there is an error: right click the wire and select "Probe" in the read loop. Do Hi_Rate_Volt and Hi_Rate_Trig use the same channels? You cannot run two tasks at once that use the same channels.
  24. Thanks for the .vi. Seem like the notifier is being passed to the new loop, as new .tdms file is created, but the loop inside the case structure is not being executed, hence the data is not being written into that file. The count stays at 0.
  25. Sorry, I misunderstood. So when the threshold is crossed, the Hi_Rate_Trig task should start, but Hi_Rate_Volt should continue? There are plenty of ways to do that. One is to use a notifier for communicating from one loop to another. The loop that should be triggered waits for a notification, which the slow sampling loop will send when the threshold is crossed. The data and type of the notifier don't matter in this case. The triggered task can run multiple times, which may or may not be desired. A notification can also be send while the trigger task is running and it will then run again after it has finished. R_R_9_MTDS_Split_Rec_retrig_CM.vi
  26. Not sure if I understand... I want the loop when meets condition not to stop but carried on. At the moment there is an "OR" block that is connected to the LED and to the stop loop.
  27. Sure, just wire another button to stop those loops.
  28. I once went for an interview where they gave me a coding test and asked me to modify it. It was a very long time ago so I don't remember the exact modification they wanted (nothing to do with memory leaks) but I do remember the obtain queue and read queue inside a while loop with the release queue outside. I asked if they wanted me to also fix the memory leak as well as the modifications and they were a little puzzled until I explained what you have just said. I must have seen (and fixed) this while-loop bug-pattern a thousand times since then in various code bases. I also created this VI which I generally use instead of the primitives as it intialises on first call, can be called from anywhere, and prevents most foot-shooting by rolling them all into a single VI and ensuring all references but 1 are closed after use. Queue.vi
  29. Some people might be tempted to use Obtain Queue and Obtain Notifier with a name and assume that since the queue is named each Obtain function returns the same refnum. That is however not true. Each Obtain returns a unique refnum that references a memory structure of a few 10s of bytes that references the actual Queue or Notifier. So the underlaying Queue or Notifier is indeed only existing once per name, BUT each refnum still consumes some memory. And to make matters more tricky, there is only a limited amount of refnum IDs of any sort that can be created. This number lies somewhere between 2^20 and 2^24. Basically for EVERY Obtain you also have to call a Release. Otherwise you leak memory and unique refnum IDs.
  30. And are you sure your Rust FFI configuration is correct? What is the LabVIEW API you call? Datatypes, multiple functions? Basically your Rust FFI is the equivalent to the Call Library Node configuration in LabVIEW. If it is anything like ctypes in Python, it can do a little more than the LabVIEW Call Library Node, but that only makes it more complex and easier to mess things up. And most people struggle with the LabVIEW Call Library Node already mightily.
  1. Load more activity
×
×
  • Create New...

Important Information

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