Case structure and dynamic data, maybe once again

Hi there,
I`m a beginner in Labview. I´d like to know, how to handle the attached case-structure so that the structure works with each point of the signal.
Right know the signal is only analyzed one time.
Thanks for your help
Michael
Attachments:
prob.jpg ‏26 KB

Thank you Lars!!
Now it works
Solution is given as attachment
Attachments:
lsg.jpg ‏46 KB

Similar Messages

  • CASE structure limits - dynamic?

    Hello everybody
    Is this possible, and if, then how, to make the CASE structure
    condition dependent on variable in my program.
    Egsample: I have integer and the value of this is changing during
    program running, and I need from some reasons, to make the CASE
    structure sensitive for the values of this integer. How I can do
    this?
    I know there is always way around, but I am interested in this
    solution.
    thanks in advance
    regards
    PP

    Hi Pawel,
    I am starting a new thread because I think I know what you are asking for.
    First of all, you can not change the values of the case structure itself BUT,
    there is a way.
    What I suggest is the following;
    1) Code your second case as normal. Pretend it has 3 cases 0,1 &2.
    2) Code the first case (just example) such that is has two cases A&B.
    3)Have the first case state A return an array of (3)strings that is "Good", "Bad", and "Ugly".
    4)Have the first case state B return an array of (3) strings that is "Bad", "Ugly", and "Good".
    Feed the above mentioned arrays into a serach 1-d array function. Use the retuned index to select the proper case of "the second case".
    If you now pass "A" to the first case structure, and "Good" to the "se
    arch 1-d array" it will return an index of 0 and the second case will execute case "0".
    If you pass the first case "B" and again pass "Good" to the "serach...." it will return an index of 2 and the second case will execute state "2".
    So,
    by manipulating the arrays returned by the first case structure, you can "dynamically" influence which of the states of the second case is called.
    There are many variations on this idea that are possible. A similar approach would make it possible to select states based on wildcards and simulate "sparse enums".
    Did I nail it this time?
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Calculate maximum value of subarray while creating it using a case structure and shift registers

    I have two 1D arrays that contain cyclical information (kind of like a sine wave).  One that contains information on position in degrees and another that contains torque.  I would like to calculate the maximum torque value each time the position is within a certain range (e.g. from 30-80 degrees).  The ranges are repeated - that's why it is cyclical.   I use the "in range" function, a case structure and shift registers to build a new array with values that fall within the range I specify - this was the easy part (see VI attached).  I'm struggling with a way to calculate a maximum value for each subarray formed when values are "in range".   Your help is much appreciated.
    Solved!
    Go to Solution.
    Attachments:
    Simple Calculate between anatomical position range.vi ‏16 KB

    It's not really noise - it's more inconsistency.  So a position output can run: 20, 30, 40, 50, 60 etc.  OR, it could run: 21, 24, 32, 41, 44, 51, 59 etc. But, it is always cyclical. 
    Attached you will find a .csv file with the data arrays - I'm using POS (ANAT) degrees column (column D if you open in excel).  There you also see torque in ft-lbs along with some other information.
    Attachments:
    025C.csv ‏224 KB

  • TS2446 Account disabled message appeared. Tried to loggin with new password. Payment verification message appeared. When details are give Rs 60/- is charged and account is disabled once again.

    Account disabled message appeared. Tried to loggin with new password. Payment verification message appeared. When details are give Rs 60/- is charged and account is disabled once again.

    Hello Errappa,
    Thank you for using Apple Support Communities!
    I was thinking that it would be a good idea for you to call our Account Security team about what may be happening with the account.
    Note: You will need to be able to verify the account.
    Apple ID: Contacting Apple for help with Apple ID account security
    http://support.apple.com/kb/HT5699?viewlocale=en_US
    Cheers,
    Sterling

  • JSF and dynamic data

    Hi,
    This is not a specific question but rather a high level concept that I'm trying to figure out. I have a system that uses a lot of dynamic data that is handled and viewed in the form of Dynabeans as well as SDO data objects.
    I'm working on trying to develop reusable web widgets such as input forms based on these objects and thought of JSF right away.
    However its seems like JSF will only work with static data models because the beans and bean properties need to be specified at design time in the xml configuration files.
    Here it is: Lets say I have a dynamic java bean with dynamic properties that was created from a metadata object. Now I want to develop a single reusable JSF widget that will create an input form using the information from the metadata object and then connect the widget values to the actual dynamic data object.
    Seems like in order to do this, the properties of the dynamic data object need to be defined at runtime so that you can classify it as a managed bean so that JSF knows how to bind values from a widget to a bean.
    Does anyone have any thoughts?

    Hi.
    ValueBinding and MethodBinding work through PropertyResolver, VariableResolver
    #{aaaa.bbbb.cccc}aaaa - will be resolved with VariableResolver (root object)
    bbbb and cccc - with PropertyResolver
    Look at the description of the default realisation of VariableResolver
    You will see in which places it searches for a root object. At least it searches in the request, session and application maps. You can just put your dynamic beans in one of this maps.
    At the worst case you can substitute implementation of the VariableResolver in faces-config.xml
      <application>
         <variable-resolver>com.qqqqq.MyVariableResolver</variable-resolver>
         <property-resolver>com.qqqqq.MyPropertyResolver</property-resolver>
      </application>
    ...Good luck

  • Case Structure timing/ writing data to a excel

    Hi all,
    I have written a program that has the main functions of allowing the user to generate a random number between either 0-10 or 5-15 by using the labelled switch. I also have a control which can switch this function on or off. When this switch is true it will display the random number and also write this number to an excel spreadsheet every 1 second (I hope). When false this will stop displaying the number and hence not write the number to a file.
    However, I am having the following issues:
    1. Excel file is corrupt once I begin to write the generated numbers to the spreadsheet. (I am trying to write to a .xlsx file)
    2. Once I begin to try write the numbers to file, the elapsed timer only displays the time is 1second intervals rather than the full time.
    I changed the .xlsx file to a .csv file and this solved issue 1. but it only recorded one random number rather than the numbers that were generated in that time since switched on/off.
    Should I have the write to spreadsheet function in the timed case structure?
    Should the file path control be outside this case structure?
    Have I set up the write to spreadsheet VI correctly?
    If anyone could help with these issues that would be a big help.
    Thanks!
    Attachments:
    Random Number tester.vi ‏30 KB

    lneill65 wrote:
    There is still an issue with the elapsed time. Once I begin I turn the top boolean control to true, the elapsed time begins changing at the set time increment inside the case structure. Is there anyway to stop this from happening?
    Your elapsed time display is independent of the boolean switches because it is on the toplevel loop diagram. I am not sure why you place a five second wait inside the case structure if you want to write once per second.
    I am not sure why you have two sequential case structures since the calculations of the first structure is not needed unless the other case is also true. Why not place it inside the true case?
    You should also adhere to some basic coding styles. Avoid overlapping and floating objects, hidden wires, right-to-left wiring.
    If it is sufficient if the code reacts once per second, just run the loop with a 1 second wait. If you don't want to display a stale random number if the switch is off, place the indicator after the case structure.
    Here's a quick draft. Modify as needed. I probably would use an event structure, but let's keep it simple at this stage. You should also modify it so it does not try to write with an illegal path and also retain the selected path once selected. I propably would use a file dialog instead of a FP Path control.
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    Random Number testerMOD.vi ‏9 KB

  • Case Structure and String

    Hello everyone.
    I'm having some problems with my VI on Labview. I have as input a String that have in sequence: "Number of Sample/X Value/Y Value/Z Value", each of them separated by a comma. In the serial port I receive a loop of 500 samples from an accelerometer.
    I'd like to have Labview receive the values only when the String "Number of Sample" is 0 and graph them until the 499th sample is send and discard the data when is different from 0.
    My problem is the Case Structure, I can't manage to send data when the string is 0 and discard the data when is different from 0.
    I've attached my VI, any help would be greatly appreciated.
    Solved!
    Go to Solution.
    Attachments:
    Serial Port String.vi ‏17 KB

    Well, you appear to have LabVIEW 2013.  Did you know about the Conditional Tunnels that were indtroduced in 2012 and improved in 2013?  a quick mod to your code is attached.
    There are other opportinities to improve that code but, I'm assuming its only part of a larger vi (and a BD clean-up is in order)  Comments can also help make your code more readable
    Jeff
    Attachments:
    Serial Port StringJJB MOD.vi ‏23 KB

  • QR Code capacity with fixed rendered size and dynamic data

    There's a paper forms barcode and symbology is QR Code, layout is 46mm x 46mm, error correction level is M, module width is 0.592mm, and max capacity is Chinese(UTF8) x 88 or number x 627 or uppercase A x 380 or lowercase a x 263, and QR code renered size is about 30mm x 30mm when max capacity.
    So, my question is, if I want to ALWAYS keep this QR code renered size is same as max capacity(30mm x 30mm), but my daya is dynamic and mix numeric, alphanumeric and byte mode, is there any formula to calculate how may character such as space should be appended?
    thanks

    The more data you stuff into the barcode, the bigger it will be. I am not sure that there is a formula you can use to calculate how much buffer space you need to keep the barcode the same size. At least I have not seen one.
    For Designer, we offer these guidelines when using paper forms barcodes: http://help.adobe.com/en_US/livecycle/9.0/designerHelp/index.htm?content=000342.html

  • Getting Data from Structure and Store Data into Table using Function Module

    Hello...
    we are created a function module to import 2 structures in the systems and want to read the data from the structure into a customized table when the fucntion module is called. However, whenever the function module is run, we only managed to have one data into the customized table whereas the actual results is that there will be a few records in this customized table.

    Hi,
    It should be something like this...
    TABLES ZRESMORT.
    DATA E_ZRESMORT TYPE STANDARD TABLE OF ZRESMORT WITH HEADER LINE.
    SELECT * FROM ZRESMORT.    <=====================
      DELETE ZRESMORT.              <==================  It is deleting all the records in your Z table
    ENDSELECT.    <===============================
    Loop at I_CKF_CONTRACT.  " Assuming this is the Main Table
    Read table I_CKF_PROCESS with key ." Here you will read this table to get the corresponding records of Table I_CKF_CONTRACT
    E_ZRESMORT-MORT_FT_ID  = I_CKF_CONTRACT-COMMON-CONTRACT_ID_EXT.
    E_ZRESMORT-MORT_KDATE  = I_CKF_PROCESS-TECHNICAL-KEY_DATE.
    E_ZRESMORT-MORT_TSTAMP = I_CKF_PROCESS-TECHNICAL-TIMESTAMP.
    E_ZRESMORT-MORT_FLAG   = 1.
    E_ZRESMORT-MORT_BUPA   = I_CKF_CONTRACT-BUPA-BUSINESS_PARTNER_ID.
    E_ZRESMORT-MORT_PORTFO = I_CKF_CONTRACT-BUPA-PORTFOLIO_CAT.
    E_ZRESMORT-MORT_FT_ID_DUM  = I_CKF_CONTRACT-COMMON-CONTRACT_ID.
    INSERT INTO ZRESMORT VALUES E_ZRESMORT.
    IF SY-SUBRC EQ 0.
    ENDIF.
    endloop.

  • Dynamic node creation from RTTI structure and dynamic mapping

    Hi,
    I'd like to create a dynamic node in my component controller then map this node to a node in my view and bind it to a dynamic table.
    I create the dynamic node in my component controller using the add_new_child_node method :
    CALL METHOD root_node_info->add_new_child_node
        EXPORTING
          name                    = 'MY_TABLE'
          static_element_rtti     = struct_type
          is_static               = ABAP_true
        RECEIVING
          child_node_info              = node_info
    Then I use the add_new_mapped_child_node method to map the node in the view :
    * Map the context node dynamically
      wa_path = 'COMPONENTCONTROLLER.MY_TABLE'.
      insert wa_path into table tab_mapping_path.
      stru_mapping_info-controller = 'COMPONENTCONTROLLER'.
      stru_mapping_info-path = tab_mapping_path.
      lo_node_info = wd_context->get_node_info( ).
      CALL METHOD lo_node_info->add_new_mapped_child_node
        EXPORTING
          child_name      = 'MY_TABLE'
          mapping_info    = stru_mapping_info
        receiving
          child_node_info = lo_dyn_node_info
    The child node is created in my view context but it doesn't have any attribute or static element RTTI.
    Do I have to add each attribute with the add_attribute method and then the add_new_mapped_child_node method will copy them over?
    Regards,
    Pierre

    Problem solved, the path was not good :
    * Map the context node dynamically
    *  wa_path = 'COMPONENTCONTROLLER.MY_TABLE'.
    *  insert wa_path into table tab_mapping_path.
      stru_mapping_info-controller = 'COMPONENTCONTROLLER'.
    *  stru_mapping_info-path = tab_mapping_path.
      append 'COMPONENTCONTROLLER' to stru_mapping_info-path.
      append 'MY_TABLE' to stru_mapping_info-path.
      lo_node_info = wd_context->get_node_info( ).
      CALL METHOD lo_node_info->add_new_mapped_child_node
        EXPORTING
          child_name      = 'MY_TABLE'
          mapping_info    = stru_mapping_info
        receiving
          child_node_info = lo_dyn_node_info
    Regards,
    Pierre

  • Please Help: Trouble with nested CASE statement and comparing dates

    Please tell me why the query below is always returning the bold null even when the start_date of OLD is greater than or equal to the start_date of NEW.
    What I want to do is get the difference of the start_dates of two statuses ( Start_date of OLD - Start_date of NEW) if
    1. end_date of NEW is not null
    2. start_date of OLD is greater than start_date of NEW
    else return null.
    select id,
    case when max(end_date) keep (dense_rank last order by decode(request_wflow_status,'New',1,0),start_date) is null then
    null
    else
              case when max(decode(status,'OLD',start_date,null)) > max(decode(status,'NEW',start_date,null))
              then max(decode(status,'OLD',start_date,null)) - max(decode(status,'NEW',start_date,null))
    else
    null
    end
    end result
    from cc_request_status where id =1
    group by id;

    Avinash,
    Thank you for your help.. Here is a more description of my problem..
    Here is a sample of data I have for a table with four columns (id,status,start_date,end_date)
    What I need to do is to get difference of the start dates of the maximum available dates, if data is valid. The pseducode is as follows:
    IF end_date of New status is null
    THEN return null
    ELSE
    IF start_date of old >= start_date of new
    THEN return (start_date of old - start_date of new)
    ELSE return null
    I used the following query but always return the bold null
    select id,
    (case when max(end_date) keep (dense_rank last order by decode(status,'new',1,0),start_date) is null then
    null
    else
              (case when max(decode(status,'old',start_date,null)) >=
              max(decode(status,'new',start_date,null))
              then max(decode(status,'old',start_date,null)) - max(decode(status,'new',start_date,null))
    else
    null
    end)
    end) result
    from tbl where id =1
    Based on the below sample, I expected to get the following result; 14-Mar-07 - 16-Feb-07 which is the difference of the maximum start_dates of the two statuses. However the query is not working.. Please help me.. Thank you..
    Id    Status    start_date      end_date
    1     new      03-Feb-07      07-Feb-07
    1     new      16-Feb-07      21-Feb-07
    1     old      '10-Mar-07      12-Mar-07
    1     old      '14-Mar-07      16-Mar-07

  • How to erase my HD and run my imac once again?!

    ok...I have no access to Mac desktop or disk utility with command+R I have no DVD of mac softwere to restore it. I can only acces single user mode only and Fsck -fy doesn't do anything. oh and I have windows bootcamp so one partition is has windows. So....can I do anything to erase everything and start my mac computer from the very beginning??!?!?!

    If your Mac is new enough to have come pre-installed with OS X Lion or Mountain Lion or Mavericks, you should be able to restart into Internet Recovery (Command+Option+R). Hold those keys until you see a spinning globe. You will need an internet connection to do this. This will boot into Apple's servers for Recovery. From there, you should be able to use Disk Utility to repartition your internal drive into one partition and label it Macintosh HD. Then you should be able to reinstall the most current version of the OS X that came pre-installed (e.g. Lion 10.7.5, Mountain Lion 10.8.5, Mavericks 10.9.4).

  • How to get a case structure to execute only once in a loop

    I have a while loop that is monitoring temperature. Once the temperature meets or exceeds a given setpoint I want to start a timer. At this point I don't want to monitor the temperature anymore. That is, if the temperature should drop below the setpoint, I don't want to execute the case structure again when the temperture meets or exceeds the setpoint(the temp may oscillate about the setpoint for a given period of time). In any event, I need the case structure to execute only one time, not every iteration of the loop.

    You can put a local Boolean variable "Flag" inside that case structure and
    set "Flag" to False. Outside the case structure, use an "AND" function
    output to control the case structure. The "AND" function has two inputs. One
    goes to the comparison results between real temp and setpoint. The other
    inputs connects to the "Flag" variable. In this way, once you entered that
    case structure, the "Flag" will be turned to False, and then in next
    iteration, you won't get into the case again because the "AND" function will
    be False as your "Flag" is False now.
    Hope this helps.
    Rentian
    1. Inside the case structure, put a
    "BB Herman" wrote in message
    news:[email protected]..
    >I have a while loop that is monitori
    ng temperature. Once the
    > temperature meets or exceeds a given setpoint I want to start a timer.
    > At this point I don't want to monitor the temperature anymore. That
    > is, if the temperature should drop below the setpoint, I don't want to
    > execute the case structure again when the temperture meets or exceeds
    > the setpoint(the temp may oscillate about the setpoint for a given
    > period of time). In any event, I need the case structure to execute
    > only one time, not every iteration of the loop.

  • MDT 2012 deploy OS from USB external drive failed - need to unplug and plug it once again

    We are using MDT 2012 and deploying Windows 7 using media (USB external hard drive). We can successfully deploy Windows 7 32 bit using this method but there is a problem with deploying Windows 7 64bit. This problem appears only on HP EliteBook 840. We can
    boot into WinPE 64 bit and can start proper task sequence, all image is applied then after restart, before logon screen appears there is an error saying that cannot find litetouch.vbs script. After clicking ok, I can logon to Windows and there is no usb external
    drive recognized. But when I unplug and plug usb drive once again it is recognized by Windows and can be used. I can see that Windows install some drivers just after plug it again
    I checked BIOS looking for some USB power options - there is no such settings. And 32 bit deployment works ok. So this is not a case. Looks for me like a problem with proper usb drivers for 64 bit. I download all drivers from HP website (driver pack and
    drivers only for USB 3.0). We are using make and model matching in MDT - works ok for all the rest hardware models. Any idea how to troubleshoot it?

    Not sure what's going on here. Is this a USB "Flash" drive or a USB "Hard Drive". There *Is* a distinction.
    I *thought* that MDT would copy itself to the c:\minint\scripts folder to continue installation.
    Next time, when you see this error, Press Shift-F10 to get into a cmd.exe prompt. Can you find litetouch.vbs on any of the drives? Does the USB Drive appear?
    IF in fact, the USB Drive is not appearing after the 1st reboot, then you have a problem. Why did the USB 3.0 driver not install. Check the Driver Installation Logs to verify.
    Keith Garner - keithga.wordpress.com

  • In the attached VI I dont understand why data from the inner case structures are not being transmitted to the array.

    In the attached VI I don't understand why data from the inner case structures are not being transmitted to the array.
    Thank you.
    Solved!
    Go to Solution.
    Attachments:
    TEMP.vi ‏25 KB

    It took me some time to figure what you are trying to do but I think I have it now.
    The SR is still required.
    What is happening is your "Bundle By Name" is replacing all of the fields of the cluster, not just the value coming out of the case structure. So to maintain the cluster stuff you do in earlier iterations you can either...
    1) Put the "Index array, Bundle by name, and Replace array" inside the case structure and ONLY bundle the value you are setting in that iteration. (as you will see Tim post shortly)
    OR
    2) Move the Index array before the Case, unbundle all of the fields and feed teh case structure and run them across the case so that ALL of your output tunnels come from the coresponding input tunnel EXCEPT for the filed you are trying to set.
    Ben
    Message Edited by Ben on 05-05-2010 01:31 PM
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

Maybe you are looking for

  • IPod Touch not working with Yamaha YDS-11, since version 3.1.1

    In July 2009, I purchased a Yamaha home theater receiver model HTR-6240 with an iPod Universal dock YDS-11. The iPod Touch worked fine on it until I upgraded the iPod firmware to 3.1.1. When connected, it charges the iPod but the music only comes out

  • ISight green light on, but not working.. PLEASE HELP!!

    HELP PLEASE! My built in iSight green light is on, which means the camera on... but when i try to use it in iMovie, it is a blank white screen and when I try to use photo booth, its a blank green screen. Tried restarting the computer, did not help. S

  • 'S' numbers for the web-site

    I know that this is probably not the place to raise this, but I really dont know where to look for a solution to this. I have a customer who I have requested SAP Portal USer ID's for and they have all been generated 'S' numbers accroding to my reques

  • Need help with this sql query

    the following query returns me the correct no of rows: select col1 from tab1 where col1 like '%'||chr(32)||'%'; but i need to use my query in the following form and it doesn't return any row: select col1 from tab1 where col1 IN ('%'||chr(32)||'%'); w

  • Setting up Mircrosoft Server 2012

    Hellow friends......i need some suggestions from you for setting up a network. our company is supplying and repairing of Locomotives. our head office is in one city and two repairing center in other cities and we have warehouse as well. Problems: the