MATLAB Answers

Hi. when i am trying to Controlling Robot Motion in Simulink, getting following error. please suggest about it. thank you.

70 views (last 30 days)
Error in S-function 'MobileRobotSimulink1/Robot Simulator/Soft Real Time': S-Function 'sfun_time' does not exist
Component:Simulink | Category:Block error
error.png
  3 Comments
Adedotun Owojori
Adedotun Owojori on 4 Nov 2021 at 5:34
Please i am still getting this error after deleting the soft realtime block
  • The "FixedStepDiscrete" solver cannot be used to simulate block diagram 'untitledfcn' because it contains continuous states
Component:Simulink | Category:Block diagram error
and also after converting to a variable solver, i got this error
Caused by:
  • Changing property 'SolverType' is not allowed
Component:Simulink | Category:Block error
kindly assist, thanks
Dotun

Sign in to comment.

Accepted Answer

MathWorks Student Competitions Team
Edited: MathWorks Student Competitions Team on 12 Nov 2019
This error usually occurs when you don't run the file "installMRTToolbox" included in the training files. This should be on the main directory for the submission here:
You will need a compiler to compile the s-funciton for the block and then everything should work. This is prompted when the install file is executed.
Alternatively, if you are using MATLAB R2018a or newer you can delete the block form the library and use Simulation pacing instead. To do this:
  1. Right-click the Robot Simulator and select Library Link>Go to library block
  2. Unlock the library by clicking the lock on the bottom left corner
  3. Right-click the Robot Simulator block in the library and select Mask>Look under mask
  4. Delete the "Soft Real Time" block
  5. Save the library
You can enable Simulation Pacing from the run button. This will slow down the simulation to real-time speed.
Find here more details on simulation pacing:
  6 Comments
Adedotun Owojori
Adedotun Owojori on 4 Nov 2021 at 5:22
Please i am still getting this error after deleting the soft realtime block
  • The "FixedStepDiscrete" solver cannot be used to simulate block diagram 'untitledfcn' because it contains continuous states
Component:Simulink | Category:Block diagram error
and also after converting to a variable solver, i got this error
Caused by:
  • Changing property 'SolverType' is not allowed
Component:Simulink | Category:Block error
kindly assist, thanks
Dotun

Sign in to comment.

More Answers (0)

Products


Release

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by