Interopérabilité entre labview et labwindows/CVI

Bonjour,
j'utilise labview 7.0 dans lequel je souhaite utiliser une DLL compilée avec LabWindows/CVI. Cette DLL contient une fonction de communication avec un équipement distant de type get_value.
Donc, grâce à cette DLL, l'outils labview demande une valeur à l'équipement distant. La fonction CVI envoie la requête à l'équipement distant et attend la réponse de celui-ci avant de retourner la réponse sous labview.
Donc l'exécution de la fonction CVI est assez longue mais entre l'envoie de la requête et la réception de la réponse, le processeur n'est pas utilisé. Néanmoins, durant l'exécution de la fonction, le rafraichissement de la fenetre labivew n'est plus opérationnel et de manière général, l'application labview sem
ble gelée.
Est-il possible de libérer le process pour labview au sein de la DLL sans en sortir ?
J'ai essayé les fonction delay, process draw event et process system event mais rien ne semble libérer le process.
Y a-t-il une solution?
Merci

Hello,
La bonne vieille recherche d'exemples (Help-> Find Examples) reste toujours efficace. Je vous suggère d'aller faire un tour dans la partie MultiThreading. On y trouve toutes les principales fonctions pour créer des threads et y exécuter du code (en parallèle, donc !).
Cet article est aussi un bon départ.
Cdt,
Eric M. - Application Engineering Specialist
Certified LabVIEW Architect
Certified LabWindows™/CVI Developer

