Jump to content

LogMAN

Members
  • Content Count

    358
  • Joined

  • Last visited

  • Days Won

    27

Posts posted by LogMAN


  1. Very strange indeed. You are right, these extensions should not affect any of this.

    I just installed the "Disable JavaScript" addon and can reproduce your behavior with the download button and version selection. In my earlier post you see the "normal" page. This is how it looks with JavaScript disabled:

    Also, the download button now statically points to http://www.ni.com/en-us/support/downloads/software-products/download.labview.html#

    1712727037_DownloadNoJS.jpg.ce73da0c0a5d39531bbe90b1dab2201f.jpg


  2. 13 minutes ago, Rolf Kalbermatter said:

    I get redirected to the nl-nl page anyhow no matter what I do.

    You need to change the location manually at the bottom of the page. After that you should always get to the same site.

    2019-06-11_14-53-42.jpg.d12ef5cacb8165d0a5286d51bd792848.jpg

    13 minutes ago, Rolf Kalbermatter said:

    And on that I can't download any versions prior to the 2019 version no matter if I only select the runtime version or if I'm logged in or not.

    That is strange indeed. I just tried on another browser and can't seem to recreate this behavior, no matter which location I choose.

    13 minutes ago, Rolf Kalbermatter said:

    On the page that I get to when clicking on the LabVIEW icon on the earlier mentioned download portal I get to https://www.ni.com/nl-nl/support/downloads/software-products/download.labview.html# (without the number at the end) and while it seems I can download anything (the Download button is always enabled), nothing happens except a page refresh when pressing that button.

    Do you have extensions installed which block JavaScript or tracker?

    They can sometimes cause strange results like this, especially if contents are dynamic (as the download button or the lock for Linux/Mac versions).


  3. 7 hours ago, MikaelH said:

    Where did patch LV2018SP1 f4 go?
    http://www.ni.com/product-documentation/55001/en/

    The link at the bottom will bring you to this page http://www.ni.com/en-us/support/downloads/software-products/download.labview.html#305508

    You just have to select 2018 SP1 Patch and click download. This will download the f4 (latest) patch.

    147534969_LV2018SP1f4Download.jpg.d48e5f99fb332e6e1bc3321110a66989.jpg

    17 minutes ago, Rolf Kalbermatter said:

    However that page is borked in many ways (as a lot on the NI webserver)

    The en-us version is pretty stable in my experience (except for a few dead links here and there). Can't say much about the others.

    19 minutes ago, Rolf Kalbermatter said:

    and depending on from where you come it won't allow you to download anything (even simple runtime installations) even if you are logged in with an account that has an associated SSP license, or it will allow you to download absolutely everything even without valid user account login😭 Why am I not surprised!!

    I'm still surprised they bother to check the associated SSP. Considering that the License Manager checks it anyway.

    • Like 1

  4. Here are some additional pointers that might be helpful

    I also found a blog post with pictures that show the general process for customizing controls.
    https://www.dmcinfo.com/latest-thinking/blog/id/9428/basic-labview-ui-control-customization

    If you are interested to see what is possible with LV, search for "2016 NIWeek - Designing Advanced User Interfaces in LabVIEW".
    https://lavag.org/topic/20645-labview-videos-tecnova-download-site/

     

    • Thanks 1

  5. Disclaimer
    The following details are oversimplified for the sake of clarity. Feel free to point out important details that aren't covered by this post.

    ---

    There is a higher chance of finding better results by searching for "labview reference". Here are a few examples.

    That said, you should be familiar with the normal data flow in LabVIEW.

    • Data goes from one end of a wire to the other.
    • A branch in the wire will create a copy in memory if either branch of the wire is changed.

    Loosely speaking, a wire represents the data.

    A refnum on the other hand doesn't represent the data, but the location of the data in memory (*). It is similar to a pointer in C-like languages.
    This changes the behavior of the wire

    • Data still goes from one end of a wire to the other.
    • Each branch of a wire receives exactly the same value as the other (no copy is made). (**)
    • In order to access the data you need to make use of Property Nodes, Invoke Nodes and more.

    The benefit is, that you can access the same value from different places in your program. Even better, this is not limited to controls.
    It works for controls and indicators, VIs, objects, the project, the whole application and everything.

    However, it doesn't work for variables and due to its nature, race conditions can occur if you don't take care of the execution in your program.
    This is why for variables there is a more specialized type of reference, the data value reference (DVR). It allows you to access the same variable in memory from different places in your program.

    There is obviously much more to it than these few points. However, the links above should give you some insight.

    (*) Here is some information about the memory structure of a refnum. https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019ZT5SAM&l=en-US

    (**) Technically speaking a copy is still made if you change the "value" on either branch of the wire, but since it is a pointer you shouldn't change it under any circumstances.

    • Like 1
    • Thanks 1

  6. 4 hours ago, 0_o said:

    How do you organize important posts you read and want to save for the time of need?

    Brain power and Google is the standard solution if the search box at the top doesn't satisfy you.

    That said, I'm using firefox, so Pocket is one way to keep track of it. https://www.mozilla.org/en-US/firefox/pocket/

    And of course you can make use of bookmarks in your favorite browser, but chances are high that it grows so much that you need Google again.

    4 hours ago, 0_o said:

    For example, I want to save an interesting post from Lavag/NI Forums or any other LV blog. 

    This post might contain VIs and I would like to tag it in a way that will let me find it when it becomes relevant.

    I would like such a post to be saved locally like an RSS so that I'll get the new comments and won't depend on the site to keep the links alive.

    Most of it can be done with Pocket. You get a button which you press while on the page. It stores the page in your Pocket (online) and you can add tags to it. You can also subscribe to an RSS feed of your personal pocket. But it doesn't update contents in your Pocket automatically and the RSS feed only contains the things you add to the Pocket.

    For live updates I suggest using the notification feature of Lava (mail based).

    4 hours ago, 0_o said:

    I see the veterans here keep track of all the new posts and even offer solutions by giving links to some old posts without having to search for them sometimes.

    Rest assured, searching was involved. hooovahh summarized it perfectly.

    4 hours ago, 0_o said:

    I hope to hear of some cool little RSS app that will let me search through the tagged vis and posts stored on my computer and not about some bookmark manager.

    To collect the information on your local computer you can use any feed reader you like. But I highly doubt there is any that automatically downloads attachments for you (because that is web scraping, not news reading).


  7. 32 minutes ago, rscott9399 said:

    I have a VI that is very complex that i did not write. Needless to say life is difficult right now

    ...

    AKA a complete bit 

    Thank you very much, this just made my day 🤣

    11 minutes ago, rscott9399 said:

    I have gone to the example folders and found the folder but its not in there

    You'll find the function on your palette under Timing.

    Alternatively press Ctrl+Space and write "Stall Data Flow", it should appear in the list.


  8. If I understand you correctly, there is a path like "C:\a\b\c" and you need the "\b\c" in order to use it as "D:\default\b\c", right?

    Use this to check if one path is relative to another http://zone.ni.com/reference/en-XX/help/371361R-01/glang/compare_two_paths/

    It returns the relative part which you can combine with your default path. I don't have access to LV right now, but this should be straightforward.


  9. 5 hours ago, LAVA Good said:

    How can I improve my while loop speed?

    There are multiple ways actually. Here are a few that come to mind:

    1. Let it run faster by adjusting the code inside the loop accordingly
    2. Split it into multiple loops to utilize more cores of your CPU
    3. Buy a faster computer

    Note that there is a limit to how many concurrent threads LV supports: https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000PARmSAO&l=en-US

    5 hours ago, LAVA Good said:

    And What is the maximum speed in while loop?

    The maximum speed of a while loop is only limited by the speed of your CPU at 100% load (and of course the way your operating system shares the CPU between processes and threads). That is assuming your loop does nothing, which makes it pretty useless. Of course, if your computer has multiple cores, you can run multiple loops in parallel to make use of them.

    4 hours ago, LAVA Good said:

    Oh my code is simple. I just want to know how to reduce loop speed :) anyway thank you for your reply

    This is contradictory to your first statement. I suppose you mean to increase the loop speed, right?

    If your code is simple, it should be easy to optimize for speed or to run multiple instances concurrently if applicable.

    • Thanks 1

  10. Here are some links to MS Docs that might be helpful:

    The second one is for Vista. I couldn't come up with any information on W10, so details can/will differ.

    Not sure if I misinterpret the information, but shouldn't the ARP table keep updating (i.e. not sending additional ARP requests) while packages are being transfered, or is this limited to TCP?

    If an entry is not used for a time between 15 to 45 seconds, it changes to the "Stale" state.
    Then, the host must send an ARP Request for IPV4 to the network when any IP datagram is sent
    to that destination.

    RFC 826 only mentions timeouts briefly:

    It may be desirable to have table aging and/or timeouts. The
    implementation of these is outside the scope of this protocol.

  11. On ‎2‎/‎5‎/‎2019 at 12:14 AM, Neil Pate said:

    On LV2015 Quite often LabVIEW will get itself into a mode where in order to box select something I have to go completely around it rather than just partially around iy. No idea what causes this to change, but it pops up on my dev PC every few weeks. No driver change has happened inbetween and then it usually just fixes itself.

    I just had this issue and found a way to reproduce (and fix) it:

    1. Create a new VI in a library (use the right click menu of the library to create the VI).
    2. Place the VI on the block diagram of another VI

    The VI is only selectable if the selection goes completely around it.

    To fix it, open the icon editor on the offending VI and simply press OK to close it.

    Now selection works as expected (i.e. partial selection selects the VI).


  12.  

    1 hour ago, smithd said:

    Its worth mentioning that LabVIEW should do this for you, its called loop invariant code motion, so don't worry about it for performance reasons.You should put the code wherever its more readable.

    Good point.

    Now that you mention it, the output of the multiplication functions are connected to a VI that (as far as I can tell) builds status messages and updates the progress bar (see the references connected to it). The output of that VI is displayed on the FP at a rapid pace.

    The VI obviously has too many responsibilities and should be split into multiple VIs. For example:

    • Calculate Progress
    • Calculate Estimate Time To Complete
    • Calculate Estimate Time To Next User Action
    • Display Progress
    • Display Status Message
    • Display Time To Complete
    • Display Time To Next User Action

    These VIs can be put in sequence, which makes it very easy to follow. It's also much more reusable than the current solution.

    I'm well aware that the example above is probably too fine grained for the purpose of this application, but there is a high chance that each of these VIs can be reused multiple times or even omitted if not needed. That is not possible with the current solution. That is probably why there are two Boolean constants attached to the VI right now (i.e. too enable features that are only required in this particular section of code).

     


  13. @smithd has stated very important points. It's also very important to get accustomed to techniques like the state machine in order to keep the code readable.

    However, in my experience it is very unlikely that

    a) shifting to a new system (like Teststand) solves the problem. That's for the same reason the previous one failed: A lack of understanding, planning and structure.

    b) using "better" techniques improve the application. Again for the same reason.

    c) replacing the current structure is even remotely possible because either the lead programmer left (or rather ran away) or it is too complex to comprehend.

    Edit: To clarify, you should take those solutions into consideration of course!

    This is of course my personal experience. Your situation may be entirely different.
    That being said, I'm sure we all have made these mistakes and learned from it. You should do the same.

    At first glance your VI looks confusing and hardly maintainable. On a closer look, however, it strikes me as a rather simple VI (i.e. not many different jobs going on at the same time) that only lacks structure and uses way too many indicators that presumably serve no real purpose other than being there (and maybe occasionally being viewed). I think the word we agreed on for such a VI is "paintainable", right?

    You asked for suggestions to improving your current situation, so find below a summary of what you can do, based on the code you shared:

    1. Remove code that is only meant for debugging purposes.

      With this I mean indicators such as the ones in the inner while loop. If the loop runs at max. speed, it updates the indicators every 20 ms. That is quite a bit faster than any human being can physically comprehend. Therefore, you have no reason to keep the indicators updating inside the loop. If you need to display the last value, simply move them outside the loop and use the last value.

      Once you removed the indicators, remove any code that isn't connected anymore. That should get rid of "dead" code.
       
    2. Take a closer look at the inner while loop and replace it by a for loop

      If you look closely, you'll notice that the inner while loop is actually a for loop. The conditions are:

      a) The boolean control "Stop Loops and Save Data 2" must be True, or
      b) The number of iterations is equal to the length of the "Frequency" array.

      Condition b) is clearly a perfect fit for for loops.
      Once you have made it a for loop, the second condition can simply be removed, which makes it a bit easier to understand.
       
    3. Move static functions outside the loop

      Inside the inner while loop are some multiplication functions that multiply values that come from outside the loop. These functions will always produce the same result inside the loop and therefore should be placed outside.
      It's a small change, but stuff like this makes the diagram easier to comprehend.
       
    4. Initialize the cluster outside the loop

      This is probably the biggest and easiest fix you can do.
      Take a close look at the "Bundle By Name" for your cluster in the loop. With the exception of two indexed arrays, all parameters are statically provided from outside the loop.

      You can easily clean up this code by initializing the cluster outside the loop and only add the indexed arrays in the loop.
      This should reduce the size of this loop considerably. It will also allow to see the purpose of the loop.
       
    5. Rearrange wires and don't hide wires behind structures or VIs

      This may sound like a lot of work (because it is), but one very important factor in LV is managing wires. There is actually a thread on LavaG dedicated to handling wires. I suggest taking a look, you can learn how other people do it:Take your time to remove wire bends whenever possible. I know it sounds ridiculous, but once you get accustomed to it you do it by reflex at which point you can start getting lazy again 😉

  14. 22 hours ago, ShaunR said:

    Bit lets be clear here. The issue isn't version performance, per se. It is a problem with redraw on certain platform configurations; the reason for which is unknown. My feeling is that it is something to do with the display driver as I have seen other spurious issues (such as not redrawing correctly when dragging) which were resolved with driver updates. 

    You are right, hardware and drivers probably play a huge part in it. In fact, the computer I use to record the videos isn't really up to the task, which is why it's easy to reproduce.

    19 hours ago, Neil Pate said:

    I think ShaunR is in to something here. On LV2015 Quite often LabVIEW will get itself into a mode where in order to box select something I have to go completely around it rather than just partially around iy. No idea what causes this to change, but it pops up on my dev PC every few weeks. No driver change has happened inbetween and then it usually just fixes itself. 

    That's really strange, can't say that I've ever had issues like that. Everything with the exception of structures and wires should simply work with partial selection. Does it only happen in LV2015?

     

    Oh and I finally figured out why the block diagram sometimes renders one line at a time like this: (sorry for the potato capture, it's impossible to capture the screen because the graphics driver is busy rendering lines)

    I can reproduce it 90% of the time on a decently slow VI using this method:

    1. Open a complex VI that slows down the editor (like the VI mentioned before)
    2. Select an area that has lots of stuff in it. The more elements are highlighted, the better
    3. Scroll the window down until some of the selected items disappear from the screen (it should lag)
    4. Quickly left click into a free area to deselect all elements and scroll up immediately (it's important to have a delay when deselecting and scrolling or it won't work)

    I've reproduced it in LV2015 and LV2017 and it happens maybe once per month on my dev machine. I'm curious if someone else has seen it?

    Any idea why this is happening? Can you reproduce it too?


  15. That is good news. Thanks for sharing, Darren!

    21 minutes ago, Darren said:

    Selection rectangles draw significantly faster in 2019. Window scrolling while dragging a selection box is also much faster.

    For reference, my dev machine is Win7-64, 16 GB RAM, E5-1650 3.5GHz. 

    Your hardware sounds reasonable. By significantly faster do you mean "fluently" or "stuttering, but not as much as before"?

    I'm so ready to replace LV2015 and finally get my hands on malleable VIs (not to mention all the other features that were added). Can't wait to finally try out LV2019.

×
×
  • Create New...

Important Information

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