Topics in CVI

I wander why there are no topics in CVI forum and why it's not possible for us to suggest some as in LV forum.
Two examples of interesting topics (personal opinion) could be:
- I saw the question posted by Markus Kossman and answered by Chris Matthews about serial communication: the differences in serial comms between various OSs are of relevant interest to many people, and it will be interesting to share ideas beyond the simple question/answer level.
- How many activex controls are we using in our applications? Which difficulties have we found in using them?
Proud to use LW/CVI from 3.1 on.
My contributions to the Developer Zone Community
If I have helped you, why not giving me a kudos?

Hi Roberto,
Thank you for expressing your interest in adding topics to the CVI forum. The details you have provided will make it quite easy to add these topics. Look for them soon!
regards,
Eric Meyer
National Instruments

Similar Messages

  • How to create distributed .exe of any CVI project

    How to create distributed .exe of any CVI project that we can execute in any system which doesn't have CVI installed

    To have a CVI excutable running on a target system you must install the apropriate support libraries and modules on it: CVI integrates the ability to create proper installers that create the correct executing environment on the target machines. These functions are included in Build >> Distributions menu item: select "Manage distributions" and look into the detailed online help.
    An overview on creating a distribution can be found in Using LabWindows/CVI >> Managing projects >>Building a project >> Distributing applications topic in the online help as well as in several forum threads and other documents on NI site: as an example, this one covers this topic for CVI 8.x
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • I would like to know how to transform an API C++ application in MFC C++ application to use the measurement studio components or Labwindows CVI

    I don t know the way used to transform a C++ with API program in an MFC application using measurement studio or Labwindows CVI.
    Thank you for you help.

    You can use the Measurement Studio Add/Remove Components Wizard to add Measurement Studio components to your C++ application. For more information, see the "Adding and Removing Components from Measurement Studio Projects Using a Wizard" topic in the Measurement Studio reference. You can find it in the table of contents under:
    Visual C++ Help
    Tutorials
    Measurement Studio for Visual C++ 6.0
    If you're using the Measurement Studio update for Visual C++ .NET, this topic will be under:
    Visual C++ Help
    Tutorials
    Measurement Studio for Visual C++ .NET
    - Elton

  • Calling a Visual C++ dll from CVI

    I created a dll in visual C++, try to access it using .Net library APIs of CVI.
    I am able to create the object of the class “Class1” correctly, but when I try to invoke a function of the class, I got error  -6587(inaccessible error).
    I attached my code, dll code for your reference.
    Attachments:
    Maxnumeber.zip ‏3 KB
    test1.zip ‏820 KB

    Can you provide a screen shot of the error you are receiving? Have you marked the functions you are trying to call with extern C to specify that they are going to be used with the C compiler? Please see the followling link which discusses this topic.
    http://www.ni.com/white-paper/3341/en#toc9
    Regards,
    Anjelica W.
    National Instruments
    Applications Engineer

  • How to use a 64-bit Matlab ActiveX in a 32-bit CVI?

    I have a CVI 9.0 and 64-bit MatLab R2012a installed on my PC together with 64-bit Windows 7.When I try to use "Create ActiveX Controller" wizard to use the Matlab ActiveX,a message went out says"The Type Library is not intended for use on Win32".Seems like it's because my CVI is 32-bit but my Matlab is 64-bit.So I wonder is there any way for me to use the MatLab ActiveX Controller?
    PS.I have been checked on this topic:http://forums.ni.com/t5/LabWindows-CVI/How-to-create-ActiveX-Control-in-LabWindows-CVI-2010/td-p/183...
    But it's not workong for me due to different CVI version.
    Thank you guys.

    Thank you for your reply.
    Does this means that it is still not possible to use the PDF ActiveX control in a x64 WinForms application?

  • In CVI !!!! How to dynamic change BaudRate of RS232 Serial COM Without closing the Port !!!

    Dear all:
    I want to change the buadrate of serial com without closing the serial com, but it failed when I use the function "SetCommConfig(m_hCom, &Com_cfg, Com_cfg_S) " to reset the buadrate ,baudrate is no change when use GetCommConfig to read back the value. 
    Appreciated all of your advice . TKS!
    Code with WINAPI as beloow:
    CreateFile(..) ;
    GetCommState(..);
    dcb.BaudRate= 1000000 ;
    SetCommState(..);
    //......do other things
    //change baudrate to normal without closing port .
    GetCommConfig(m_hCom, &Com_cfg, &Com_cfg_S);
    Com_cfg.wVersion = 0X100;
    Com_cfg.dwProviderSubType = 1;
    Com_cfg.dcb.BaudRate =9600  ;
    Com_cfg.dcb.StopBits =1 ;
    SetCommConfig(m_hCom, &Com_cfg, Com_cfg_S);
    GetCommConfig(m_hCom, &Com_cfg, &Com_cfg_S);   
    Solved!
    Go to Solution.

    This topic has been discussed some years ago: see here. Please note that even if I made that sample program which changes the baud rate without closing the port, I never used it in a real situation: you'll need to made your tests and check if this solution can satisfy your needs in the short and long term.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • How to create an array Station Globals programmatically in CVI?

    Hello all,
    I want to create an array Station Globals programmatically in CVI. Where can I find some examples?
    Thanks,
    Zhonghui Ning

    Zhonghui,
    There is a KnowledgeBase on our website that describes the methods needed to do this. You can find the KnowledgeBase at http://digital.ni.com/public.nsf/websearch/C7C81F4AE5A46BB686256CDA005FA4C6?OpenDocument.
    I found this by searching for "teststand create variable". You can find TestStand examples on our Developer Library by going to http://www.ni.com/devzone and clicking on the link for Developer Library. This page has example code as well as tutorials and application notes on many aspects of TestStand. There are quite a few examples there that already address this type of question: Creating Sequence File Global Variables Using the TestStand API with LabWindows/CVI
    and Creating and Inserting a New Data Type into a Sequence File using LabWindows/CVI
    We continually add examples to these web pages, so it is always a good place to look for examples. While they may not have the exact answer to your questions, the examples usually cover a topic that is close enough for you to be able to apply the example to your question.
    Hope that helps.
    Regards,
    Shannon R.
    Applications Engineer
    National Instruments

  • CVI IDE: Is it possible to see list of functions for faster navigation?

    Colleagues,
    Very simple question about CVI IDE.
    Is it possible to see whole list of functions for fast and convenient navigation, like in Micro$oft Visual Studio:
    When I have C code with more than 20-30 functions and 2000+ lines - its a very inconvenient to scroll up and down every time...
    I guess this feature should present in CVI, or I missing something? 
    How you working with relative large projects in CVI? 
    Thank you in advance,
    Andrey.

    CVI offers the Source Code Browser, which shows informations about files, functions, variables, data types and macros in your code. The code browser can be accessed in several ways: the easiest is to position over an element in the code and press Ctrl+F1: the lower part of the workbench will host the Source Code Browser area (though you can lately release this window to position it wherever you find it useful). There are several other ways to access these informations: I suggest you to look in the online help, topic Using LabWindows/CVI >> Writing Source Code >> Browsing Source Code
    CVI has several other ways of navigating in your application:
    Select a panel, menu or control callback and press Ctrl+Shift+U to go to the object in the UIR editor
    Right-click on an element in the UIR editor to go to its callback (if any)
    Select a function call in the code editor and press Ctrl+I to go to the function source
    Select a filename and press Ctrl+U to open it in an editor window
    ... and others I don't remember now! 
    Message Edited by Roberto Bozzolo on 05-07-2010 10:12 AM
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Using Matlab in Labwindows/CVI

    I have a matlab .m file that runs a function. In my Labwindows software, I want to be able to run this function. Is this possible? Thanks.

    Hi Kamkon,
    Have you had a chance to look into the example posted by Anna? I've come across discussion forums regarding how to use MATLAB dlls in LabWindows CVI. They are listed below. I hope this is of some help to you.
    http://forums.ni.com/t5/LabWindows-CVI/How-to-use-a-Matlab-DLL-in-CVI/m-p/548105?requireLogin=False
    http://forums.ni.com/t5/LabWindows-CVI/Linking-Matlab-generated-lib-files/m-p/283814?requireLogin=Fa...
    Creating a MATLAB dll is somewhat outside the scope of our suppot. However, I have found a third party link on this topic. Hopefully, it will point you in the right direction.
    http://www.mathworks.com/support/solutions/en/data/1-18CBI/index.html?solution=1-18CBI
    Regards.
    Josh L.
    Applications Engineer
    National Instruments

  • CVI Distibution with Database Functions

    I am working with CVI2012.  I have an application that uses the SQL toolkit.  I made a distribution and installed it on a target machine (Windows 7 with the CVI2012 runtime engine).  However when I install the application on another target (also a Windows 7 machine and also with the CVI2012 runtime engine) I cannot not initialize the database.  The application fails on a call to DBInit(DB_INIT_MULTITHREADED).  I get an error of -100: DB_FAILED_TO_LOAD_DLL.   (I am using  SQL Anywhere 11.)  I know that the ODBC configuration is the same on both targets and I can access the DB manually through Interactive SQL.     
    I am baffled by this.  After some searching I found that the file "cvidb32.dll" was not in the system32 directory so I copied that over.  Still no joy.  (I would also expect this to be installed when I installed the RTE.  I did not have to manually copy this file on to the computer where the application does work.)  I have checked the forums here have not found a solutionl.  One post discussed running sqldistsupp.exe after the installer.  I tried this and got an error "Driver's ConfigDSN, ConfigDriver or ConfigTranslator failed in function SQLConfigDataSource".  Another post suggested simply adding CVISQLShared.msm to the installer.  I tried this but it did not fixt the problem.  I also tried downloading the SQL Distribution Toolkit help and it turns out the file has no content under the help topics.
    Clearly something is missing but I don't know what.  I tried running Dependency Walker to find the missing DLL but it did not show anything was missing. 
    Thoughts?
    Thanks.

    I have not distributed any applications with sql functionality, but looking at the following links it seems it can be a little tricky:
    Why Do I Get Errors When I Try to Run a Distribution of a LabWindows™/CVI™ Program Which Uses the SQ...
    LabWindows™/CVI SQL Toolkit 2.2 Readme
    S. Eren BALCI
    www.aselsan.com.tr

  • Timer( ) resolution in CVI 2009 SP1

    In the CVI 2009 SP1 Contents Help for Timer() function I find
    The resolution is normally 1 microsecond. However, if you set the useDefaultTimer configuration option to True, the resolution is 55 milliseconds.
    But if you click on the useDefaultTimer hyperlink, a new page is opened, where you can read that the resolution is 1 millisecond if you set useDefaultTimer to False.
    Which is the right resolution?
    I wrote my application considering 1 microsecond, but I found strange problems, and I think it is 1 ms.
    Vix
    In claris non fit interpretatio
    Using LV 2013 SP1 on Win 7 64bit
    Using LV 8.2.1 on WinXP SP3
    Using CVI 2012 SP1 on Win 7 64bit, WinXP and WinXP Embedded
    Using CVI 6.0 on Win2k, WinXP and WinXP Embedded

    Hi vix,
    Thanks for bringing those documentation problems to our attention.
    1. There does seem to be a problem with a lot of the function prototypes in the .chm help in the CVI 2009 SP1 and 2010 versions, where an extra asterisk seems to have been added to a number of output parameters. We'll fix this and post a corrected version of the affected .chm files as soon as possible. In all these cases, the parameter data type as it appears in the Parameters section of the help topic is correct, as is the prototype in the corresponding function panel.
    2. Concerning the timer resolution issues, the async timer resolution is in fact 1 millisecond, as confirmed by the GetAsyncTimerResolution function. But note that asynchronous timers are a library in and of themselves, and are not covered by what is discussed in the documentation of the Timer() function or the useDefaultTimer option.
    The resolution of the Timer() function should be 1 microsecond, as of CVI 9.0 and later. The function documentation is correct. When that change was made, however, the documentation of the useDefaultTimer option was incorrectly not updated. It should say that "the performance counter timer provides a resolution of 1 microsecond".
    You mentioned that you didn't think that the resolution of the Timer() function was 1 microsecond. If you run the following code, what do you see?
    int     i;
    double  time[10];
    for (i = 0; i < 10; i++)
        time[i] = Timer();
    for (i = 0; i < 10; i++)
        DebugPrintf ("timer = %f\n", time[i]);

  • How to execute a sequence from cvi code ?

    Hello ,
    I'm programing a test software using Labwindows CVI 9.0 and TestStand 4.2 .
    I'm Using CVI GUI and i want for example to press a button that will lanuch a squence from Teststand .
    the SEQ file is already open because i'm launching the GUI from Teststand .
    How can i execute a seq from CVI ?
    Thank you for your help.... Kobi
    Kobi Kalif
    Software Engineer

    Refer to the Example User Interfaces section in Chapter 9, Creating Custom User Interfaces, of the TestStand Reference Manual (p. 9-1):
    Example User Interfaces
    The <TestStand>\UserInterfaces directory includes the executable, project, and source code files for each example user interface. The Full-Featured subdirectory contains user interfaces for loading, viewing, editing, saving, executing, and debugging sequence files. The Simple subdirectory contains similar but limited user interfaces with fewer commands and options but no menus. Also, the simple example user interfaces display the steps for executions you run but do not display steps for sequences you load. Both subdirectories contain source code for LabVIEW, LabWindows/CVI, Microsoft Visual Basic .NET, C#, and C++ (MFC).TestStand installs the source code files for the default user interfaces in the <TestStand>\UserInterfaces and <TestStand Public>\UserInterfaces directories. To modify the installed user interfaces or to create new user interfaces, modify the files in the <TestStand Public>\UserInterfaces directory. You can use the read-only source files for the default user interfaces in the <TestStand>\ UserInterfaces directory as a reference. When you modify installed files, rename the files after you modify them if you want to create a separate custom component. You do not have to rename the files after you modify them if you only want to modify the behavior of an existing component. If you do not rename the files and you use the files in a future version of TestStand, changes National Instruments makes to the component might not be compatible with the modified version of the component. Storing new and customized files in the <TestStand Public> directory ensures that new installations of the same version of TestStand do not overwrite the customizations and ensures that uninstalling TestStand does not remove the files you customize.
    Note: National Instruments recommends that you track the changes you make to the user interface source code files so you can integrate the changes with any enhancements in future versions of the TestStand User Interfaces.
    You might also find the Example Programs topic in the NI TestStand Help useful for other tasks.

  • NI USB 8473s sous Labwindows/CVI

    Bonjours à tous.
    Je me rettrouves bien embeté par cette petite boite. En éffet je dois développer un programme exclusivement sous Labwindows CVI ayant pour but de tracer les courbes des informations reçues par ma CAN box et le hic est que je n'arrive tout bonnement pas à le faire à cause de l'incompatibilité entre Channel API et Frame API. Y à t'il une solution sous CVI pour réaliser celà? Peut on réaliser ce programme sous Labwindows sans utiliser les fonctions proposées par le constructeur?

    Bonjour,
    Je remonte un peu votre topic mais je ne sais pas si vous avez trouvé une solution entre-temps.
    Je ne comprends pas tout à fait où se situe votre problème. Pourriez-détailler un peu plus ? Pour l'instant, je ne vois pas trop d'où vient un potentiel problème d'affichage.
    Par ailleurs, qu'entendez vous par "sans utiliser les fonctions proposées par le constructeur" ?
    Cordialement,
    Mathieu P. | Certified LabVIEW Associate Developer
    National Instruments France
    #adMrkt{text-align: center;font-size:11px; font-weight: bold;} #adMrkt a {text-decoration: none;} #adMrkt a:hover{font-size: 9px;} #adMrkt a span{display: none;} #adMrkt a:hover span{display: block;}
    Journées techniques : des fondamentaux aux dernières technologies pour la mesure et le contrôle/comm...

  • CVI DLL target project needs to let caller update progress

    I'm still thinking about this old topic of mine. 
    If I ever get around to packaging my low-level project into a DLL, other host projects that use it won't necessarily be CVI.  So my DLL can't have upward CVI dependencies to let the caller know status of DLL function looping.
    I've looked briefly into multithreading with pointers, but it seems to me that this would be machine/processor dependent.  I can't really use PostDeferredCall because of the CVI dependencies back up in the caller.
    Should I simply increment an index in my loop and output that from the function by reference?  Something like this:
    int DLLSTDCALL myFunction (int* progress)
    double stuff;
    // worker loop
    for (int i=0; i<1000; i++)
    stuff = rand();
    *progress = i;
    return;
    And then just leave it up to the framework caller to handle the progress pointer in a multi-threaded fashion?

    meh, it'll all work out.
    I did some testing with multi-threading and it works pretty well to get visibility of real-time status.
    I decided to leave it up to the client platform to deal with threads on their own if they want this visibility of a DLL function.

  • CVI Nugget - Dealing with Doubles

    I'm not sure if there were past Nuggets in the CVI forum, but here is my first nugget: Dealing with Doubles
    I read an interesting article today:  http://www.exploringbinary.com/the-answer-is-one-unless-you-use-floating-point/
    As I am mostly active in the LabVIEW Forum, I will do a cross post because I want to do a comparison between CVI and LabVIEW when dealing with doubles.  I have not yet implemented the code in LabVIEW, but I do expect the same results.
    In the article by Rick Regan, he explains the results that was obtained when running his function.  I have duplicated is function and add my own main function below. 
    #include <utility.h>
    #include <ansi_c.h>
    #include <userint.h>
    // Prototypes
    double f(double a);
    void main (void)
        int i;
        double result;
        double myArray[21] = { 5.1,  91.3, 451.9, 7341.4, 51367.7, 897451.7,
                            1923556.4, 59567771.9, 176498634.7,
                            2399851001.7, 60098761442.7,
                            772555211114.1, 1209983553611.9,
                            59871426773404.9, 190776306245331.2,
                            2987154209766221.6, 19843566622234755.9,
                            719525522284533115.3, 8399871243556765103.9,
                            39847765103525225199.1, 553774558711019983333.9 };
        for( i = 0; i < 21; i++)
            result = f ( myArray[i] );
            printf("f(%22.1f) \t = %18.17f \n", myArray[i], result );
        while ( !KeyHit() )
            GetKey();  // to see the io screen before the program closes
    double f(double a)
     double b, c;
     b = 10*a - 10;
     c = a - 0.1*b;
     return (c);
    As expected, I get the same output as Rick.
    Rick's output:
    My output (and yes, I was lazy and did not create a pretty table..  I just wanted to show a comparison of the values).
    You can read the article (link provided above) for more details on the values obtained above.  However, the message I am trying to convey is that you have to be careful when "dealing with doubles".  Often I see code where there is an if statement that compares the value to zero.
    For instance something like:
      if ( double zero == 0 )
        // then do something when true
    and people get upset and frustrated because they do not understand why the true case never gets executed.  As a matter of fact, I do recall several discussions on this topic in the LabVIEW forum.  I have actually seen the discussion turn into an argument. 
    What is important to understand is how the processor interprets double values.
    I hope this information will save someone some headaches..
    RayR
    Attachments:
    RicksOutput.PNG ‏16 KB
    MyDoublesOutput.PNG ‏24 KB

    Thanks Ray for this nugget.
    I had fallen across such cases in the past enough times to have learned not to perform any exact match on doble values
    Now your example gives me a reason for this.
    The accuracy of binary representation of doubles has been discussed several times in this forums: in addition to posts that explicitly mention IEEE754 standard I remember a few ones that also cover this subject (for example this thread and this one), but indeed having it explained in a good way is a valuable addition on this subject!
    And yes: you should be awarded for posting the first nugget on the CVI board!
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

