undefined function or variable error in matlab simulink?

조회 수: 3 (최근 30일)
Najmeh Eskandari
Najmeh Eskandari 2018년 8월 9일
답변: Ameer Hamza 2018년 8월 10일
hi.i want to simulate ur10 kinematic(inverse and forward) but when I run I have these errors(screenshot which is attached). the function name or path are correct. i run the trajectory planning block and have all 6 Theta at the output.
  댓글 수: 9
Ameer Hamza
Ameer Hamza 2018년 8월 10일
It will be easier to suggest a solution if you can attach the model files as zip file.

댓글을 달려면 로그인하십시오.

채택된 답변

Ameer Hamza
Ameer Hamza 2018년 8월 10일
There are some typing mistakes in ur10_forward_kinematic(). For example in the input list the variable name is Theta2, whereas in the code you are using Theta_2. You need to use the same name in both places. Also on line 39, you are using p06 whereas the actual name is P06 remember the variable names are case sensitive.
The file ur10_inverse_kinematic() contains some more involved problems. For example, at the beginning of your code you are using Theta1, Theta2, ... Theta6 but their values are not defined. You are not giving their values as function input neither defining inside the function. MATLAB has no way of knowing what values to take when the function run.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Block Libraries에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by