OPC configuration error: cannot get server list. Operation returned"Null Pointer"

7 visualizzazioni (ultimi 30 giorni)
Matlab version 2012a. I opened a simulink model on my new windows 7 X64 computer. When I configurate the 'OPC configuration' block, the ERROR "IOPCCommon: class not registered" occurred. The OPC server was created by "CoDeSys OPC configurator"(CoDeSys is the programming software for ABB PLC). The OPC client test software "SOClient.exe" succed in connecting to the OPC server and so does one Chinese upper computer software "KingView". The Simulink model functions well on my old computer, with Windows 7 X32, Matlab 2012a. Then I try to creat a new model and add a new OPC server, an ERROR "can not get server list.Operation returned 'Null Pointer'" occurred.
Can someone tell me how to solve it? Thanks a lot.

Risposte (2)

Muhammad
Muhammad il 25 Nov 2014
I received the same error while trying to communicate MATLAB with WAGO PLC using KepServer. I have solved this problem by first initializing the OPC toolBox.
You have to write the following command in the workspace.
opcregister
After that, my problem is solved and server created on my laptop was picked up by OPC Configuration function block

Michal Zielinski
Michal Zielinski il 8 Nov 2015
Hi, I have the same error (OPC Configuration Error). Command opcregister didn't help (opcreset, opcregister('repair') also) Could anybode help me?
thx

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by