Filter löschen
Filter löschen

Why simulink simulation stop takes so long?

4 Ansichten (letzte 30 Tage)
VaL V6
VaL V6 am 22 Sep. 2023
Kommentiert: VaL V6 am 5 Okt. 2023
I'm developing a Simulink Model that communicates with a Beckhoff PLC for SIL simulation.
To interface the PLC I'm currently use the Beckhoff package developed for Simulink, TE1410 (TE1410 | TwinCAT 3 Interface for MATLAB®/Simulink® | Beckhoff Worldwide). In partciluar, I'm using the "TC Symbol Interface" block. To manage the sample time of the Simulink simulation, it includes the "Real-Time Synconization" block.
The simulation starts and runs very well. No issues. The problem arises when I want to stop it.
The simulation stop takes at least 5 minutes but often I had to terminate matlab from the task manager.
Any advise? Some point that I'm missing?
I already started a thread with Beckhoff support service for additional information.

Antworten (1)

UDAYA PEDDIRAJU
UDAYA PEDDIRAJU am 29 Sep. 2023
Hi Val,
I understand the problem, the delay in stopping the Simulink simulation could be due to the complexity of your model, the communication with the “PLC”, or the real-time synchronization settings. Here are some suggestions which could help in reducing the time taken during simulation:
  1. Optimize Your Model: If your model is complex, try simplifying it or optimizing the calculations and data exchanges.
  2. Check Your “PLC” Communication: Ensure that the communication between Simulink and your “Beckhoff PLC” is functioning optimally.
  3. Adjust Real-Time Synchronization Settings: Try tweaking the settings of your “Real-Time Synchronization” block.
Best,
Uday
  1 Kommentar
VaL V6
VaL V6 am 5 Okt. 2023
Hello Uday,
thank you for your answer.
I definetly find out that the problem is introduced by the Beckhoff communication blocks. In fact, if I comment out these blocks, I run an internal simulation and control the simulator by using the Simulink dashboard, the stop is instantaneous.
I'm wainting for feedback from Beckhoff. If some news will come out, I'll give an update to the community.
Best,
Valerio

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Model Preparation finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by