SIT Real-time data logging and passing data

Hello all,
I am pretty new to LabView real-time, so I just want to confirm a few things. I am also using the Simulation Interface Toolkit.
Let's take the Sinewave.vi from the SIT examples. I have modified it to use sinewave.dll, and run on PXI-8101. If my understanding is correct, when I click "Play", the entire Sinewave.vi is deloyed into PXI-8101, and therefore the entire VI is running at the same pace. The front panel I see on my desktop is slower snapshots of what is actually happening?
1) Let's pretend now that the sinewave model is time critical and must run every 10ms. How do I do that? I have noticed that within the "SIT_Indicator_Indices" loop, there is a Wait 50ms block. Is that accurate?
2) I have also added a time elapsed block that will change the Frequency and Amplitude inputs as a function of time. I made them update every 2ms. What clock are we running on? If my sinewave.mdl suddenly calculate integration (time dependent), can I use that elapsed time block as my timer to pass into the model?
3) How fast is the sinewave.vi running anyways?
4) Let's say I want a log of the sinewave output (a data point every 10ms). I don't need the log in real-time, I just want to do some analysis on it later. How do I do it?
Thanks.
Attachments:
Sine Wave.vi ‏104 KB

Hi Bladhart,
When running the in the Development Environment (pressing the run button on the Real-Time vi) there will be an extra thread to handle the front panel you see. This thread will be handled just like any other thread in Real-Time and will take processor time, thus slowing down your entire application to a certain extent.  
1. You would need to make sure everthing inside the loop can execute within 10ms and change the wait time to 10ms. Or you can use a timed loop set to run every 10ms and get rid of the wait time but again you would need to ensure everything in the loop can execute in under 10ms.
2. The elapsed time should be running off the Real-Time system clock. 
3. The time that the Sinewave.vi is running is system dependent, there is no set speed.
4. You can log the data by saving to a *.tdms file. You can then use the data from the *.tdms file to do processing later. 
<Brian A | Applications Engineering | National Instruments> 

