Clear Filters
Clear Filters

OPC configuration block reports no OPC servers

7 views (last 30 days)
Hi,
I'm writing this post because I tried every possible option shown in the support. I was trying to estabilish a connection on my localhost between the program CODESYS and Simulink, wich is supposed to read some values from the server I created using CODESYS. When I try to configure a client by clicking "configure OPC clients" --> " add... " --> "select... " a warning is shown:
" Host 'localhost' reports no OPC servers "
I think this is very strange, because I succeded (using the command window) to connect to the same server previously mentioned and even read the variables I needed!
Is there any way to know what I should type inside the textbox to bypass the Simulink automatic local inspection?
Alternatively how can I solve the problem?
I tried to re-register OPC foundation core components and to configure properly DCOM. To be honest, I'm beginning to think that there's no solution :(
Thank you for your help!

Answers (1)

Yatharth
Yatharth on 6 May 2024
Hi,
It's important to prior to MATLAB R2024a, MATLAB does not extend support for OPC UA blocks within Simulink. Consequently, the OPC Read block that is available in these versions is designed exclusively for connections to OPC DA servers. This is the underlying reason for the challenges you are facing in connecting to an OPC UA server.
Starting with R2024a, the Industrial Communication Toolbox has introduced support for OPC UA Servers in Simulink, using OPC UA Read and Write Blocks.

Community Treasure Hunt

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

Start Hunting!