COPC32 activeX control used for SCADA creation and advancement. You can create SCADA system (Graphic keeping an eye on & & control, Trending, Alarm system, and a lot more. )within your favorite programming IDE such as Aesthetic Standard 6.0, Aesthetic Studio.Net (VB.Net, C#),
and also VBA (MS Excel, Word, & hellip;-RRB-. COPC32 1.7 complete description COPC32 activeX control used for SCADA production and also advancement. You can create SCADA system (Graphic checking & & control, Trending, Alarm, and also a lot more.) within your favorite programming IDE such as Aesthetic Standard 6.0, Visual Studio.Net (VB.Net, C#), and also VBA (MS Excel, Word, & hellip;-RRB-. COPC32 Path version will certainly stop working after a hr. You need to restart program to run it again.
This instance demonstrates how to logging OPC information in to MS SQL Server 2014 Express utilizing COPC32 and Aesthetic Workshop 2015 Express.
- MS SQL Web Server/ MS SQL Server Express
- Aesthetic Workshop 2015 Express (download right here)
- COPC32 (it is not cost-free, download and install test here). And you need to installing COPC32.
- OPC Web server
My data source name and table’& rsquo; s column shown “below. & ldquo; id & rdquo; column is vehicle increment.by link COPC32 Download website
MS SQL Web server, instance name shown. It is MS SQL Web Server on exact same COMPUTER of my Visual Studio. Then I can use “& ldquo; (neighborhood)& rdquo; as recommendation name in script. If your circumstances name is something like “& ldquo; ACER \ SQLEXPRESS & rdquo;, then you could make use of & ldquo;(
neighborhood)\ SQLEXPRESS & rdquo;. Download and install OPC Data logging instance
project(135kb)Open up downloaded project as well as make sure you have insert COPC32 control on Tool kit of Visual Workshop.
3 tag utilized 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 residential property page.
Along with OPC tags.
In Timer2’& rsquo; s code, getting OPC information right into global variable v( 0) to v( 2) (see downloaded and install instance code, will certainly see international variable stated). As well as also show information on labels.
Exclusive Sub Timer2_Tick(sender As Item, e As EventArgs) Handles Timer2.Tick
For i = 0 To 2
v(i) = Axcopc1.GetVl(i)
Label1.Text = v( 0 ). ToString()
Label2.Text = v( 1 ). ToString()
Label3.Text = v( 2 ). ToString()
I have use shell to call SQLCMD.exe with SQL command to insert OPC data in to MS SQL table.
Personal Below Timer1_Tick(sender As Things, e As EventArgs) Manages Timer1.Tick
Shell(“& ldquo; C: \ Program Data \ Microsoft SQL Web Server \ Customer SDK \ ODBC \ 110 \ Devices \ Binn \ SQLCMD.exe -S (local) -d test -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=Server Name “(Please keep in mind that if your SQL Server has & ldquo; \ SQLEXPRESS & rdquo; after computer name after that you require to use (local)\ SQLEXPRESS ), –– d = Database Name, –– Q = SQL query/command. Example over use SQL Insert command to put v( 0 ), v( 1 ), v( 2) as well as current date time into table t1 at relevant column.
You have to examining course of SQLCMD.exe in your system and change to over script.
After running project, OPC information logged right into MS sQL Web server.