Similar Messages

  • How toStore the Date Variable and pass it when the program runs next time??

    HI All,
    My JDBC program basically needs two command line args. Rabge_Start_Dt and Range_End_Dt. for ex:
    2001-05-31 and 2001-06-01 . And my porgram should run every day. Next day the date range will be 2001-06-01 to some date. It means I have to store some how the range_end_dt and pass it as range_start_dt when my program runs the next day.
    Problem:
    How can I store the Data variable and pass it as an argument to my porgram when It runs next time. Every time my pogram runs It should pick the range start_dt (==range_end_dt of the previuos run) and end_dt I have to go and query some other data base and pass that value to it.
    Thanks in advance!!!!

    save the value in a file, then read it back in each day. Similar to when a process needs a PID.
    -blhqctz

  • How can I generate a real-time highchart from my database data?

    I have looked several links; however, I couldn't find a working demo showing how to implement a highchart using data from a database.
    Objective: I want to generate a real time highchart line graph getting data from my database. What I want is very similar to the
    HighChart Demo which provides a real-time highchart with randomly generated values. It is also similar by X-axis and Y-axis, for I want my x-axis to be "Time" (I have a DateTime column in my database) and y-axis to be an integer (I have
    a variable for that as well in my database).
    Please I need help in sending the model data to my razor view.
    Note that I am already using SignalR to display a realtime table. I also want to know if it can be used to automatically update the highchart as well.
    Below is the code snippet of my script in the view. I have used the code provided in
    HighChart Demo link for generating the highchart. Please tell me where should I apply the changes on my code.
    @section Scripts{
    <script src="~/Scripts/jquery.signalR-2.2.0.js"></script>
    <!--Reference the autogenerated SignalR hub script. -->
    <script src="~/SignalR/Hubs"></script>
    <script type="text/javascript">
    $(document).ready(function () {
    // Declare a proxy to reference the hub.
    var notifications = $.connection.dataHub;
    //debugger;
    // Create a function that the hub can call to broadcast messages.
    notifications.client.updateMessages = function () {
    getAllMessages()
    // Start the connection.
    $.connection.hub.start().done(function () {
    alert("connection started")
    getAllMessages();
    }).fail(function (e) {
    alert(e);
    //Highchart
    Highcharts.setOptions({
    global: {
    useUTC: false
    //Fill chart
    $('#container').highcharts({
    chart: {
    type: 'spline',
    animation: Highcharts.svg, // don't animate in old IE
    marginRight: 10,
    events: {
    load: function () {
    // set up the updating of the chart each second
    var series = this.series[0];
    setInterval(function () {
    var x = (new Date()).getTime(), // current time
    y = Math.random();
    series.addPoint([x, y], true, true);
    }, 1000);//300000
    title: {
    text: 'Live random data'
    xAxis: {
    type: 'datetime',
    tickPixelInterval: 150
    yAxis: {
    title: {
    text: 'Value'
    plotLines: [{
    value: 0,
    width: 1,
    color: '#808080'
    tooltip: {
    formatter: function () {
    return '<b>' + this.series.name + '</b><br/>' +
    Highcharts.dateFormat('%Y-%m-%d %H:%M:%S', this.x) + '<br/>' +
    Highcharts.numberFormat(this.y, 2);
    legend: {
    enabled: false
    exporting: {
    enabled: false
    series: [{
    name: 'Random data',
    data: (function () {
    // generate an array of random data
    var data = [],
    time = (new Date()).getTime(),
    i;
    for (i = -19; i <= 0; i += 1) {
    data.push({
    x: time + i * 1000,
    y: Math.random()
    return data;
    function getAllMessages() {
    var tbl = $('#messagesTable');
    var data = @Html.Raw(JsonConvert.SerializeObject(this.Model))
    $.ajax({
    url: '/nurse/GetMessages',
    data: {
    id: data.id,
    contentType: 'application/html ; charset:utf-8',
    type: 'GET',
    dataType: 'html'
    }).success(function (result) {
    tbl.empty().append(result);
    $("#g_table").dataTable();
    }).error(function (e) {
    alert(e);
    </script>

    Hi Sihem,
    Thank you for contacting National Instruments.  Using the LabVIEW Real-Time module, you can do development without actually having a target.  While viewing the project explorer window, you can do the following steps:
    Right click on the project
    Select New >> Targets and Devices
    Select the "New Target or Device" radio button
    Select the target you would like to develop on.Information about the LabVIEW Real-Time Module can be found here.
    Regards,
    Kevin H
    National Instruments
    WSN/Wireless DAQ Product Support Engineer

  • Scheduling a report in background and passing data for processing

    Hi all,
    Using code (in a report1) ...i  want to execute a report (report2) in background.....but at the same time i want to pass data (an internal table and a variable) to that report2.
    is it possible to pass data like internal table to a executable report and at the same time pass the data to that report.
    Thanks in advance.
    Thanks and Regards,
    Sushil.

    hi
    regarding  Scheduling a report in background check the below thread
    SCHEDULE THE ZREPORT IN BACKGROUND DYNAMICALLY
    regards
    chandra

  • Query from the data abse  and pass values to a pdf form

    query from the data abse and pass values to a pdf form
    Hello
    Hello i have this html report that i have written to output a
    report.
    now, i am assigned to pass the same fields to a pdf form so
    the fields in the adaobe form can be populated or the term
    Pre-populate the form.
    can anyone help me get started.
    first i would like to know if it can be done.
    second, what do i need to get started (tools )
    third how do i do this.
    i am really lost at this point.
    can anyone give me tips in how to approach this
    subject??

    It can be one using Adobe Acrobat Designer which is packaged
    with Acrobat
    Professional Pro 7. It uses all XML to create and populate
    forms.
    If you had the time, you can also create <cfdocument
    type="pdf"> to have
    them ready and just pass the info to it so it autogenerates
    the PDF on the
    fly.

  • Help In keithley 2400 VI!!(Problem with the data logging and graph plotting)

    Hi,need help badly=(.
    My program works fine when i run it,and tested it out with a simple diode.The expected start current steps up nicely to the stop current.The only problem is when it ends,i cannot get the data log and the graph,though i already have write code for it.Can someone help me see what's wrong with the code?I've attached the necessary file below,and i'm working with Labview 7.1.
    Thanks in advance!!!
    Attachments:
    24xx Swp-I Meas-V gpib.llb ‏687 KB

    Good morning,
    Without the instrument it might be hard for others to help
    troubleshoot the problem.  Was there a
    specific LabVIEW programming question you had, are you having problems with the
    instrument communication, are there errors? 
    I’d like to help, but could you provide some more specific information
    on what problems you are encountering, and maybe accompany that with a simple
    example which demonstrates the behavior? 
    In general we don’t we will be unable to open specific code and debug,
    but I’d be happy to help with specific questions. 
    I did notice, though, that in your logging VI you have at
    least one section of code which appears to not do anything.  It could be that a small section of code, or
    a wire was removed and the data is not being updated correctly (see pic below).  Is your file being opened properly?  Is the data being passed to the file
    properly?  What are some of the things
    you have examined so far?
    Sorry I could not provide the ‘fix’, but I’m confident that
    we can help.  Thanks for posting, and
    have a great day-
    Message Edited by Travis M. on 07-11-2006 08:51 AM
    Travis M
    LabVIEW R&D
    National Instruments
    Attachments:
    untitled.JPG ‏88 KB

  • How to call routine and pass data to routine in vofm

    Hi Experts,
    I need to update KBETR and KWERT values present in 'Conditions Tab' in Purchase Order (ME21N/ME22N).
    I have created a new customer tab in which we enter amount field and  percentage filed. When user enters some value in this and clicks on 'Conditions Tab', calculation has to be done and the calculated value has to be appeared across a specific condition type.as i am new to abap  i dont know how to create routine and pass data to routine in vofm from customised tab in me21n .
                                                                                                                                                                          Thank's in advance

    Hello Rajendra,
    You can get plenty of forums in SCN related to it. Follow below steps to create VOFM routine.
    Go to VOFM Transaction Code
    1. On the Menu Select required Application i.e Pricing
    2. Enter any Number in between 600 to 999 for Custom Developments.
    3. On entering Pop Screen appears ask for Access Key(We have to remember that Every New Routine needs an Access Key)
    4. Once the Access Key is received we can do modification.
    5. Enter the Routine Number ,description and insert the Access Key
    6. Now the ABAP Editor will open and required code can be copied from Standard SAP Routine and Custom Code Can be developed.
    7. Once the coding is completed we have to Activate the Routine
    8. Select the Routine and Go to Edit – Activate
    9. Ensure that Active check box is ticked upon Activation of the Routine.
    10. Double click on the routine will enter into ABAP Editor, we have to generate the Routine
    11. Go to Program and select Generate
    12.A screen pops up with the related Main Programs  and select all required main programs wherever the Routine is being called.
    13. Once the Routine is Generated and Activated, We need to configure the Routine in the config.
    ** Important SAP note: 156230.
    Check the below document too.
    http://www.scribd.com/doc/35056841/How-to-create-Requirement-Routines
    Regards,
    Thanga

  • What is open data set and close data set

    what is open data set and close data set,
    how to use the files in sap directories ?

    hi,
    Open Dataset is used to read or write on to application server ... other than that i am not sure that there exists any way to do the same ... here is a short description for that
    FILE HANDLING IN SAP
    Introduction
    • Files on application server are sequential files.
    • Files on presentation server / workstation are local files.
    • A sequential file is also called a dataset.
    Handling of Sequential file
    Three steps are involved in sequential file handling
    • OPEN
    • PROCESS
    • CLOSE
    Here processing of file can be READING a file or WRITING on to a file.
    OPEN FILE
    Before data can be processed, a file needs to be opened.
    After processing file is closed.
    Syntax:
    OPEN DATASET <file name> FOR {OUTPUT/INPUT/APPENDING}
    IN {TEXT/BINARY} MODE
    This statement returns SY_SUBRC as 0 for successful opening of file or 8, if unsuccessful.
    OUTPUT: Opens the file for writing. If the dataset already exists, this will place the cursor at the start of the dataset, the old contents get deleted at the end of the program or when the CLOSE DATASET is encountered.
    INPUT: Opens a file for READ and places the cursor at the beginning of the file.
    FOR APPENDING: Opens the file for writing and places the cursor at the end of file. If the file does not exist, it is generated.
    BINARY MODE: The READ or TRANSFER will be character wise. Each time ‘n’’ characters are READ or transferred. The next READ or TRANSFER will start from the next character position and not on the next line.
    IN TEXT MODE: The READ or TRANSFER will start at the beginning of a new line each time. If for READ, the destination is shorter than the source, it gets truncated. If destination is longer, then it is padded with spaces.
    Defaults: If nothing is mentioned, then defaults are FOR INPUT and in BINARY MODE.
    PROCESS FILE:
    Processing a file involves READing the file or Writing on to file TRANSFER.
    TRANSFER Statement
    Syntax:
    TRANSFER <field> TO <file name>.
    <Field> can also be a field string / work area / DDIC structure.
    Each transfer statement writes a statement to the dataset. In binary mode, it writes the length of the field to the dataset. In text mode, it writes one line to the dataset.
    If the file is not already open, TRANSFER tries to OPEN file FOR OUTPUT (IN BINARY MODE) or using the last OPEN DATASET statement for this file.
    IF FILE HANDLING, TRANSFER IS THE ONLY STATEMENT WHICH DOES NOT RETURN SY-SUBRC
    READ Statement
    Syntax:
    READ DATASET <file name> INTO <field>.
    <Field> can also be a field string / work area / DDIC structure.
    Each READ will get one record from the dataset. In binary mode it reads the length of the field and in text mode it reads each line.
    CLOSE FILE:
    The program will close all sequential files, which are open at the end of the program. However, it is a good programming practice to explicitly close all the datasets that were opened.
    Syntax:
    CLOSE DATASET <file name>.
    SY-SUBRC will be set to 0 or 8 depending on whether the CLOSE is successful or not.
    DELETE FILE:
    A dataset can be deleted.
    Syntax:
    DELETE DATASET <file name>.
    SY-SUBRC will be set to 0 or 8 depending on whether the DELETE is successful or not.
    Pseudo logic for processing the sequential files:
    For reading:
    Open dataset for input in a particular mode.
    Start DO loop.
    Read dataset into a field.
    If READ is not successful.
    Exit the loop.
    Endif.
    Do relevant processing for that record.
    End the do loop.
    Close the dataset.
    For writing:
    Open dataset for output / Appending in a particular mode.
    Populate the field that is to be transferred.
    TRANSFER the filed to a dataset.
    Close the dataset.
    Regards
    Anver
    if hlped pls mark points

  • Download using open data set and close data set

    can any body please send some sample pgm using open data set and close data set .the data should get downloaded in application server
    very simple pgm needed

    Hi Arun,
    See the Sample code for BDC using OPEN DATASET.
    report ZSDBDCP_PRICING no standard page heading
    line-size 255.
    include zbdcrecx1.
    *--Internal Table To hold condition records data from flat file.
    Data: begin of it_pricing occurs 0,
    key(4),
    f1(4),
    f2(4),
    f3(2),
    f4(18),
    f5(16),
    end of it_pricing.
    *--Internal Table To hold condition records header .
    data : begin of it_header occurs 0,
    key(4),
    f1(4),
    f2(4),
    f3(2),
    end of it_header.
    *--Internal Table To hold condition records details .
    data : begin of it_details occurs 0,
    key(4),
    f4(18),
    f5(16),
    end of it_details.
    data : v_sno(2),
    v_rows type i,
    v_fname(40).
    start-of-selection.
    refresh : it_pricing,it_header,it_details.
    clear : it_pricing,it_header,it_details.
    CALL FUNCTION 'UPLOAD'
    EXPORTING
    FILENAME = 'C:\WINDOWS\Desktop\pricing.txt'
    FILETYPE = 'DAT'
    TABLES
    DATA_TAB = it_pricing
    EXCEPTIONS
    CONVERSION_ERROR = 1
    INVALID_TABLE_WIDTH = 2
    INVALID_TYPE = 3
    NO_BATCH = 4
    UNKNOWN_ERROR = 5
    GUI_REFUSE_FILETRANSFER = 6
    OTHERS = 7.
    WRITE : / 'Condition Records ', P_FNAME, ' on ', SY-DATUM.
    OPEN DATASET P_FNAME FOR INPUT IN TEXT MODE.
    if sy-subrc ne 0.
    write : / 'File could not be uploaded.. Check file name.'.
    stop.
    endif.
    CLEAR : it_pricing[], it_pricing.
    DO.
    READ DATASET P_FNAME INTO V_STR.
    IF SY-SUBRC NE 0.
    EXIT.
    ENDIF.
    write v_str.
    translate v_str using '#/'.
    SPLIT V_STR AT ',' INTO it_pricing-key
    it_pricing-F1 it_pricing-F2 it_pricing-F3
    it_pricing-F4 it_pricing-F5 .
    APPEND it_pricing.
    CLEAR it_pricing.
    ENDDO.
    IF it_pricing[] IS INITIAL.
    WRITE : / 'No data found to upload'.
    STOP.
    ENDIF.
    loop at it_pricing.
    At new key.
    read table it_pricing index sy-tabix.
    move-corresponding it_pricing to it_header.
    append it_header.
    clear it_header.
    endat.
    move-corresponding it_pricing to it_details.
    append it_details.
    clear it_details.
    endloop.
    perform open_group.
    v_rows = sy-srows - 8.
    loop at it_header.
    perform bdc_dynpro using 'SAPMV13A' '0100'.
    perform bdc_field using 'BDC_CURSOR'
    'RV13A-KSCHL'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'RV13A-KSCHL'
    it_header-f1.
    perform bdc_dynpro using 'SAPMV13A' '1004'.
    perform bdc_field using 'BDC_CURSOR'
    'KONP-KBETR(01)'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    perform bdc_field using 'KOMG-VKORG'
    it_header-f2.
    perform bdc_field using 'KOMG-VTWEG'
    it_header-f3.
    **Table Control
    v_sno = 0.
    loop at it_details where key eq it_header-key.
    v_sno = v_sno + 1.
    clear v_fname.
    CONCATENATE 'KOMG-MATNR(' V_SNO ')' INTO V_FNAME.
    perform bdc_field using v_fname
    it_details-f4.
    clear v_fname.
    CONCATENATE 'KONP-KBETR(' V_SNO ')' INTO V_FNAME.
    perform bdc_field using v_fname
    it_details-f5.
    if v_sno eq v_rows.
    v_sno = 0.
    perform bdc_dynpro using 'SAPMV13A' '1004'.
    perform bdc_field using 'BDC_OKCODE'
    '=P+'.
    perform bdc_dynpro using 'SAPMV13A' '1004'.
    perform bdc_field using 'BDC_OKCODE'
    '/00'.
    endif.
    endloop.
    *--Save
    perform bdc_dynpro using 'SAPMV13A' '1004'.
    perform bdc_field using 'BDC_OKCODE'
    '=SICH'.
    perform bdc_transaction using 'VK11'.
    endloop.
    perform close_group.
    Hope this resolves your query.
    Reward all the helpful answers.
    Regards

  • What is data archiving and DMS(Data Management System) in SAP

    what is data archiving and DMS(Data Management System) in SAP
    Welcome to SCN. Before posting questions please search for available information here and in the web. Please also read the Rules of Engagement before further posting.
    Edited by: kishan P on Aug 31, 2010 1:06 PM

    Hi,
    Filtering at the IDoc Level
    Identify the filter object (BD59)
    Modify the distribution model
    Segment Filtering
    specify the segments to be filtered (BD56)
    The Reduced IDoc Type
    Analyze the data.
    Reduce the IDoc type (BD53)
    Thanks and regards.

  • Real-Time Sequencer Feedback and Questions

    Post your questions and feedback to the Real-Time Sequencer Architecture and Real-Time Sequencer Architecture Example here.
    Brian K.

    I just purchased the USB 6341 DAQ card. I am using Dev1/.Port1 to control 4 driver transistors. The transistors fire 4 SSR. I am trying to create a sequence for the 4 transistors. Sometimes a test unit that is driven by a SSR will fail. So I have to change the sequence for the failed DUT.
    Basically each SSR will be ON for 6 seconds. There will be a delay of about 5.75 seconds for the next valve to fire. The delay is used to balance the pressure testing. The second valve will need to start at 5.75 seconds later. Basically the two valves must cross at the 50 % turn OFF. How can I perform this task. There are at least 7 different test sequences??
    Thanks,
    Philip 

  • How to make a Infocube as data source and upload data? urgent

    Hi all,
    I have 2 same InfoCubes, and I want to make the test InfoCube(ZCO_1T) as data source and upload data to another Cube(ZCO_1), Now I has Generated Export DataSource on ZCO_1T and create a update rule between ZCO_1T and ZCO_1. what will I do the next step? Thanks.

    hi delve,
    once u generate datasource from test cube it acts as an data source for further upload.
    now u choose update target3.x in additional functions in context menu of the test cube.
    u will get an infopackage pop up with data target to the cube ZCO_1,processing to datatarget only.
    selection criterion can bve selected from the first tab.
    under schedule tab you can start extraction.
    reward points if helpful.

  • Is vision development module in labview 8.6. sufficient for real-time image acquisition and analysis using a webcam

    Hi, 
    I'm new to labview and trying to develop an eye-tracker using labview 8.6. It has the vision development module and i was wondering if this was sufficient for real-time image acquisition and processing or would i be needing any other software tools.
    Solved!
    Go to Solution.

    Hello, certainly it is possible and sufficient for real-time tracking!
    About eye tracking - if you need an example, you can find the code here:
    https://decibel.ni.com/content/blogs/kl3m3n/2013/10/08/real-time-face-and-eye-detection-in-labview-u...
    The code uses OpenCV functionalities along with the LabView UI (and some other functions like overlay).
    Hope this helps a bit.
    Best regards,
    K
    https://decibel.ni.com/content/blogs/kl3m3n
    "Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."

  • Master data tables and Transaction data Tables

    Hello Gurus,
    Please let me know how to know which table belongs to master data  and which table belongs to transaction data.
    for FICO module.
    Does any one  have specific material relating to master data table and transaction data tables.
    Thanks
    Edited by: Manu Rathore on Jan 18, 2012 4:38 AM

    Hi Manu,
    Find attached table relation diagram by Christopher Solomon. It is one of the very comprehensive chart on this topic.
    deleted
    Warm regards,
    Murukan Arunachalam

  • I want to be able to tweak the graphic equalizer in real time while recording - and have this have the audible effect written to the recording.   At the moment i have to go into post-production and manually set the graph equalizer at various time points .

    i want to be able to tweak the graphic equalizer in real time while recording - and have this have the audible effect written to the recording.
    At the moment i have to go into post-production and manually set the graph equalizer at various time points ...

    This won't be real-time as you record, but you could tweak the EQ in real-time after the recording thus:
    Record what you want to tweak into GB with no effects.
    Solo the track and output it into something like Audacity.
    Start Audacity recording, then play your track in GB as you make those tweaks. That's what Audacity will record.
    Get that file from Audacity and put it into GB, then you'll have that effect.
    Sorry if it's complicated, but that's what came to mind. Hope it works.

Maybe you are looking for

  • FM to get purchasing price based on certain condition

    Hi, Is there any function module to get Price in purchasing document like PO after certain price condition like freight, discount etc. For example I have a material no, price per unit 50 USD and we'd like to buy 10 pieces of it, we have price conditi

  • Warehouse RF and 2 step picking

    Hi Guys, I have set up wm mobile in ecc 6.0 and also have 2 step TO's working manually but can't get them to work with a scanner. I have one storage type one side of the road and one the other but they all form part of the same warehouse in SAP. They

  • Sun Java ME 3.0 windows installer corrupted

    Hello there, I am not sure if I am posting this issue into the right forum...if not and if someone is aware of the right contact, please provide. I am quite new to the J2ME world and at this moment I am mainly concentrating on learning J2ME for mobil

  • After the latest update the app can't be opened.

    Updated iBook to the latest version but it cracked after the book covers are just displayed. Tried several times and turned the iPad off/on several times, but still it does not work. Who has the idea how to fix this or Apple is going to do this?

  • OVI Suite 3.0 problem recognizing Nokia device

    Workaround for this: 1. Disconnect your phone from PC if connected. 2 .Open Control Panel and go to 'Programs and Features'for windows7 and "Add/remove program" for Windows XP 3. From the list of available programs, choose 'Nokia Connectivity Cable D