I can't open live script examples

조회 수: 16 (최근 30일)
Ekrem Onur Ozbisirici
Ekrem Onur Ozbisirici 2020년 1월 5일
댓글: Ekrem Onur Ozbisirici 2020년 1월 6일
Error using mkdir
Sistem belirtilen dosyayı bulamıyor.
Error in exampleUtils.setupWorkDir (line 4)
mkdir(workDir)
Error in setupExample (line 18)
exampleUtils.setupWorkDir(workDir);
Error in openExample (line 29)
I've got this error when i tried to open live script examples. When i clicked "view MATLAB command" button and following the instructions, gave me the error. One of the example is "Plan and Execute Task- and Joint-space Trajectories using KINOVA Gen3 Manipulator". How can i open and run this example on matlab? Is the example folder missing? If it is, how can i get the folder? And how can i insert the kinova robotic arm to matlab like the example shows?
I added a link the example which i wanna open. Can you help me,pls? It's so important and urgent for me.

채택된 답변

Walter Roberson
Walter Roberson 2020년 1월 6일
It appears to me that the code attempts to use "userpath" followed by Examples followed by your MATLAB release, followed by an example-specific directory name, and creates that directory if it does not exist. It appears to me that it is failing to create the directory.
One way that could happen is if your "userpath" does not exist. userpath is
% Windows: user's "Documents" folder appended with "MATLAB"
% Mac: user's "Documents" folder ($home/Documents) appended with "MATLAB"
% Linux: user's $home folder appended by "Documents" and "MATLAB"
You should check to see if that directory exists.
(On MS Windows systems in corporate environments, I have seen cases where the directory does not exist, when the user has been restricted to writing into network filesystem directories instead of local directories.)
In the meantime, there is a work-around:
openExample('robotics/PlanAndExecuteTaskAndJointSpaceTrajectoriesExample', 'workDir', 'NameOfDirectoryToUseForTheExample')
where 'workDir' is the literal string, and NameOfDirectoryToUseForTheExample should be replaced by the fully-qualified directory name to use . You should use a different directory name for each example.
  댓글 수: 3
Walter Roberson
Walter Roberson 2020년 1월 6일
That one works for me on my system.
I would suggest using
dbstop if error
and running until it stops, and then examine src and target to try to figure out what is going wrong.
Ekrem Onur Ozbisirici
Ekrem Onur Ozbisirici 2020년 1월 6일
That one works too, thank you!!

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

추가 답변 (0개)

카테고리

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

제품


릴리스

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by