Maybe you are looking for

  • HD with HD Compatible TV?

    I am thinking about ordering FIOS.  I currently have an HD compatible TV (about 6-7 years old).  The TV has component hook-ups.  If I order the HD Extreme Package and the HD Receiver will I be able to get true HD?  Or will the HD channels look the sa

  • Report has two duplicated line

    Hi experts, in A/P invoice, I new a document with only one item. but when I preview the print of the document. it appears two item line. the second item and quantity is the same with the first one but without price and total. the format is like below

  • Bi 7 Query execution  error

    Hi All, I have created a query using the new query designer but when i execute it, i get the following errors: <b>Components ZDELETE (version A) do not exist on the database</b> <b>DP_1: Unable to load query ZDELETE</b>. This is our Dev system, on Sa

  • "The project was saved in a newer version of premiere pro and cannot be opened in this version." How can I keep the projects interchangeable?

    I recently updated my Premiere Pro CC at home to 2014.1 and now can't open my projects at school where they are using Premiere Pro CC 2014. (which was up to date last week) Since I don't know how long it will take for them to update all of the comput

  • Problem updating graphic styles specs, after scaling illustrator image

    Hello there, I'm designing a map in Illy and have created graphic styles for the various route keys I use. After recording the styles, I've enlarged the map, so the specs for all the styles has changed to a greater value (stroke width etc.) I've trie