For this program to run, you will need to download Kepserver found at http://www.kepware.com/Products/products_OPCServers.asp
After you have download and installed the KepServer, use the demo.opf file included in the OPC.zip as the default project in Kepserver.
Then run the opc_demo.m file, you will see how Matlab as an OPC Client communicates with this OPC server.
You can try different servers as well, such as Matrikon, Iconics, etc, but you will have to create your own server configuration files.
Next you can try connecting any PLC which are supported by Kepserver and try out PLC communication through Matlab.
There is also an inbuilt OPC Client in Kepserver which will reflect the same results as on this program.
The boolean output i.e the RED/GREEN toggle button o/p can be viewed on the OPC Client of Kepserver