Automated unit testing for automation
I have a project in Control Builder M, I can download it to Soft Controller and run it. I have another application running a MATLAB model against the OPC and interacting with my control program. When we're done with a single run, we restart the Soft controller and download the program again - so that we can run different scenario. We need to somehow automate the process of bringin the soft controller to time=0. Is there any way how to do this in non-manual way from 3-rd party application? Anything will do, run some utility, write something somewhere, call Control Builder executable with some parameter, anything.
I know it is possible to control CBM via COM Interface, just see the "Control Builder 2.0 Type Library" COM Reference. On the CBOpenIF Object, you can find e.g.
"Function DownloadAndGoOnline(isOnline As Boolean) As String" which should allow you to automatically Download a program to SoftController.
I guess there is a way to access COM from MATLAB but i don't have experience with that.
The missing link is how to restart the SoftController - i don't know how that is done, however there is a App here "SoftController Administrator" which says it can start/stop SoftControllers so that should be possible as well.
I am also interested in doing something similar to your idea so would be nice if you could share your experience - are you using MATLAB OPC Toolbox to access the Control Program?