BreakPoint

cancel
Showing results for 
Search instead for 
Did you mean: 

Rube Goldberg Code

 
Sometime we need to clear a string indicator by writing an empty string to its terminal. Here's the Rube Goldberg way.
 
  • Of course if the content of the string was concatenated from 5 substrings, we need to concatenate five empty strings to match it 😮
  • We also cannot really trust a single wire, so we need to branch it and write to the indicator terminal AND to a local variable of same.
  • Now can we be double sure that that sucker gets really cleared. 😄
  • For government applications, we should actually add a few more copies of the local variable to bring it up to specs.

(from http://forums.ni.com/ni/board/message?board.id=170&view=by_date_ascending&message.id=294413#M294413)



Message Edited by altenbach on 01-11-2008 11:14 AM


LabVIEW Champion. It all comes together in GCentral GCentral
What does "Engineering Redefined" mean??
Message 121 of 2,324
(14,393 Views)
Christian wrote

  • For government applications, we should actually add a few more copies of the local variable to bring it up to specs.

  •  
    You had me scared there for a second.   I do a fair amount of gov. work and need to keep up on req's.
     
     
    Ben
    Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
    Message 122 of 2,324
    (14,370 Views)
    LOL! @ Altenbach..
     
    I can almost not believe that it was true..  Wow!  LOL!! 
     
    LOL!!  😄 😄
     
    Now that's a funny RG code!
    LOL!!
    Message 123 of 2,324
    (14,352 Views)
    If monitor resolution was truly unlimited, we could easily manage a diagram that is 14285 pixels wide and 3354 pixeld high.
     
    Here's how it looks if I scale it down to 5% (!!) of the original size in a graphics program: 😮
     
     
    Note: each of the inner stacked sequences has 10 frames. Maybe we should convert those to flat sequences. 😄
     
    Suddenly, a state machine does not sound like such a bad idea. 🙂
     



    Message Edited by altenbach on 02-01-2008 10:59 AM

    LabVIEW Champion. It all comes together in GCentral GCentral
    What does "Engineering Redefined" mean??
    Message 124 of 2,324
    (14,246 Views)

    Altenbach,

    I admire your tenacity at looking at such diagrams.. 

    It takes courage.... and probably some strong beverage at the end of the day.. 😄

    Message 125 of 2,324
    (14,227 Views)
    Sometimes it may be better if the code does take up more than one screen!
     
    This is the most densely packed code I've seen.
     
    And what is the purpose of feedback nodes on error clusters that aren't even part of a loop?  It makes it hard to tell which is the first function that executes.  Is that so you can hold on to errors from the last time you ran the program?  "I had an error and stopped the program, but everytime I restart it won't work and I get the same error!  I can't figure out why!!!"Smiley Very Happy
     


    Message Edited by Ravens Fan on 02-05-2008 12:08 AM
    Message 126 of 2,324
    (14,204 Views)
    [And what is the purpose of feedback nodes on error clusters that aren't even part of a loop?  ]
     
    maybe they are being used as a direction indicatorSmiley Very Happy
     
    Regards
    Ray
    Regards
    Ray Farmer
    Message 127 of 2,324
    (14,202 Views)
    Most likely the author of this code wire things randomly together, accidentally creating loops and these feedback nodes were inserted automatically (the "auto inser feedback nodes in cycles" option is enabled by default). For example you can delete the rightmost feedback node and simply wire the remaining ends together and the feedback node will magically reappear.
     
    I wonder why all calculations are done in DBL, but displayed as SGL. 😮

    LabVIEW Champion. It all comes together in GCentral GCentral
    What does "Engineering Redefined" mean??
    Message 128 of 2,324
    (14,198 Views)


    Ravens Fan wrote:
     
    This is the most densely packed code I've seen.

    I guess you weren't looking hard enough. I title this post "Scary Code" (note the zoom window):
     

     
     
     
     
     

    ___________________
    Try to take over the world!
    Download All
    Message 129 of 2,324
    (14,167 Views)
    You're right that is scary. And worse.  I especially like the amount of overlapping and parallel wires in the right hand side of the window of the top picture.
     
    I was impressed with how in my example, the programmer worked hard to really compact everything, and by doing so was able to squeeze it into much less than one screen, so it was like they were trying to follow one style rule!
    0 Kudos
    Message 130 of 2,324
    (14,163 Views)