1000 non virtual blocks exceeded

27 次查看(过去 30 天)
Shveta Dhamankar
Shveta Dhamankar 2019-8-12
回答: Song-Hyun Ji 2024-10-30,7:40
I get an error saying: 'Number of blocks in the block diagram 'IntegratedPlant' and all models it references exceeds the license limit of 1000 nonvirtual blocks'. This is despite me not using 1000 non virtual blocks.
length(find_system('IntegratedPlant', 'LookUnderMasks', 'on', 'FollowLinks', 'on'))
ans =
26

回答(2 个)

Roshni Garnayak
Roshni Garnayak 2019-8-23
If you notice, the error says: Number of blocks in the block diagram 'IntegratedPlant' and all models it references exceeds the license limit of 1000 nonvirtual blocks.”
You cannot use “find_system” command by itself to obtain the contents of a referenced model. Hence when you are using length(find_system())” you are subliminally discarding the contents of referenced models.
To understand the actual number of virtual blocks, a search is needed to be performed inside the referenced models also:
There are two possible workarounds that can be used to find the referenced models:
  • Use the “find_mdlrefs” command in conjunction with the “find_system” command. For example, to find the relational operator blocks inside all of the referenced models that have the relational operator property set to "==" in the demo model "sldemo_mdlref_basic":
[r, b] = find_mdlrefs('sldemo_mdlref_basic');
load_system(r{1})
rel_blks = find_system(r{1},'FindAll', 'on','BlockType','RelationalOperator','Operator','==')
Note: The last two commands can be used in a "for" loop if you have multiple referenced models.
  • A second possible workaround is to use the MATLAB file submitted in the following MATLAB File Exchange link:
Note that MathWorks does not guarantee or warrant the use or content of these submissions. Any questions, issues, or complaints should be directed to the contributing author.
I would also like to suggest about the sldiagnostics functionality. See this link:
Most of the checks done by “sldiagnostics” help you gather an understanding of the model as a whole. If you could take a look at the following Blog post:
http://blogs.mathworks.com/simulink/2009/08/11/how-many-blocks-are-in-that-model/, you can see that there is a function mdlrefCountBlocks  that you can make use of to find the contents of referenced models and how  many times each of these is referenced.
  1 个评论
Eric Bott
Eric Bott 2021-11-20
This problem is still there, not getting any better.
The overall effect of it is a moving goal post.
As the toolset has become more and more internally cross-dependent, the scope of what can be opened and worked on with limit of nodes is becoming less and less, with the result that there are now many working examples of systems of interest, given in the help files, which can't be opened with a student license, even maxed out with all the bells and whistles, coming to almost 700 dollars, we can't open those examples.
Frankly it feels like a very dishonest way of doing business, if you ask me, for this to only become apparent after splashing out on the toolset, to try to open an example, even one created previously by someone with a previous student license, to realise that just to open the examples, we need a toolset upgrade which is orders of magnitude greater, way out of the purchasing range of most individuals, and even most companies, certainly most universities.

请先登录,再进行评论。


Song-Hyun Ji
Song-Hyun Ji 2024-10-30,7:40
Please refer to the following answer.
- Why do I encounter the error stating I have exceeded the license limit of 1000 nonvirtual blocks?
https://www.mathworks.com/matlabcentral/answers/383805-why-do-i-encounter-the-error-stating-i-have-exceeded-the-license-limit-of-1000-nonvirtual-blocks

类别

Help CenterFile Exchange 中查找有关 Startup and Shutdown 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by