Solved

VB.NET OPC READ to slow...

Posted on 2011-09-19
8
537 Views
Last Modified: 2012-05-12
Hi...
I need som tips..
I use the " Imports OPCAutomation "
The read and write works verry good but it takes to long time..
about 5 sec for every tagg..

I just made som code to show how I use it...

 

        Dim tagggg(50) As OPCItem
        Dim i As Integer = 1
 
       For i = 1 To 30
            tagggg(i) = plcReadTest1Group.OPCItems.Item(i)
           tagggg(i).Read(OPCAutomation.OPCDataSource.OPCDevice)    ' <---- This line takes about 5 sec...
            MainForm.resultat(i) = "'" + tagggg(i).Value.ToString() + "'"
        Next i
I hope somone have som tips how I can fix this.. can i read from other way?

Please ask me if my question isen´t clear....



0
Comment
Question by:kavvis
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 2
8 Comments
 
LVL 15

Expert Comment

by:Minh Võ Công
ID: 36559138
You can use thread to retrive data
0
 

Author Comment

by:kavvis
ID: 36559156
Hi, I´m pretty new as this can you explain some more?

Maybe show me some example...  What will this thread to?
0
 

Author Comment

by:kavvis
ID: 36559178
Hi upload a picture abput the "Read" function.. maybe somone can se somthing I have mist...

I only intressted in .Value
Read.JPG
0
PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

 
LVL 15

Accepted Solution

by:
Minh Võ Công earned 500 total points
ID: 36559186
0
 

Author Comment

by:kavvis
ID: 36559354
Ok, So you belive that if a manage to do this to a threed just this sub then I should be faster?
0
 

Author Comment

by:kavvis
ID: 36560320
Maybe I can make only one read from the OPC..  like I read a array... and then sort the data..

Have anyone done a Array read from a OPC-Server?
0
 

Author Comment

by:kavvis
ID: 36565715
I still haven´t found any solution to this... some more tips please...
0
 

Author Closing Comment

by:kavvis
ID: 36990894
thank you for you took your time..
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Summary Displaying images in RichTextBox is a common requirement with limited solutions available. Pasting through clipboard or embedding into RTF content only support static images.  This article describes how to insert Windows control objects int…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question