How can I keep a state machine readable when using large amounts of in/outputs

Hello, I am new to Labview,
Read trough the fundamentals and the
getting started and a lot of examples.
What I want to do is use a standard
state machine from the template, and add some stages, for example
orange, apple, banana. At this point I can use numeric controls to
put in the amount of oranges, apples, bananas there are. I can even
use a led to tell the user which state of the state-machine is
active.
The thing is there will be more numeric
controls and more leds and it would be nice if the code would still
be readable when there are 20 inputs and 20 outputs.
Questions
(1) It would be nice if I could use the
typedef to select the right state AND the corresponding numeric
controls and leds out of a cluster or an array kind of structure to
keep the number of wires low. Is this possible, how can I do this?
(2) I tried to put the numeric controls
into a cluster but that way I can't put the numeric control for the
apples in the upper right corner and the numeric control for the
oranges in the lower left down corner of the front panel.
(3) An example would be really nice, I
know that I saw some examples describing this problem but there are
so many examples that after a few hours of searching I haven't found
the right one yet.
Thanks in advance for the effort.
p.s. I will not use Labview to do
calculations on fruit, I am only using this to make the question
easier to understand.

I can only start a proper answer but I might as well start with that.
When I am developing State Machines I have to think about what data is used and manipulated in each state. I then have to think about where am i going to keep and manage the data. I list all of the fields that are "touched" in each state and what values are used together and which are independent form the others. After this phase of the analysis, I usually have some data structure defined (cluser array etc).
Then I flipp from thinking about the state to thinking about the data (after all this is LabVIEW and the data-flow paradigm is critical). If I see data that is only used by the State machine and is used in many of the states, then the data structure get put in a shift-register for easy access in each state. This maybe enough of an answer for your fruity question.
When i see data that is shared or only used in a handful of states then I concider putting the data in an Action Engine. Depending on how you design your AE, you can access each of the fruit totoal by name or increment etc as required.
If your app demands many fileds that are all related (can't be broken into distinct data structures) then create a cluster that has all of your values that are used by the AE. Then create an Wrapper VI for each call of the AE but only put the associated fields on the FP of the wrapper and then bundle that value into the cluster and invoke the AE.
Ben
PS: Sorry about reverting to neBulus mode but this topic could take days to cover in detail.
Ben Rayner
I am currently active on.. MainStream Preppers
Rayner's Ridge is under construction

Similar Messages

  • How can I keep emails and read later when off line please

    How can I keep email to read later when off line please

    I'm not sure how it works on your iPad, but once the email has been downloaded onto my iPad, I can read them even in Airplane mode with WiFi disabled. I don't see the images that are in the emails, but I can read the messages. I have one POP account and three IMAP accounts and it works for all four accounts.

  • How can I keep a playlist on phone when syncing with new computer?

    When syncing my IPhone I am prompted with an ominous message that says "Are you sure you want to remove the existing music ... from this phone and sync with this ITunes library? Music .... will be removed and items will be synced from this ITunes library" The answer is no because I have a playlist I would like to keep on the phone, but add one which resides on the computer I am attempting to sync with. That is not an choice presented, the choices are Cancel or Remove and Sync. Apple should either give more options or at least a better explanation. I have synced this phone and computer combination before but have since created a new playlist in the computer (a Mac Mini).
    So how can I keep a playlist on the phone and add one from the computer too? Is it possible to view the phone as a drive and move items around in that manner? I use ITunes on both Windows and Mac platforms but this issue has always been problem for me. I also have IPhone 3 (used as an IPod), IPhone 4S and Iphone 5.

    Unless you can get the iPod backup file (and restore the iPod from that file on your new computer) from the "dead" computer you will lose all the app data you can export via email.
    - Yu can trabsfer iTnes purchases from the iPod by:
    iTunes Store: Transferring purchases from your iPhone, iPad, or iPod to a computer
    - You can transfer non-itunes purchased music to the new computer by using one of the third-party programs discussed in this previous discussion.
    Best iPod to PC
    - After you move the stuff to the new computer, either restore the iPod from the backup, or if no backup, restore to factory defaults,new iPod and sync.

  • How can I disenable the EXCEL field format when use ALV download to excel ?

    Dear friends,
         I have a problem with the ALV download to EXCEL. One field Value in ALV is like u2018-abcdeu2026u2019.the character u201C-u201Cis the first   position  in field value.when I download  the value to EXCEL,the field value u2018-abcdeu2026u2019 changed u2018=-abcdeu2026u2019 in EXCEL.how can I remove u2018=u2019 in EXCEL when I down to excel used ALV.
    I add a space in u2018  -abcdeu2026u2019,So this value can be download to Excel .
    Have you any solve method?
    User does not use excel logo button to download.
    User use Local fileu2026 button to download
    Thanks
    Sun

    add a single quote to the beginning of the field.
    like:  '-abcde
    in excel it will be shown as : -abcde

  • On Illustrator CS6 (Mac OS) how can I keep an open file minimized when opening other files?

    I work with several files at a time and it can become annoying when you open several files and a minimized file keeps opening after each one.  I don't want to have it open in the background, I just want it to stay minimized until I'm ready to work with it.
    Thanks in advance

    Hi Lytle,
    Let me clarify few more things here. There is an option Window>Arrange>Float in Window / Float All in Windows. You can use this option to float all your documents i.e. make them in separate document window. Now you can minimize these individual windows. But, when you open any more document your last active document window will come into focus. To avoid disturbing minimized state of other documents you can keep a blank document floating and before opening any document make it active and then open any new document. This is a kind of workaround to get rid of this issue.
    Hope it helps!
    Thanks!
    Dhirendra

  • TS4002 How can I change the email address in iCloud in setting and how can I keep from getting streams from family using this

    How can the email address be changed in iCloud
    My grand daughter us my iTunes account now I am getting her streams on on iPad and iPhone .

    You have to delete the old account, provide the password for the old ID when prompted to turn off Find My iPhone, then sign back in with the ID you wish to use.

  • In MIRO, how can I get a credit to balance when using dr/cr lines?

    When processing a logistics invoice verification document via MIRO, we're trying to post a credit memo against a purchase order with muliple lines (one return, and on non-return line).  The value of the return line is greater, and the invoice is billing for receipts/returns on mulitple lines on the PO (it has a credit amount for the entire return to be posted against the return line, and a restocking fee to be posted against a text based PO line). 
    In MIRO, I have selected credit memo and am posting a credit for a gross amount of $550 in the header.  The return line I'm trying to post against is for $575, and the non-return line for the restocking fee is for $25.  However, when I'm posting against both, the system is indicating that I'm out of balance by $50.  It appears that it's not calculating the $25 as a credit.  I've tried looking at documents around posting against returns and posting credits, but haven't seen anything that addresses this scenario.  I've also tried using negative amounts, but SAP does not accept these.  We're currently using SAP ECC 6.0.  How can I get this to balance?

    Only Apple Account Security could help at this point. You can try calling Apple Support in Canada - you'll have to find one of the several ways, such as Skype, to call an 800 number from outside of the relevant country - and ask for Account Security and see if they can help. Or you can find a friend who speaks Chinese and ask them to help you talk to Apple Support in China. There are really no other options that I know of.
    Note, by the way, that these are user-to-user support forums. You aren't speaking with Apple when you post here.
    Regards.

  • How can I control creation of empty tags when using ora:view syntax?

    I'm using XMLQuery and ora:view syntax to create xml resources in the database but I'd like to be able to prevent the creation of empty tags for null values in the table.
    CREATE OR REPLACE PROCEDURE proc_ctsi_build is
    XMLdoc XMLType;
    BEGIN
    DBMS_XDB.deleteResource('/public/CTSI/ctsi_phsall_rpt1.xml',1);
    SELECT XMLQuery(
    '<Progress_Report>
    <Personnel_Roster>
    {for $c in ora:view("CTSI_INVEST_SOURCE_V")
        let $username  := $c/ROW/COMMONS_USERNAME/text(),
    $expertise  := $c/ROW/AREA_OF_EXPERTISE/text()
         return
      <Investigator>
       <Commons_Username>{$username}</Commons_Username>
    <Area_of_Expertise>{$expertise}</Area_of_Expertise>
    </Investigator>}
    </Personnel_Roster>
    </Progress_Report>'
    RETURNING CONTENT) INTO XMLdoc FROM DUAL;
    IF(DBMS_XDB.CREATERESOURCE('/public/CTSI/ctsi_phsall_rpt1.xml', XMLdoc)) THEN
    DBMS_OUTPUT.PUT_LINE('Resource is created');
    ELSE
    DBMS_OUTPUT.PUT_LINE('Cannot create resource');
    END IF;
    COMMIT;
    END;
    In this example how can I prevent getting <Area_of_Expertise/> in my output when AREA_OF_EXPERTISE is null in the table?
    Thanks

    Hi,
    you can use if else conditions.
    {if ($expertise) then
    <Area_of_Expertise>{$expertise}</Area_of_Expertise>
    else ()}
    **not tested**
    Ants
    Message was edited by:
    Ants Hindpere

  • How can I keep my screen captures sharp when exporting to PDF?

    I've tried using a screen capture tool that allows me to snag in the exact size, plus I changed downsampling to none in the export settings, but the screen captures still look blurry in the PDF. What else can I do to keep them looking sharp?
    My client insists on using InDesign to lay out this presentation and wants a sharp looking PDF to send to clients.

    Ok, there's the problem. You turned off effective compression of the photos.
    I don't know how, or whether, you can have different compression for different image classes in InDesign. That's really a question for an InDesign forum.
    Good luck!

  • How can I keep the file size small when I render a .mov file to video in PS entended CS4?

    Hi,
    I haven't worked with video in Photoshop before and I am having the following issue:
    I imported a .mov file into photoshop. I trimmed the file by moving the start and finish points to the relevant points on the timeline. I then cropped the image to get rid of unwanted footage on the edge of the screen. I then selected export - render video. On the panel I chose to select only "currently selected frames" as the range and I chose "Quick Time Movie" as the file type. When I check the properties of my newly rendered movie the file size has increased by several times. The file sizes are now much too large.
    I know that I must need to alter some of the render settings but having tried altering many of the settings the result is always the same - a very large file size that is much bigger than my oringinal file.
    If anyone can let me know how I can carry out a simple crop & trim on a .mov file and end up with a smaller more compact file after rendering the video I would really appreciate it. Thanks in advance!

    Hi Marion,
    Thanks very much for your message. I have downloaded that program and it's definitely handy for examining the details of the original file. You mentioned in your message about not having to recode the file - The file I'm editing is originally from a Q3 Zoom video recorder and I can use their in-built software (handyware) to trim the file - this doesn't recode the file and so the file size just reduces by the required amount. Unfortunately there is no facility to crop the file with this software - I've looked for other software that would allow cropping without having to recode the file but I haven't found anything suitable for a simple procudure like this - do you know of any software that allows you to crop a file without recoding? Thanks.

  • How can I keep the file/ album names when copying music from the Finder to iTunes?

    Hi,
    Is there a possibility to keep the file names one uses in the Finder when adding music to iTunes?
    [e.g. that a Beethoven symphony still ends up under 'Beethoven/ symphony No./' and not under the name of the orchestra/ dirigent]
    Thanks in advance
    Kath

    Yes.  Go into Preferences and make sure that "Keep..." and '"Copy..." are both not checked.  Then put the file(s) where you want them (preferably somewhere in your iTunes Media folder) and use the command File > Add File (or Folder) to Library.
    Try this first with a file or two so you can see that it keeps the same file name as it adds to your library.

  • How can i keep the screen from dimming when reading sth.?

    as above

    Screen dimming is an operating system function; I'm not sure if any program can actually disable that.

  • How can I keep bootable partitions from showing when I want to use my usb stick without the option command at boot up?

    Im using a usb stick with bootable diagnostic partitions and a extra partition for diags that run in the OS. When i want to use diagnostics from this extra partition on a mac thats already booted, I have to wait for all the bootable partitions to mount as well as the one partition that I need. Is there a way to hide these bootable partitions when using the usb drive as a storage device to run diags in the OS?
    Thanks

    I think I may have to look into a redirect line in my htaccess file so that direct loads of my mp3's route through my website page.
    If you do this you may find iTunes won't read the files, so I should test carefully on one file first if possible.

  • How can I keep multiple tabs to reopen when I relaunch browser?

    I just downloaded Firefox 8.0. NOW I cannot reopen my browser with the 8 or so tabs like I used to do previously? Please suggest if this is possilbe. Thanks.

    Hi - it still did not contain a precise response to my problem. But then I wandered around some more in the Tools option and found "always show the tab bar". I unchecked that, and it seems that for now all the tabs are gone. Shall have to see if they return on restarting or rebooting. If so, will post back. Thanks.

  • Exporting to PDF - How Can I Get A Small File Size When Using Lots of Vector Art?

    I am trying to create a small PDF file for e-book distribution purposes. My Indesign pages contain a variety of photographs, vector icons and vector maps.
    A publisher in Britain who does similar books on a Mac using Creative Suite was able to create a 22-page document very similar to mine (similar icons, graphics, density, etc) that is only 2.84 mb, a small fraction of the file size that I'm getting! I've included a sample page of his below, which is a low-res jpeg, but on the original PDF all of the text and images (except the jpeg cliff background) are super sharp - they look like vectors when you zoom in. I've also included screenshots of his PDF export settings.
    I don't know if he's exporting directly out of Indesign, but my best guess is that he is.
    My vector-based icons, numbers and maps are bloating my PDFs considerably. When I remove them, the Indesign and exported PDF file sizes drop dramatically. For the life of me, I can't figure out how he got such small PDF files sizes using so much vector art! The PDF graphic compression settings don't seem to include any options for vector art.
    My vector art graphics (numbering, icons, maps) are all saved as Illustrator AI files and then placed in Indesign as linked graphics. My best guess as to why I can't achieve smaller PDF files is I'm either doing something wrong with the vector graphics themselves or handling/exporting them improperly out of Indesign.
    I am using CS4 for PC and am on a Dell Machine running Windows 7.

    I am trying to create a small PDF file for e-book distribution purposes. My Indesign pages contain a variety of photographs, vector icons and vector maps.
    A publisher in Britain who does similar books on a Mac using Creative Suite was able to create a 22-page document very similar to mine (similar icons, graphics, density, etc) that is only 2.84 mb, a small fraction of the file size that I'm getting! I've included a sample page of his below, which is a low-res jpeg, but on the original PDF all of the text and images (except the jpeg cliff background) are super sharp - they look like vectors when you zoom in. I've also included screenshots of his PDF export settings.
    I don't know if he's exporting directly out of Indesign, but my best guess is that he is.
    My vector-based icons, numbers and maps are bloating my PDFs considerably. When I remove them, the Indesign and exported PDF file sizes drop dramatically. For the life of me, I can't figure out how he got such small PDF files sizes using so much vector art! The PDF graphic compression settings don't seem to include any options for vector art.
    My vector art graphics (numbering, icons, maps) are all saved as Illustrator AI files and then placed in Indesign as linked graphics. My best guess as to why I can't achieve smaller PDF files is I'm either doing something wrong with the vector graphics themselves or handling/exporting them improperly out of Indesign.
    I am using CS4 for PC and am on a Dell Machine running Windows 7.

Maybe you are looking for

  • Safari and airport problems

    Safari started about a month ago getting hung up when loading, ending up with just not loading at all. Then I started getting messages that I was unable to join my network. I can get online at my office wirelessly(different network)but Safari is stil

  • IPod 5g 30gb freezes...iTunes...Failed-Delayed Write Error

    For some reason my iPod is just going whacko! When I plug it into my computer everything is reconized fine, and iTunes starts to sync the iPod with my library...after about 45sec. of "coping" the iPod screen freezes, and then an error message comes u

  • MSI R5570. Good Value Performing Card

    Just tested this new R5570 video card from MSI. This VC sits between the entry-level 5450 and the mid-entry level 5670. So I guess it's a value card with performance.  The good thing about this card is, it is specially designed for HTPC types of PC a

  • Audigy 2 H

    Hi just wanted to know if anyone has hacked or upgraded their Audigy 2 card by a soft mod or some way to something noticeable like an Audigy 4 or X-Fi? Thks

  • Link Purchasing Vendor to Paying Vendors

    Dear Gurus, How can we link multiple purchasing vendors to a single paying vendor? Thanks. regards, Raj