Develop OPC Data Logger with COPC32 and Aesthetic Studio 2015 Express

Methods for fulfilling an on-line Connection face-to-face
December 2, 2020
I go to Jail if I don’t Pay My Payday Loan Will?
December 2, 2020

Develop OPC Data Logger with COPC32 and Aesthetic Studio 2015 Express

COPC32 activeX control utilized for SCADA creation and also growth. You can produce SCADA system (Graphic monitoring & & control, Trending, Alarm system, as well as much more. )within your favorite programs IDE such as Visual Basic 6.0, Aesthetic Studio.Net (VB.Net, C#),

as well as VBA (MS Excel, Word, & hellip;-RRB-. COPC32 1.7 full summary COPC32 activeX control made use of for SCADA production and development. You can create SCADA system (Graphic checking & & control, Trending, Alarm system, and much more.) within your favored programming IDE such as Aesthetic Fundamental 6.0, Visual Studio.Net (VB.Net, C#), and VBA (MS Excel, Word, & hellip;-RRB-. COPC32 Path version will quit working after an hour. You have to restart program to run it once again.

This instance shows how to logging OPC information in to MS SQL Web server 2014 Express using COPC32 and Visual Workshop 2015 Express.

Demands

  • MS SQL Server/ MS SQL Web Server Express
  • Aesthetic Workshop 2015 Express (download below)
  • COPC32 (it is not complimentary, download and install test below). And also you have to setting up COPC32.
  • OPC Server

My data source name and also table’& rsquo; s column revealed “listed below. & ldquo; id & rdquo; column is car increment.Read about COPC32 free download At website

MS SQL Server, circumstances name shown. It is MS SQL Server on very same COMPUTER of my Visual Studio. Then I can use “& ldquo; (neighborhood)& rdquo; as reference name in manuscript. If your instance name is something like “& ldquo; ACER \ SQLEXPRESS & rdquo;, after that you might use & ldquo;(

neighborhood)\ SQLEXPRESS & rdquo;. Download OPC Information logging instance

task(135kb)Open downloaded project and also ensure you have insert COPC32 control on Tool kit of Visual Workshop.

3 label made use of to show OPC tags value with Timer2 every 1 sec. Timer1 has logging manuscript functioning every 5 sec.

Specify OPC Server on COPC32 ‘& lsquo; s property page.

In addition to OPC tags.

In Timer2’& rsquo; s code, obtaining OPC information right into global variable v( 0) to v( 2) (see downloaded example code, will certainly see international variable declared). As well as also show data on tags.

Exclusive Sub Timer2_Tick(sender As Things, e As EventArgs) Takes Care Of Timer2.Tick
For i = 0 To 2
v(i) = Axcopc1.GetVl(i)
Following

Label1.Text = v( 0 ). ToString()
Label2.Text = v( 1 ). ToString()
Label3.Text = v( 2 ). ToString()
End Below

I have usage covering to call SQLCMD.exe with SQL command to place OPC information in to MS SQL table.

Exclusive Below Timer1_Tick(sender As Things, e As EventArgs) Deals With Timer1.Tick
Covering(“& ldquo; C: \ Program Data \ Microsoft SQL Server \ Customer SDK \ ODBC \ 110 \ Tools \ Binn \ SQLCMD.exe -S (regional) -d examination -Q “”& ldquo; & rdquo; insert into t1(v1, v2, v3, Time_Date) values (” & & rdquo; & & v(0) “& & ldquo; “, & rdquo;””& v(1)& & ldquo;, & rdquo; &

v(2) & & ldquo;, getdate ())& rdquo; & rdquo; & rdquo;-RRB- End Sub When argumment– S=Web Server Call “(Please keep in mind that if your SQL Server has & ldquo; \ SQLEXPRESS & rdquo; after computer name then you require to make use of (neighborhood)\ SQLEXPRESS ), –– d = Database Name, –– Q = SQL query/command. Example above use SQL Insert command to put v( 0 ), v( 1 ), v( 2) as well as current date time right into table t1 at related column.

You need to examining course of SQLCMD.exe in your system as well as replace to over manuscript.

After running job, OPC data logged right into MS sQL Server.