Convert Targetlink blocks to Simulink

27 ビュー (過去 30 日間)
Apurv Koregave
Apurv Koregave 2017 年 5 月 4 日
コメント済み: Amana 2024 年 11 月 26 日
Hello, I have been working with Targetlink blocks to build my models. However lately other departments who do not have Targetlink lisences want to convert these models in Simulink for Simulations. As the models are relatively big, it would take an enormous time to build these models again. I have been trying to find a solution where through an mfile we can convert the blocks. However due to lack of documentation, I haven't been able to come to a conclusion if it is possible. Is there a solution to convert these Targetlink blocks (most of which are simple math operations, ports, logic operators etc.) to their Simulink counterparts. Thank you in advance.
  1 件のコメント
Amana
Amana 2024 年 11 月 26 日
Did you solve this?

サインインしてコメントする。

回答 (2 件)

Daniel
Daniel 2018 年 10 月 18 日
Hi, is there a way to do this automatically for all TL blocks in a subsystem?
  2 件のコメント
Cuzuc Vlad-Andrei
Cuzuc Vlad-Andrei 2021 年 2 月 16 日
Hi Daniel :)
You can automatically Enhance all blocks in a subsystem like this:
BlocksToEnhance = tl_check_system('system',YourSubsystem); -> this will return a structure with all blocks checked by TargetLink.
BlocksToEnhance = BlocksToEnhance.hUnEnhBlocks; -> this will select you only the blocks you need that are not enhance
x = tl_enhance_block(BlocksToEnhance); -> with this you enhance all your blocks. If you don't use an output 'x' a prompt will appear every time. To avoid this you must assign an output to the function call (in this case x). The function will return an empty array if no error has occurred.
I hope this information helped you :)
Victor-Vladut Rusu
Victor-Vladut Rusu 2021 年 9 月 23 日
Sure did!

サインインしてコメントする。


Vishwanath Salokye
Vishwanath Salokye 2017 年 9 月 5 日
Hello Apurv Koregave There are many ways to convert TL to SL block. select all blocks, right click go to TargetLink and de-enhance TargetLink property. Write a script to read TL block properties and replace with SL block with same properties.

カテゴリ

Help Center および File ExchangeSimulink についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by