Error in Simulink.messageviewer.internal.MsgIdToDataMap/addRecord - Caused by: Maximum recursion limit of 500 reached.
4 次查看(过去 30 天)
显示 更早的评论
Hello, I have recieved the following error message:
"Error in Simulink.messageviewer.internal.MsgIdToDataMap/addRecord
Caused by: Maximum recursion limit of 500 reached."
Or I will also (for no reason I have figured out yet) recieve
"Warning: The following error was caught while executing 'slmsgviewer' class destructor: Maximum recursion limit of 500 reached.
Error in slmsgviewer
Caused by: Maximum recursion limit of 500 reached. "
in mass on my command prompt. This occurs when I open a simulink file that has a distribution system (power system) set up. I am not running any simulations or anything yet I am simply opening the file.
I cannot find information on how this could trigger a maximum recursion limit from opening a simulink/simscape power systems file or where/what the Simulink.messageviewer.internal.MsgIdToDataMap/addRecord' is.
I have:
1) changed the blocks which are put in the system so that I know its not an issue with callbacks or initialization in the masking
2) commented out code which initializes the block parameters from the code (File is initially populated with blocks from code)
3) deleted sections of blocks to find if is a specific problem with one (its not at about 20/50 blocks the error message stops but it doesnt matter which blocks are deleted)
I do not have the first idea about what I am dealing with and despite many hours searching google, Matlab Wiki and even youtube.
The only solutions I have seen so far make no mention of this happening in a simulink/simscape file and usually advise to just increase the recursion limit. I would like to know what the issue is though to properly solve it. Any information on this will be greatly appreciated.
Thank you for your time.
1 个评论
Pedro Beires
2018-8-17
Ok the same thing happened to me, also building a distribution power system. I had not run any simulations yet. No solutions yet.
As it occured: I had the .slx opened, specifically an RLC Load Mask opened. I was going to initialize local variables via script, variables which are called by the Simulink model. I caused an error running the script because I had changed the script filename via Windows Explorer, closed and reopened the script and ran it to initalize the variables. I'm quite certain I got the first crash at that point. Afterwards, after restarting MATLAB and restarting the PC, I get the described error trying to open the Simulink file.
回答(3 个)
Jan
2018-10-1
Hello, I have had the same error while creating a distribution system with simulink. I fixed the problem by creating a new empty simulink model. I have copied the distribution system (all elements) into the new model. So far the error has not recurred in the new model.
0 个评论
VraelEnrique
2020-1-27
Did you guys could find a solution to this problem? I have the same issue and i don´t get the solution to it /:
0 个评论
Shubhranshu Kumar Tiwary
2022-12-10
I had answered this question before, from a different account with same name (which is about to be deactivated within a week, since I switched institutes)
Before opening the model, run the following code in the command prompt >> set(0,'RecursionLimit',5000)
Then try opening the model, the error will not show. I got this answer from consumer support for my license.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulink Environment Customization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!