LabVIEW OPC Connection

Hi,
Could anybody send me an example for LabVIEW to connect to an OPC Server
to read/write IOs from a plc. I have to connect to a Siemens plc via
SIMATIC NET OPC Server. Or maby you can post a link for further
information and/or examples because i couldn't find any at the NI
Developer zone.
Thanks,
Max

There are examples included with LabVIEW; they are stored in the comm folder:
Program Files\National Instruments\LabVIEW 7.0\examples\comm\opc.llb
MTO

Similar Messages

  • Data access in Teststand/LabVIEW through OPC connection

    We are using TestStand 2.0 and LabVIEW6.2 and following problem occurs when accessing the datas from UUT through OPC.
    For the first UUT i get the measurement datas but starting the next UUT causes a system hang up. The corresponding LabVIEW VI stops at the connect to the OPC Server it doesn't read the selected item. Only with LabVIEW there is no problem launching OPC data access for multiple times. Does anyone have expierence with this configuration: TestStand-LabVIEW-OPC?

    For your information, there is a new TestStand Add-on "OPC DA Connect" which adds a StepType Palette dedicated to OPC Data Access.
    You can configure each step by browsing the OPC servers on your network and browsing variables within these servers.
    This toolkit has free deployment licence.
    Hoping this helps.
    Jean-Louis SCHRICKE
    ├ CTA - Certified TestStand Architect (2008 & 2010 & 2014)
    ├ CTD - Certified TestStand Developer (2004 & 2007)
    └ CLD - Certified LabVIEW Developer (2003 & 2005)

  • OPC Connection faliure/status using LabView & Protool

    Hi there,
    we are integrating NI Vision solution into Siemens Step7/Protool automation environment. Two CVS modules perform visual inspection and communicate via Ethernet with Siemens Protool vizualization/GUI application running on Windows XP based PC. Protool is serving as OPC 2.0 compliat server and LabView "helper" application on PC is mirroring OPC data to and from NI PSP (Shared variable) domain which NI CVS-es use to communicate. All works well until we shut down and/or restart Protool (and thus the OPC service along with it).
    Helper application fails to acknowledge any Connection Status change (as its status remains: Connected) if/when OPC is turned off ... furthermore once the Protool OPC is up and running again the values in LabView OPC bound items within helper app. cease to be updated although their Connection Status Property is shown as: Connected throughout ...
    Has anyone had a similar problem? What could be the cause/solution to the behavior described?
    Thanks in advance,
    Robert

    Hi Mike,
    LabView "helper" app. is residing on Win PC and has controls that are data-bound to ProTool OPC via datasocket. The PC hosts shared variables that CVS-es use to communicate to PC. helper app. is transfering data between ProTool OPC and NI PSP network as necessary. If OPC is "power cycled" the "datasocket LED" of OPC DataBound controls remains green as nothing happened! If we use DataSocket (DS) pallete to programatically open DS conneciton to an OPC item, connection is rejected if OPC is not running, but once connected the "connection:status" property wont change if we shutdown the OPC!
    Why is this happening? Is there a manner to detect the "running" status op OPC? Is there a more elegant way to bring OPC and NI PSP network together that would bypass the need for data pooling? Would the functionality of DSC help, like "register for events notification" function?
    We would sure could use a quick soultion to this ...
    Thx and regards, Robert

  • OPC connection failure

    I'm continue to troubleshoot OPC connectivity via Shared Vairables. I've attached the error log output by LabView. Any ideas on the proper fix for this? I'm assuming it's making the proper registry entries, but I'm not sure where to begin. The errors are "Class not registered" problems. Everything is running on the local machine, and I can get standard OPC clients to connect, but not the Shared Variables. 
    The relevant errors are at the top of the log.  
    Attachments:
    OPC Error Log.txt ‏14 KB

    Hi, is this the same topic as this. If it is we should stick to the older thread. However, for the time being, have you checked your dcom settings?
    In order to successfully communicate to the OPC server, you need to allow the proper exceptions in the Windows Firewall.  Open up the Windows Firewall from the Control Panel, and select the Exceptions tab.  Click on Add Program... and add the following:  
    All OPC Clients and Servers
    Microsoft Management Console
    OPC utility OPCEnum.exe found in the Windows\System32 directory
    Next, In the Exceptions tab of the Windows Firewall, click on Add Port...
    In the Add a Port dialog, fill out the fields as follows: (Name: DCOM) (Port Number: 135) and check tcp
    National Instruments
    RIO Embedded Hardware PSE
    CompactRIO Developers Guide

  • Labview Database Connection Toolkit and decimal point

    Hi,
    on my system I use "," (comma) as decimal point.
    In Labview Options I unflagged "Use localized decimal point", and numeric controls and indicators use "." (dot) as decimal point.
    The problem is that Labview Database Connection Toolkit keeps returning floating point numbers as strings with comma as decimal point.
    Has anyone experienced this issue?
    Is this related to Labview or MySQL ODBC Connector (that I'm using to connect to a mySQL DB)?
    Thanks in advance for any help,
    Marco

    You have two or three places to look. First there is the DCT. Second, there's a couple layers there that could cause problems (the mySQL drivers and ADO) and then there's even the posibility that the issue could be in the DBMS itself.
    I would start by burrowing down through all the DCT layers and find the spot where the results are actually being read back fromt he database. If the resutls are read as variants and converted to LV datatypes, the problem is on the LV side. If the values are being read as strings and converted, the problem coiuld be on the other side.
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

  • LabView database connectivity toolkit 1.0.1 compatibility with MS-ACCESS 2010 / Labview report generation toolkit for Office 1.1.3 compatibility with Office 2010

    In the very near future we will be forced to upgrade to Office 2010 Company wide and I am a little concerned with some of our older test platforms that have applications built in LabView 8.2.1.  These applications save data to MS-ACCESS 2000 databases using the LabView database connectivity toolkit 1.0.1.  Office 2003 is also loaded on these test platforms with all test reports generated using the LabView report generation toolkit for Office 1.1.3.
    I have not gotten my hands on a copy of Office 2010 yet to see if there will be any compatibility issues.  Does anyone have any experience in this area?

    The MS-Access part is fairly well isolated through the ADO interface LabVIEW uses. The only possible problems there IMHO are difficulties with possible Acess compatibilities itself such as an example, SQL statement you may have invoked directly through the ADO interface. Maybe you did use a depreciated command back then that has since been removed. As long as the only thing you do are simple INSERT and SELECT statements only, I would expect it to just keep working.
    The Report Generation interface is a different beast. Microsoft manages to change the Automation interface with every version of office in a way that strongly binding applications like LabVIEW break on. There is no good way around that except not changing those methods, but that is a cause that has been lost already. You will certainly have to verify the version dependant Report Generation API VIs to still work with Office 2010 and most likely you will have to make some changes to those VIs to make them work again with the modified ActiveX interface of Office 2010. Note, that I have no experience with porting report generation to Office 2010 but I have had some headaches from porting that between Office 97, 2000, 2003, and 2007.
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Storing labview TCP connection in TestStand object reference

    I have a LabVIEW routine (GetFileGlobal) that uses the TestStand SequenceContext->FileGlobals to do a lookupString and determine the GetType if the string 'Exists'.  I have a LabVIEW case statement that captures values of '1' for GetValString, '2' for GetValBoolean, and '3' for GetValNumber.  I have a LabVIEW TCP connection that gets opened that we need to store in TestStand in a FileGlobal.  What type is necessary in TestStand to store a TCP Conn?  AND, given the (tbd) type in TestStand, what is the value I would need in my case statement to capture this new (tbd) type coming out of the GetType?  

    I've asked this on another thread, but I'm just not understanding the exact implementation.  In TestStand, the LabVIEW IO Controls type is made up of a DeviceName and a SessionNumber, but in LabVIEW I have a TCP Network Connection.  I have routines that let me Get/Set TestStand File Globals if they are Boolean, String, or Number.  Now, if I use LabVIEW IO Controls in TestStand, what is the exact way I stuff a TCP Network Connection in there.  I've attached a VI that I use to GET the FileGlobal value from TS.  I need to grow it to allow me to get the TCP connection (i.e. LabVIEW IO Controls), but I'm not sure how to do that.  The types are messing me up.  Also, I'm not sure what the 'GetType' wants to see
    Attachments:
    FTW_ATE_UTIL_GetFileGlobal.vi ‏25 KB

  • Problem of security using ADO from Labview to connect to Access 2000 Data Base

    I have a problem using ADO from Labview to connect to Access 2000 Data Base.
    First I open a ADO_DB_Engine and create a Workspace as an ODBCDirect. After I execute the open_data_base using the workspace. Here you can specify the parameter connect with /type of connection / user / password.
    The problem is the following:
    Although you configure a password for the Administrator user in Access, you can read/writte to data base from Labview using ADO without any security and without putting the user and password in the parameter connect. I need to access with security to data base using users and permissions but it seems that the parameter connect does not operate.
    I attach
    you a example of the vis and database. Remember create a ODBC connect with BD3.mdb
    Thanks a lot
    Peter Mst
    Attachments:
    SECURITY.zip ‏70 KB
    BD3.mdb ‏112 KB

    Hi Kahn,
    If you use ADODB_connection -> Connection.Open and set in connection string :
    "Provider=Microsoft.Jet.OLEDB.4.0; Jet OLEDBystem Database=c:\.....\Protegida5.mdw; Password=pepe;user ID=jose; Data Source:c:\......\BD5.mdb";
    and after connection.execute ->
    INSERT INTO tabla1 VALUES (5,'XXX'
    you will be able to access to the database with security using the provider=Microsoft.Jet.OLEDB.4.0. With this provider you have to use the path and the name of the database file c:\.....\mdb file. From this way the problem is solved. (SEE SAMPLE_ADO_W2_JET.VI).
    BD5.mdb have the following administrator user: user:jose / passwordepe (Protegida5.mdw)
    The problem is when you want to
    use ODBC and DSN. The name of this ODBC Provider is MSDASQL;. If you use this type of connection you can not enter to the database I attach you.
    This database has a new administrator owner. I deleted the default administrator. If you support the default administrator you can connect to database by ODBC / DSN but the security disappear because you can always enter to database with any password, user o PC.
    FINALLY I HAVE 3 QUESTIONS FOR Application Engineers of National Instruments or someone who knows these subjects before deciding the best way to connect locally o remotely with security to Access from Labview:
    1.- Is it possible to enter to Database BD5.mdb from ODBC and DSN with this owner?
    2.- I want to connect remotely to Access database too. Is it possible to use Microsoft.Jet.OLEDB.4.0 using the path (.mdb file) without DSN?
    3. Which is the optimal Provider for Microsoft Access?
    I thank you beforehand for your technical support.
    Peter Mst.
    Attachments:
    BD5.mdb ‏116 KB
    Protegida5.mdw ‏112 KB
    sample_ADO_W2_JET.vi ‏45 KB

  • I have an existing application need to add LabVIEW OPC Server

    I have an existing application written in LabVIEW which controls a Device. The data from the device is currently logged to the local drive. 
    It is desired to upgrade this application to become an OPC Server so that the manager can remotely acquire data and control the Application.
    What would be the easiest approach to accomplish this task?
    Thanks and Best Regards,
    Gary

    Hello Dan,
    1. The operator specifies a time interval to save the data to disk. The data is stored in a csv file.
     2. The manager is the Engineer who is managing the data collection system remotely.
    3.The desired end result is to have the LabVIEW with an OPC server provide the connectivity to an OPC client so that they can collect the data, that they desire from the system, and control the system.
    4. Controlling the system is secondary. Providing the connectivity so that an OPC client can specify what data is to be sent and the update interval is the first priority.  For example, they may only be interested
    in 10 of say 30 parameters, and want that data sent over every 10 seconds or so. The data once they receive it will be logged to a central data base.
    We suggested using TCP/IP but they do not want a custom interface.
    We also suggested Modbus, but they perfer to use OPC. The want to integrate it with their OSI PI.
     Thanks and Best Regards,
    Gary

  • Executable opc connection

    Hi all
    I-trying to build an executable which reads values from a RT-target (cRIO) and then sends this data to an opc-server.
    I managed to read the values from the rt-target, but unfortunatelly the connection to the opc seems not to work. I created a library with the opc Server and the variables in the project. if I run the vi on the pc with LabView installed everthing works fine. Also if I try the executable on this pc. When I change to the other PC where I want the executable to be running. The programm runs with no error, but the data never gets to the OPC-server.
    Has somone any idea why this happens?
    Thanks
    Manuel

    Hi Manuelwaser,
    your problem sounds like an configuration problem.
    It would be helpful to post your build-specifications or your project without VIs.
    Here is an guide for ...
    Building an Installer (Windows) - LabVIEW 2011 Help - National Instruments
    http://zone.ni.com/reference/en-XX/help/371361H-01/lvhowto/build_installer/
    How Do I Use OPC in LabVIEW? - National Instruments
    http://digital.ni.com/public.nsf/allkb/EA15F53DB6FECCA5862567240064DF09
    Over that you'll need the DSC RUN-Time System:
    What is the DSC Run-Time System and When Should I Use It? - National Instruments
    http://digital.ni.com/public.nsf/allkb/E56DB8726DB68F288625770E00594351?OpenDocument

  • OPC Connection

    Hello,
    I have a significant problem with connect an OPC Server to my Labview Application. I make use of  the AX OPC Server of Phoenix Contact this is already working. Now I have no idea how I can simply write a boolean or read one. I need an easy VI were I can add the IP adress of my server or something like that.  It would be nice if I can use this variable as a normal one in my VI.
    I would be thankfull for each support!!!
    Thank you

    HI,
    did you already open the example OPC project in the LV example finder?
    Is this any help?
    Anna

  • LabVIEW OPC UA support ?

    Hello All,
    Does anyone know when OPC UA will be supported in DSC and NI OPC servers?
    BR,
    Jim

    HI, I'm trying to connect to an Arburg injection moulding machine from Labview 2013. The machine has got an OPC UA server running and is configured with TCP/IP, I've connected using UAExpert but not LV.  NI OPC doesn't seem to detect either the Arburg OPC server or the UAExpert OPC server. Any suggestions on how to resolve this would be welcome.
    regards
    ER

  • LabView OPC client versus Opto22 Ethernet brain SNAP B3000

    I'm trying to use some OPC examples from the LabView 6i library connecting my PC to the OPC server provided by the Opto22 Ethernet brain SNAP B3000. Every time the program access the brain it hangs up. There is any known mismatch between the two implementations of the OPC communications or what I miss?

    NI has a good troubleshooting utiltiy to view OPC servers as an OPC client. Contact NI directly and we can get you this troubleshooting utility.
    http://www.ni.com/support/
    or 512-795-8248 ask for Industrial Automation.

  • Why labview dosnt connect to mysql in this example?

    Hello.
    I have a problem to connect with mysql. can you help me?
    I make a database in my sql and I use ODBC as interface.
    in labview, ADO blocks are used to connect with mysql as example attached. but, when I run this program, it dosn't work. this example is along with ADO pack.
    By the way,, it dosnt get me any ID!
    do you know what is the problem?
    Best Reagards
    Attachments:
    Example - Insert into a Table.vi ‏14 KB

    UDL is very basic and best way to communicate to DB. becasue here you can change the database which you need to connect to any time. I havent seen your VI but first you need to create UDL file and configure it as per your application. For there if you can test the connection that means your configuration is ok.
    Then from VI you need to open the UDL file and check the error message. From there you can easily check what is the problem.
    Here start from page 3-4. Let us know if any issue
    Kudos are always welcome if you got solution to some extent.
    I need my difficulties because they are necessary to enjoy my success.
    --Ranjeet
    Attachments:
    Database.pdf ‏687 KB

  • LabVIEW Database Connectivity Toolkit Parameterized Query Property Wildcard

    Hi,
    within my LabVIEW application I successfully implemented a SQL statement
    like
    SELECT *
    FROM table_name
    WHERE property 1 = 123
    AND property2 = "abc"
    with help of the Database Connectivity Toolkit. I first created a parameterized
    query, then set each parameter and afterwards executed this query.
    But now I want to use wildcards within this statement. Does anybody know
    how to use wildcards with both integer properties and string properties?
    Is this possible while using the normal parameterized query vi?
    Thanks in advance for your help.
    Regards
    Michael

    Hi Michael
    You can use "LIKE":
    SELECT * FROM table_name WHERE property 1 LIKE '12%'
    % represents multiple characters (e.g. entries with property 1 123 but also 1240 would be selected)
    _ represents one character
    Hope this helps.
    Thomas
    Message Edited by becktho on 09-05-2005 11:57 AM
    Using LV8.0
    Don't be afraid to rate a good answer...

Maybe you are looking for

  • Compressor setting so it won't output a video larger than source?

    Hello. I am sending a whole library of videos (most Apple ProRes, but varrying video dimensions based on the project) through Compressor 4 and I'm having an issue where, for some of the videos (with smaller video dimensions), the settings I'm choosin

  • Failed Recovery of Satellite C855

    I have created Recovery DVDs for this product and they don't seem to work. It is for Windows 8 but booting from the DVD fails. It boots the DVD and then presents a Windows 8 type screen which says "Recovery - your PC needs to be repaired" with "a req

  • Iphoto is no photo...

    Happy Labor day! I upgraded to the latest version of iphoto updated my photo library, life is good. Then Big black question mark over the application in the dock... huh? Go to look for the App. On the drive... gone, yes, gone. Nope I delete it, I'm n

  • Up-grade PATH from Stack9 to Stack11

    I would like to upgrade Stack11 from Stack9 for Enterprise Portal. But I couldn't find any documents which described the Up-grade path. Does anyone know whether I have to implement Stack 10 and Stack11, or I just implement only Stack 11 for Enterpirs

  • I have downloaded a movie which I brought from itunes. It appears in my ipod class movie menu but it won't playic

    I have downloaded a movie which I brought from itunes. It appears in my ipod classic movie menu but it won't play. I try to update and or restore my ipod but I just keep getting a message saying that I need to connect to the internet which I am and a