Error using PurePersuit Block in Simulink Model
2 views (last 30 days)
Show older comments
Hello there,
I've got a Simulink model where I use the Pure Pursuit (PP) algorithm to control a vehicle's lateral dynamics. When I use this controller with a constant "desired velocity," everything works as expected. When I use an additional PID controller to insert the desired velocity into the PP block, I receive this error:
"Error: An error occurred during simulation and the simulation was terminated
Caused by:
A runtime error occurred in the System object 'nav.slalgs.internal.PurePursuit' in MATLAB System block 'PP_MKS_Controller/Subsystem/Subsystem1/PID Längs PP Quer/Pure Pursuit', while executing the 'stepImpl' method.
Expected DesiredLinearVelocity to be nonnegative.
Error in validatenonnegative.m (line 14):
'ReportedID', getReportedID(funcname, 'expectedNonnegative'), ...
Error in validateattributes.m (line 93)
Error in PurePursuitBase.m (line 125)"
I've checked the velocity signal, which is never < 0, and also tried taking the absolute values of the signal just to see if it works this way. I'm not quite sure where the problem actually lies.
Thanks in advance for your support and kind regards,
Danus
2 Comments
Venkatesh BalaSubburaman
on 18 Feb 2025
Hi Danus,
Can you share a simple model that reproduces the error. I am unable to reproduce the issue at my end. Please also mention the MATLAB Release and other details that can help to debug the issue.
Thanks
Answers (0)
See Also
Categories
Find more on PCM 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!