1- % Copyright 2022-2023 Peter Corke, Witold Jachimczyk, Remo Pillat
2-
3- function rvccheck()
4-
5- % this function is a help to users, and those providing help in forums to understand
6- % the users environment. Peter's experience is that a mix of toolboxes and path issues
7- % is the root cause of a lot of problems.
8-
9- % Checking installation for RVC3 toolbox
10-
11- % report version of MATLAB
12- % warning if version is too old
13-
14- % check for presence of RST, CVST and other required MW toolboxes
15- % error if key ones are missing
16- % warning if some functionality might be lost, ie. The toolboxes required for Part III are not present, you need ....
17-
18- % check for presence of RTB, MVTB, SMTB
19- % it looks like you have the older MATLAB toolboxes installed...
20-
21- % check for shadowing, or which toolboxes are first in the path
22- % it looks like some older toolboxes are shadowing this toolbox, do you want to automatically fix your MATLAB path...
1+ function rvccheck
2+ % RVCCHECK Check MATLAB environment for running RVC3 Toolbox
3+ % This function is a help to users, and those providing help in forums to
4+ % understand the user's environment. Peter's experience is that a mix of
5+ % toolboxes and path issues is the root cause of a lot of problems.
6+ %
7+ % This function does the following:
8+ % - Warns if version of MATLAB is too old (< R2023a)
9+ % - Checks for presence of required MathWorks toolboxes: Robotics System
10+ % Toolbox, Navigation Toolbox, Image Processing Toolbox, and Computer
11+ % Vision Toolbox. Warn if key ones are missing.
12+ % - Checks for presence of RTB, MVTB, SMTB
13+ % It looks like you have the older MATLAB toolboxes installed...
14+
15+ % Copyright 2022-2024 Peter Corke, Witold Jachimczyk, Remo Pillat
2316
2417 %% check MATLAB version
2518 fprintf(" rvccheck for RVC3 Toolbox\n" )
26- if verLessThan(" matlab" , " 9.14" )
27- fprintf(" You have MATLAB release %s, at least (R2023a) is required\n" , ...
28- ver(" matlab" ).Release);
19+ fprintf(" Checking for MATLAB version: %s Update %d.\n" , matlabRelease .Release , matlabRelease .Update )
20+ if isMATLABReleaseOlderThan(" R2023a" )
21+ fprintf(" - You have MATLAB release (%s), but at least (R2023a) is required\n" , ...
22+ matlabRelease .Release );
2923 end
3024
3125 %% check that required toolboxes are present
3226
3327 required_toolboxes = [
3428 " Robotics System Toolbox" , " robotics" , " Chapters 2-9"
35- " Navigation Toolbox" , " navigation " , " Chapter 5"
29+ " Navigation Toolbox" , " nav " , " Chapter 5"
3630 " Image Processing Toolbox" , " images" , " Chapters 10-15"
3731 " Computer Vision Toolbox" , " vision" , " Chapters 11-15"
3832 ];
3933
4034 if ~isempty(required_toolboxes )
41- fprintf(" Some required Toolboxes are not installed: \n" )
35+ fprintf(" Checking that required Toolboxes are installed. \n" )
4236 for rt = required_toolboxes '
4337 full = rt(1 ); short = rt(2 ); comment = rt(3 );
4438 v = ver(short );
4539 if isempty(v )
46- fprintf(" %s is required for %s\n" , full , comment );
40+ fprintf(" - %s is required for %s and not installed. \n" , full , comment );
4741 end
4842 end
4943 end
5044
5145 %% check for other toolboxes
52-
46+ fprintf( " Checking for the presence of older Toolboxes.\n " )
5347 p = which(' trotx' );
5448
5549 if ~isempty(p )
56- fprintf(" You have Peter Corke's Robotics and/or Spatial Math Toolbox in your path\n" )
50+ fprintf(" - You have Peter Corke's Robotics and/or Spatial Math Toolbox in your path\n" )
5751 end
5852
5953 shadows = [];
6054 shadows = checkshadow(shadows , " Camera" );
6155 if ~isempty(shadows )
62- fprintf(" You have Peter Corke's Machine Vision Toolbox shadowing the RVC3 Toolbox, please remove the former from your path\n" );
56+ fprintf(" - You have Peter Corke's Machine Vision Toolbox shadowing the RVC3 Toolbox, please remove the former from your path\n" );
6357 end
6458
6559
@@ -77,10 +71,3 @@ function rvccheck()
7771 out = [out ; {funcname , which(funcname )}];
7872 end
7973end
80-
81- function p = getpath(funcname )
82- funcpath = which(funcname );
83- k = strfind( funcpath , [filesep funcname ]);
84- p = funcpath(1 : k - 1 );
85- end
86-
0 commit comments