Similar Messages

  • Can I convert Labview panel to Labwindows/CVI uir file

    I a project that I want to convert from labview to Labwindows\CVI.
    I don't want to call my VI's from LabWindows.
    It is possible to convert some Labview fronts panels to *.uir files (Labwindows/CVI)
    Thanks

    Hi Artus!
    Unfortunately there is no automatic way to convert a LabView Front Panel into a Labwindows UIR.
    The only way you can do this is by creating a new interface and adding all the elements that you need, but this way would actually mean rebuilding everything based on something you already have. Sorry about the bad news
    I wish you the best day!
    Oswald Branford

  • Converting HP-BASIC code into Labview or Labwindows

    I need some insight on as to whether I can use all my HP-Basic code in labview or labwindows and how? Can I create dlls and call them into labview or use the code itselg in LabWindows?
    Any information will be appreciated.

    A very long time ago, there was a BASIC version of LabWindows.  You could not convert a Rocky Mountain BASIC program directly, but it was a fairly simple fit.  You could then translate that into C code automatically through LabWindows.  That was one of its selling points; you didn't have to lose all of that old BASIC code.  About 10 years ago, they decided to go with only a C version of LabWindows and renamed it LabWindows/CVI.  This change was made because most people who were converting from BASIC to C already had and supporting two languages and a translator was very expensive (cost, memory, processing power, complexity, - expensive in every way). 
    If someone has an old version, you might have an upgrade path with your old code (no, I don't have any that old).  Otherwise, you could build DLLs and call them with either LabVIEW or LabWindows/CVI.  You could also recreate the code with the newer language.
    Hope that this helps,
    Bob Young
    Bob Young - Test Engineer - Lapsed Certified LabVIEW Developer
    DISTek Integration, Inc. - NI Alliance Member
    mailto:[email protected]

  • Intercept LabWindows/CVI CLOSE event

    In my LabWindows UI the user can click the X on the top right to quit the application.
    I'd like to intercept that message to do various things before it gets to the TestStand Engine.
    I tried to use InstallWinMsgCallback for a WM_QUIT and WM_CLOSE but it doesn't get called.     
    Thanks,
    Ronnie
    TestStand 4.2.1, LabVIEW 2009, LabWindows/CVI 2009
    Solved!
    Go to Solution.

    OK - I figured it out - it's the EVENT_CLOSE generated by the MainPanelCallback.
    TestStand 4.2.1, LabVIEW 2009, LabWindows/CVI 2009

  • I used to working with Labwindow CVI and i would like to know how can i use the commands "loadpanel" and "Displaypanel " in Labview. Using Invoke Nodes?

    I want to make another panel appears and runs, but i don´t want to use a subpanel. So, i would like to use somenthing similar to Loadpanel and Displaypanel, that you can use in Labwindows CVI, but in Labview, is ti possible?I hope your answers, thank you!!!

    Hi Bichillo,
    I posted an example here.
    http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=137&HOID=50650000000500000014570100&HTHREAD=000087828&UCATEGORY_0=_49_%24_6_&UCATEGORY_S=0
    It demonstrates how to do what you are asking.
    I do not mind you laughing at the code.
    Have fun!
    Ben

  • Yokogawa UT driver for LabWindows/CVI 6.0 won't translate to LabVIEW 8.6?

    The device driver for the Yokogawa UT series furnace controllers is in LabWindows/CVI 6.0 and I would like to use it in LabVIEW. I tried to use the utility to convert from LabWindows/CVI to LabVIEW, but it said it couldn't and that the device driver is from before LabWindows/CVI 5.01.
    In any case, here is the series of events.
    I downloaded the LabWindows/CVI to LabVIEW Converter, from
    the page on LabVIEW's developer's connection that had the driver for the
    Yokogawa UT controller.
    From an empty LabVIEW Block Diagram, I click
    Tools>>Instrumentation>>Create LabVIEW Interface to LabWindows/CVI
    Instrument Driver...
    This takes a little while to load. During loading an
    FC_Interface_Main.vi runs, apparently trying to find a file.
    Once that is done, the two options are Basic and Advanced. I leave
    basic selected. I click next. browse to find the ykut.fp file from the
    driver I downloaded.
    I then click next. The error window that is seen in the screen shot is
    then shown.
    I called a tech support guy at NI about this, and I e-mailed him with all the above, but there was no reply, though the conversion utility is no longer available on the same web page as this specific device driver.
    In any case, if anybody could give a little guidance, it would be appreciated.

    Hello Screamingzebras,
    I converted the .fp file to be version 5.5 and ran the utility that was mentioned.  I have attached two files to this post.  "ykut.zip" is the converted .fp file (version 5.5).  "yut.zip" is the converted instrument driver.
    Regards,
    Jon S.
    National Instruments
    LabVIEW R&D
    Attachments:
    yut.zip ‏174 KB
    ykut.zip ‏25 KB

  • Conversion of an Instrument Driver from LabWindows/CVI to LabVIEW

    Hello All,
    Conversion of an Instrument Driver from LabWindows/CVI to LabVIEW
    http://zone.ni.com/devzone/conceptd.nsf/webmain/9A93316BEBEDB17786256FA300675A0A 
    But I can not find any hyperlinkt to download
    "LabVIEW Interface Generator for LabWindows/CVI Instrument Drivers"
    Is there any evaluation version for downloading?
    Thanks,
    nonomiya

    So strange,
    I go through three pages but does not find any entry for download,
    hmm...,
    1. After press the hyperlink,
    See Also:
    LabVIEW Interface Generator for LabWindows/CVI Instrument Drivers
    2. and for a resuest info. form.
    3. press download..
    ====
    LabVIEW Interface Generator for LabWindows/CVI Instrument Drivers
    System Requirements
    NI LabVIEW 7.1 or later
    Windows 2000/NT/XP
    Use the LabVIEW Interface Generator for LabWindows/CVI Instrument Drivers to create LabVIEW VIs for VXIplug&play and IVI-C instrument drivers from function panel (.fp) files.
    Instrument Driver Network
    Before using the conversion utility to create a new instrument driver wrapper, please visit ni.com/idnet to see if a LabVIEW Plug and Play instrument driver is available for your device. The Instrument Driver Network (IDNET) provides support for more than 3,000 different instrument models from over 170 different instrument vendors.
    Recommendations
    This utility was created for developers of C-based instrument drivers who wish to provide a LabVIEW interface, but do not develop a LabVIEW Plug and Play driver. By developing the C and LabVIEW interfaces together, it keeps the components synchronized, and eliminates the need for customers to create their own LabVIEW interfaces. Vendors should distribute the LabVIEW wrapper files with the associated VXIplug&play or IVI instrument driver, so that end users do not have to visit multiple web sites to download the complete driver.
    If you are not an instrument vendor, we recommend that you use this utility only if you have instrument driver expertise. Access to the instrument driver source code is preferred, in case you need to edit the C instrument driver in LabWindows/CVI.
    After generation, the wrapper VIs should be tested with the instrument.
    Instructions
    Once you install the software, simply access the utility from the Tools>>Instrumentation>>Import CVI Instrument Driver...menu in LabVIEW. This software replaces the built-in tool and provides feature enhancements.
    For additional information on this utility, view the resources below.
    Readme for the LabVIEW Interface Generator for LabWindows/CVI Instrument Drivers
    Submit your Driver
    Visit the Instrument Driver Network
    nonomiya

  • Q: Must one use special LabVIEW types (e.g. float64) for DLLs in LabWINDOWS/CVI?

    Hello,
    I have recently started compiling C code using LabWindows/CVI, and have successfully called a simple DLL function from within LabVIEW.
    I have a question about the types defined in LabVIEW's extcode.h file:
    These are defined to explicitly quantify the number of bits used for each data type (e.g. float64 instead of float) in order to eliminate ambiguity across compilers.
    When I am using LabWindows/CVI to compile, do I need to use the LabView numeric types defined in LabView's extcode.h, or can I use the standard C types (int, float, etc.)?
    Is there a distinction between having to use these special types for CIN versus shared library calls in LabVIEW?
    Thanks
    in advance,
    Frenk

    You do not have to use the defines in extcode.h, but you certainly can if you want to.
    The float64 is equivalent to CVI's "double", and the float32 is equivalent to CVI's "float".
    These correspond to the double- and single-precision types in the IEEE Standard for Floating Point Arithmetic, IEEE-754.
    I hope this helps.
    Brian

  • Announcement: Security Update 5Q5FJ4QW for multiple versions of LabWindows/CVI and LabVIEW

    An update for LabWindows/CVI and LabVIEW users is now available for download. This update resolves security vulnerabilities in components installed with LabWindows/CVI 2010 SP1 and earlier and LabVIEW 2011 and earlier. Further details can be found at KnowledgeBase Article 5Q5FJ4QW: How Does National Instruments Security Update 5Q5FJ4QW Affect Me?
    The update can be downloaded with NI Update Service 2.0 (which installs with LabWindows/CVI 2010 SP1 and LabVIEW 2011) or from the Drivers and Updates page. Information about the update is also available in other languages through links in the Drivers and Updates page.
    This is free update for all LabWindows/CVI and LabVIEW users.
    National Instruments
    Product Support Engineer

    The correct link should be this one
    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?

  • Are there some "waveform measurements" componet in LabWindows/CVI as in the LabVIEW ?

    I want to use some"waveform measurements" function , but I don't familiar with  LabVIEW  ,
    Is there a  corresponding  componet in  LabWindows/CVI ?

    This depends on your CVI version... the full development version includes the advanced math library, which provides functions such as PulseMeas to evaluate waveforms.

  • Is LabWindows/CVI suitable to me more than Labview?

    I know some of the LabVIEW gurus might have some insightful words to share on this thread (formerly posted on the CVI forum).
    Is LabWindows/CVI suitable to me more than Labview?
    Wendyk

    There were some excellent response there. I would, however, like to make a few addtional comments.
    First, LabVIEW is a compiler. The "source" code is compiled when the run button on the toolbar is pressed. The creation of an exe is done with the application builder that has been available for much longer than version 6. But, since the development environment is also a compiler, you will not see a signicificant improvement in execution speed when building an exe.
    I originally started my NI programming with LabWindows v1.0. Back then, despite it's name, it was only available for DOS. I transitioned to LabVIEW when it was released  for Windows 3.0. I had no great difficulties in making the transition. In fact, I had a great deal of fun in learning it and loved being able to "write" a program using only a mouse. Given some time and training, I think any text based programmer can do the same if he or she is willing to do so. Like anything else, there is a learning curve to LabVIEW but I don't think it's as steep as someone first starting to program C++ or VB.
    I still do some occassional LabWindows programming but in my instrument control and DAQ applications, I simply find LabVIEW allows me to get the job done faster. If you have some specific imaging or motion application in mind, look over the tools available for each in LabVIEW and LabWindows and check over in those forums to see what they are using.

  • Is LabWindows​/CVI running faster than LabView?

    A colleague told me that LabWindows/CVI is much faster than LabView. And I make a mistake if I would go on using LabView. So he tried to convince me of LabWindows/CVI. What are your experiences? Which program is faster: LabWindows/CVI or LabView?
    mara

    It all depends on what you're doing. I've used both (LabWindows since v1 and LabVIEW since v3), and in my instrument control and daq applications, I don't see any. I think LabVIEW is faster to develop in and that's the main advantage for me. NI has a benchmark here if that helps at all. Either LabVIEW or LabWindows is a good choice. If you're an experienced C programmer, you might be better off sticking with the more familar CVI but if you're not, LabVIEW should work just fine.

  • Labwindows/CVI multitaches: acquisition et contrôle d'instrument

    Bonjour a tous,
    Dans le cadre d'un développement sous labwindows/CVI je suis amené à réaliser une acquisition tout en contrôlant autre un instrument. Je pense que la solution est le multi taches.
    Mon problème est que je ne connais pas du tout cette méthode, et je souhaiterais savoir si s'est une solution viable pour à la fois lancer une acquisition pendant que je contrôle un instrument (reset de son alimentation). Dans le cas contraire, pouvez vous m'indiquer une solution, avec la démarche a réaliser?
    Je sais réaliser une synchronisation entre une génération et une acquisition mais dans ce cas, il faut gérer une carte d'acquisition et un autre instrument. Comment faire??
    Je vous remercie
    Cordialement,
    Julien_B

    Hello,
    La bonne vieille recherche d'exemples (Help-> Find Examples) reste toujours efficace. Je vous suggère d'aller faire un tour dans la partie MultiThreading. On y trouve toutes les principales fonctions pour créer des threads et y exécuter du code (en parallèle, donc !).
    Cet article est aussi un bon départ.
    Cdt,
    Eric M. - Application Engineering Specialist
    Certified LabVIEW Architect
    Certified LabWindows™/CVI Developer

  • Rapport cyclique variable - Labwindows CVI - PXI 5411

    Bonjour Madame, Monsieur,
    Je développe actuellement une application sous Labwindows CVI permettant de faire varier en fréquence 3 signaux déphasés de 120° entre eux . Pour cela je dispose de 3 cartes PXI 5411.
    Cependant, le rapport cyclique est fixé à 50% par défaut. Mes signaux doivent avoir un rapport cyclique Th=75%.
    Je ne sais pas comment programmer cela sous CVI.
    Voici mon bout de code (dans moin exemple j'ai fixé la fréquence à 500Hz) :
    int CVICALLBACK COMMANDBUTTON (int panel, int control, int event, void *callbackData, int eventData1, int eventData2)
     ViReal64 DC=75.00; 
     ViReal64 frequence=500.00;
     ViChar GBF1[256]="DAQ::3";
     ViChar ChannelGBF1[256]="0";
     ViReal64 Amplitude1=5;
     ViReal64 DCOffset1=2.5;
     ViInt32  Waveform1=NIFGEN_VAL_WFM_SQUARE;
     ViChar GBF2[256]="DAQ::5";
     ViChar ChannelGBF2[256]="0";
     ViReal64 Amplitude2=5;
     ViReal64 DCOffset2=2.5;
        ViInt32  Waveform2=NIFGEN_VAL_WFM_SQUARE;
     ViChar GBF3[256]="DAQ::7";
     ViChar ChannelGBF3[256]="0";
     ViReal64 Amplitude3=5;
     ViReal64 DCOffset3=2.5;
        ViInt32  Waveform3=NIFGEN_VAL_WFM_SQUARE;
     switch (event)
      case EVENT_COMMIT:
       /* Ressource 1 maître, ressource 2 et 3 esclaves*/  
     if(vi1 != VI_NULL) { niFgen_close(vi1);}  
     if(vi2 != VI_NULL) { niFgen_close(vi2);}
     if(vi3 != VI_NULL) { niFgen_close(vi3);}  
     niFgen_init(GBF1, VI_TRUE,1, &vi1);
     niFgen_init(GBF2, VI_TRUE, 1, &vi2);  
     niFgen_init(GBF3, VI_TRUE,1, &vi3);  
      /* Configuration du maître*/
     niFgen_ConfigureRefClockSource(vi1, NIFGEN_VAL_RTSI_CLOCK);
     niFgen_RouteSignalOut(vi1, "0", NIFGEN_VAL_OUT_START_TRIGGER,NIFGEN_VAL_RTSI_1);
     niFgen_RouteSignalOut(vi1, "0", NIFGEN_VAL_SYNCHRONIZATION,NIFGEN_VAL_RTSI_0);   
       /* Configuration esclave 1*/
     niFgen_ConfigureRefClockSource(vi2, NIFGEN_VAL_RTSI_CLOCK);
        niFgen_ConfigureTriggerSource(vi2, "0", NIFGEN_VAL_RTSI_1);
        niFgen_ConfigureSynchronization (vi2, "0", NIFGEN_VAL_RTSI_0);  
       /* Configuration esclave 2*/
     niFgen_ConfigureRefClockSource(vi3, NIFGEN_VAL_RTSI_CLOCK);
        niFgen_ConfigureTriggerSource(vi3, "0", NIFGEN_VAL_RTSI_1);
        niFgen_ConfigureSynchronization(vi3, "0", NIFGEN_VAL_RTSI_0);   
      /* Configuration et generation forme d'onde esclave 1*/
        niFgen_ConfigureOutputMode(vi2, NIFGEN_VAL_OUTPUT_FUNC); 
     niFgen_ConfigureStandardWaveform(vi2, ChannelGBF2, Waveform2, Amplitude2, DCOffset2, frequence,120);
     niFgen_InitiateGeneration(vi2);
        niFgen_ConfigureOutputEnabled(vi2, "0", VI_TRUE);     
     niFgen_SetAttributeViReal64 (vi2, ChannelGBF2, NIFGEN_ATTR_FUNC_DUTY_CYCLE_HIGH, DC); 
      /* Configuration et generation forme d'onde esclave 2*/
        niFgen_ConfigureOutputMode(vi3, NIFGEN_VAL_OUTPUT_FUNC); 
     niFgen_ConfigureStandardWaveform(vi3, ChannelGBF3, Waveform3, Amplitude3, DCOffset3, frequence,-120);
     niFgen_InitiateGeneration(vi3);
        niFgen_ConfigureOutputEnabled(vi3, "0", VI_TRUE);
     niFgen_SetAttributeViReal64 (vi2, ChannelGBF2, NIFGEN_ATTR_FUNC_DUTY_CYCLE_HIGH, DC); 
     /* Configuration et generation forme d'onde maître*/
        niFgen_ConfigureOutputMode(vi1, NIFGEN_VAL_OUTPUT_FUNC);
        niFgen_ConfigureStandardWaveform(vi1, ChannelGBF1, Waveform1, Amplitude1, DCOffset1, frequence,0);   
        niFgen_InitiateGeneration(vi1);
        niFgen_ConfigureOutputEnabled(vi1, "0", VI_TRUE); 
        niFgen_SetAttributeViReal64 (vi2, ChannelGBF2, NIFGEN_ATTR_FUNC_DUTY_CYCLE_HIGH, DC); 
        break;
     return 0;
    Naturellement, je me connecte sur la sortie SYNC OUT des cartes PXI. Aussi, j'ai essayé à l'aide du Front Panel NiFgen et là j'arrive à faire varier le rapport cyclique (quelque soit le signal généré sur la sortie ARB OUT).
    Pourriez-vous m'aider??
    La fonction ; niFgen_SetAttributeViReal64(vi2,ChannelGBF2,NIFGEN​_ATTR_FUNC_DUTY_CYCLE_HIGH, DC);
    ne fonctionne pas.
    Cordialement,
    Eric

    Bonjour Eric,
    Tu as posté ta question sur la partie internationale du forum.
    Si tu souhaites avoir plus de chance d'avoir une réponse je te conseille soit d'y poser ta question en anglais soit de la poser sur le forum francophone : French forum
    Nevertheless, you should be able to change the duty cycle with the following function:
    ViStatus niFgen_SetAttributeViReal64 (ViSession vi, ViConstString Channel_Name, ViAttr Attribute_ID, ViReal64 Attribute_Value);
    You can take a look at CVI examples and especially to the 5404ClockGeneration. cws example which change dynamically the duty cycle with the function above. (Help>>Find Examples)
    Regards,
    Valentin
    Certified TestStand Architect
    Certified LabVIEW 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;}
    Travaux Pratiques d'initiation à LabVIEW et à la mesure
    Du 2 au 23 octobre, partout en France

  • 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...

Maybe you are looking for