Jump to content

crossrulz

Members
  • Posts

    531
  • Joined

  • Last visited

  • Days Won

    21

Posts posted by crossrulz

  1. What is the communication bus that is used to talk to the instruments?  Assuming anything VISA, it is likely that the communication time will swamp out any gains from going parallel.

    As a gut feel, I would likely go with the Parallel FOR Loop simply because it is easier to code up than two FOR loops (one to launch the VIs and a second to collect the results).

  2. On 3/5/2024 at 9:55 AM, crossrulz said:

    FYI, there is a new feature in LabVIEW 2024Q1 where can wire the reference to the VI Path input on the Open VI Reference.  You do also need to wire up the Type Specifier if you need the strict type.  NI has stated the need for the type specifier  as a bug per this thread on the dark side: New Open VI Reference Functionality

    Update:  There is now a 2024 Q1 patch that fixes this bug.  So you no longer need to wire up the Type Specifier when using the static VI reference wired to the VI Path input on the Open VI Reference.

    The patch also covers several security issues.  Those who are using 2024Q1 really should go into NIPM and get the update.

  3. On 3/5/2024 at 7:32 AM, Francois Aujard said:

    Thank you all for your answers

    In the end, only the first one is useful. Is there a case where I might prefer the 2nd or 3rd solution over the first?

    In fact, the 2nd solution will always be waiting for the end of execution, even if you set the option to call and forget

    494167725_DynamiqueCalloptionx80.PNG.da66e8b28664f8fa41de9608227f9a83.PNG

     

    FYI, there is a new feature in LabVIEW 2024Q1 where can wire the reference to the VI Path input on the Open VI Reference.  You do also need to wire up the Type Specifier if you need the strict type.  NI has stated the need for the type specifier  as a bug per this thread on the dark side: New Open VI Reference Functionality

    Call Waits_BD.png

    • Thanks 1
  4. Top: Start Asynchronous Call - Loads a VI, starts running the VI, and then waits for it to complete.  The SAC returns as soon as the VI has started to run.  The Wait On Asynchronous Call is what waits for the VI to complete and return its outputs.

    Middle: Call By Reference - Loads a VI and runs it.  The CBR will not return until the called VI is complete.

    Bottom: Run VI Invoke Node - Loads a VI and runs it.  If you wire FALSE to the Wait Until Done input, the VI runs asynchronously.  If you wire a TRUE to the Wait Until Done input, the invoke node will not return until the VI is complete.  You do not have a direct way of getting the results once the VI is complete.

    • Like 1
  5. 11 hours ago, codcoder said:

    So yes I went for "brute force".

    But I managed to solve it using VI scripting, i.e. automatically creating undbundle-by-name from the public cluster to bundle-by-name to the private cluster. So even if the creation process is obscure the result is easy to read by someone who knows only little LabVIEW. Which was what I was aiming for.

    Sounds like an OOP solution is what you really want.

  6. 48 minutes ago, HYH said:

    And then NI killed both CDS ( without warning ) and MathScript ( with years of warning ) here in 2023. CDS was NI's own re-implementation of MATRIXx, which they got/bought back in 2003. 

    It took me a bit of time to figure out CDS is LabVIEW Control Design and Simulation Module.  Yeah, that kind of came out of nowhere, but it was really only used in academia as far as I am aware.

    MathScript was also dropped mostly due to it being a major PITA to maintain, especially since Matlab was such a better product to do something very similar.  As soon as NI and Mathworks became friends, I saw this coming.

  7. 1. Move the VISA Configure Serial Port to before the loop.  No need keep re-initializing it.

    2. You shouldn't need the Flush Buffer.

    3. You should not need the wait.  This would also eliminate the need for the Sequence Structure

    4. Since you are expecting a response immediately after you send the command (or soon after), you should not be checking the Bytes At Port.  This would eliminate the need for the Case Structure.

    5. Because of the termination character, tell the VISA Read to read more bytes than you expect back.  In this case, I would probably use 50.  The read will complete when the Line Feed is encountered.

    6. Since you are dealing with space separated data, use the Spreadsheet String To Array with a space set as the delimiter to make an array of strings, each element corresponding to a piece of data.  You can use Index Array if you really want them separated out.

  8. 22 minutes ago, hooovahh said:

    I remember a presentation by Jack Dunaway years ago at NI Week I think that talked about some of the event behaviors, and how it has changed in some releases.  This was in the 2012 era.

    Then, a couple of years later, NI completely redid how events work behind the scenes which corrected some things Jack mentioned, complete with an NI Week presentation.

  9. The announcement for the acquisition did happen in early April.  Now it is just waiting for approval by the US government and who knows what other legal red tape for it to actually happen.  One of the articles mentioned the acquisition finalization was expected to be in Emerson's financial 2024 H1, which starts in October.  Do not expect to hear anything until that happens.

×
×
  • Create New...

Important Information

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