Difference between revisions of "Algorithms and Data Structures"
(Created page with "ThIs guide provides a step-by-step guide to downloading, installing, and checking the software required to develop DREAM software and write and run DREAM robot applications....") |
|||
Line 1: | Line 1: | ||
− | ThIs guide provides a step-by-step guide to downloading, installing, and checking the software required to | + | ThIs guide provides a step-by-step guide to downloading, installing, and checking the software required to submit an assignment for the Algorithms and Data Structures course |
== Operating System == | == Operating System == | ||
− | + | I assume you are running Windows 7. | |
== C/C++ Compiler == | == C/C++ Compiler == | ||
− | Download the Microsoft Visual C++ Express compiler, version 10.0 (also known as Visual C++ 2010). It is important to use this version; earlier versions are no longer supported by Microsoft and later versions cause problems with | + | Download the Microsoft Visual C++ Express compiler, version 10.0 (also known as Visual C++ 2010). It is important to use this version; earlier versions are no longer supported by Microsoft and later versions cause problems with some libraries. |
− | + | ||
− | + | ||
You can download the required compiler from [http://www.visualstudio.com/downloads/download-visual-studio-vs here]. | You can download the required compiler from [http://www.visualstudio.com/downloads/download-visual-studio-vs here]. | ||
Line 16: | Line 14: | ||
Once the compiler is installed, try compiling a simple program. Some versions of Windows 7 may need the the Microsoft Visual Studio 2010 Service Pack 1 to be installed. If you get an error trying to compile and run a simple program, this may be the problem. CMake (see below) will also fail in this case. | Once the compiler is installed, try compiling a simple program. Some versions of Windows 7 may need the the Microsoft Visual Studio 2010 Service Pack 1 to be installed. If you get an error trying to compile and run a simple program, this may be the problem. CMake (see below) will also fail in this case. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== CMake == | == CMake == | ||
Line 30: | Line 21: | ||
You can opt for either the WIN32 installer or the Windows zip file. The installer has the advantage that it gives you the option to update your system path automatically (which you should take by clicking the appropriate radio button during the installation process). | You can opt for either the WIN32 installer or the Windows zip file. The installer has the advantage that it gives you the option to update your system path automatically (which you should take by clicking the appropriate radio button during the installation process). | ||
− | == | + | == ADS Repository == |
− | + | Copy the full ADS repository to the <code>C:</code> drive. You can download a zip file from [http://www.vernon.eu/ADS.zip here]. | |
− | + | Copy it to <code>C:</code> drive and unzip it so that you have a directory called <code>C:\ADS</code> with a sub-directory structure explained in class. | |
− | + | The next step is to build a MSVC++ <code>.sln</code> solution file so that you can compile all the ADS executables. To do this, you need to run CMake against the <code>C:ADS\assignment</code> directory (where you will find the main <code>CMakeLists.txt</code> file) | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | The next step is to build a MSVC++ <code>.sln</code> solution file so that you can compile all the | + | |
* Launch the CMake GUI from the Windows 7 toolbar. | * Launch the CMake GUI from the Windows 7 toolbar. | ||
− | * In the ''Where is the source code:'' input (browse to) <code>C:\ | + | * In the ''Where is the source code:'' input (browse to) <code>C:\ADS\assignment</code> |
− | * In the ''Where to build the binaries:'' input (browse to) <code>C:\ | + | * In the ''Where to build the binaries:'' input (browse to) <code>C:\ADS\assignment\build</code> |
− | * Select ''File > Delete Cache'' from the top menu (you '''must''' do this the first time in case there is an old invalid configuration in the | + | * Select ''File > Delete Cache'' from the top menu (you '''must''' do this the first time in case there is an old invalid configuration in the ADS directory) |
* Click ''Configure'' | * Click ''Configure'' | ||
Line 69: | Line 45: | ||
* Click ''Configure'' again and everything should be fine (unless you have forgotten to download and install OpenCV, in which case you will get an error and you will have install OpenCV and start this process again) | * Click ''Configure'' again and everything should be fine (unless you have forgotten to download and install OpenCV, in which case you will get an error and you will have install OpenCV and start this process again) | ||
− | * Click ''Generate'' to create the MSVC++ <code> | + | * Click ''Generate'' to create the MSVC++ <code>assignment.sln</code> file in <code>C:\ADS\Assignment\build</code> |
− | + | Now you are ready to launch MSVC++ and build the ADS executables. | |
− | * | + | * Go to the <code>C:\ADS\release\build</code> directory and open the <code>Assignment.sln</code> file. This launches Microsoft Visual C++ 2010 Express. |
− | + | * Select <code>Release</code> in the ''Solutions Configuration'' box. | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | * Select <code>Release</code> in the ''Solutions Configuration'' box | + | |
* Select ''Build > Build Solution'' from the top menu, (if you don't see this and you see ''Debug > Build Solution'' instead, it's probably because your IDE is set to basic settings. To change this, select ''Tools > Settings > Expert Settings''). | * Select ''Build > Build Solution'' from the top menu, (if you don't see this and you see ''Debug > Build Solution'' instead, it's probably because your IDE is set to basic settings. To change this, select ''Tools > Settings > Expert Settings''). | ||
− | This will compile and link the | + | This will compile and link the programs in the the <code>C:\ADS\assignment\bin</code> sub-directory. Check to see that both component executables are there. If they are not, build the solution again. |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | You are now ready to run the Vernon application and to begin developing your own assignment programs. | |
− | [[ | + | To run the test application for the <code>Vernon</code> example that is provided with the ADS release, double click the [[Vernon]] executable in <code>C:\ADS\assignment\bin</code>. |
Revision as of 13:58, 19 September 2014
ThIs guide provides a step-by-step guide to downloading, installing, and checking the software required to submit an assignment for the Algorithms and Data Structures course
Operating System
I assume you are running Windows 7.
C/C++ Compiler
Download the Microsoft Visual C++ Express compiler, version 10.0 (also known as Visual C++ 2010). It is important to use this version; earlier versions are no longer supported by Microsoft and later versions cause problems with some libraries.
You can download the required compiler from here.
Run the installer and follow the instructions.
Once the compiler is installed, try compiling a simple program. Some versions of Windows 7 may need the the Microsoft Visual Studio 2010 Service Pack 1 to be installed. If you get an error trying to compile and run a simple program, this may be the problem. CMake (see below) will also fail in this case.
CMake
Download CMake binaries from here.
You can opt for either the WIN32 installer or the Windows zip file. The installer has the advantage that it gives you the option to update your system path automatically (which you should take by clicking the appropriate radio button during the installation process).
ADS Repository
Copy the full ADS repository to the C:
drive. You can download a zip file from here.
Copy it to C:
drive and unzip it so that you have a directory called C:\ADS
with a sub-directory structure explained in class.
The next step is to build a MSVC++ .sln
solution file so that you can compile all the ADS executables. To do this, you need to run CMake against the C:ADS\assignment
directory (where you will find the main CMakeLists.txt
file)
- Launch the CMake GUI from the Windows 7 toolbar.
- In the Where is the source code: input (browse to)
C:\ADS\assignment
- In the Where to build the binaries: input (browse to)
C:\ADS\assignment\build
- Select File > Delete Cache from the top menu (you must do this the first time in case there is an old invalid configuration in the ADS directory)
- Click Configure
- Select Visual Studio 10 (2010) from the drop-down menu as the generator for the project
- Click Finish and watch CMake configure your project. The dialogue box will still highlighted in red so ...
- Click Configure again and everything should be fine (unless you have forgotten to download and install OpenCV, in which case you will get an error and you will have install OpenCV and start this process again)
- Click Generate to create the MSVC++
assignment.sln
file inC:\ADS\Assignment\build
Now you are ready to launch MSVC++ and build the ADS executables.
- Go to the
C:\ADS\release\build
directory and open theAssignment.sln
file. This launches Microsoft Visual C++ 2010 Express.
- Select
Release
in the Solutions Configuration box.
- Select Build > Build Solution from the top menu, (if you don't see this and you see Debug > Build Solution instead, it's probably because your IDE is set to basic settings. To change this, select Tools > Settings > Expert Settings).
This will compile and link the programs in the the C:\ADS\assignment\bin
sub-directory. Check to see that both component executables are there. If they are not, build the solution again.
You are now ready to run the Vernon application and to begin developing your own assignment programs.
To run the test application for the Vernon
example that is provided with the ADS release, double click the Vernon executable in C:\ADS\assignment\bin
.