How come I can't interrupt a function execution immediately using Ctrl+C ?
7 views (last 30 days)
Show older comments
Hi,
I'm using modbus function and when I initiate a connection with a bad IP address, I get an error as expected but it takes 15 seconds each time and there is no way to interrupt it faster, not even with Ctrl+C. I dug into modbus function and found a private method simply called 'connect'. The delay is all here and there's no timeout parameter. Is there a way to change its timeout parameter so it waits 2 seconds instead or at least interrupt its execution?
Thanks.
0 Comments
Answers (1)
Kirthi
on 9 Feb 2023
Hello Alexandre,
I can answer your issue of Ctrl+C not working.
Go to Model settings => Simulation Target => Advanced parameters. Now check if the 'Break on Ctrl-C' option is enabled or not.
Break on Ctrl+C will not work if this option isn't checked.
Hope this helps !
2 Comments
Kirthi
on 14 Feb 2023
Hi Alexandre,
I understand your concern but there is no way you can change the time delay in execution of "modbus" function. However, we might consider resolving this in our future releases.
Thank you.
See Also
Categories
Find more on Introduction to Installation and Licensing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!