2021/11/1 下午8:06 Project Software Install Instructions: ELEC1601/ELEC9601 Introduction to Computer Systems
https://canvas.sydney.edu.au/courses/35882/pages/project-software-install-instructions 1/3
Project Software Install Instructions
Details
The software project template was written in Codeblocks with SDL2 in an attempt to make it
somewhat platform independent. However, you can use your own IDE if you prefer.
It was based on this code: https://github.com/gmartsenkov/snake-SDL2
(https://github.com/gmartsenkov/snake-SDL2) (random google search to find it). (acknowledging
source. You can download/install/play this game if you wish!)
The full installation instructions can be found below, but videos have also been prepared which go
through the required steps. The Windows version is here
(https://canvas.sydney.edu.au/media_objects_iframe/m-3HrvNxUL56JaHmhZH4m99V6Q7P4cUVGz?
type=video?type=video) and the Mac version is here
(https://canvas.sydney.edu.au/media_objects_iframe?
mediahref=/files/20093133/download&type=video?type=video) . Don't worry if you can't hear
anything on the Mac version (it does not have any audio).
There has been some discussion on Ed about the best approach for installing onto a Mac or
Linux. A summary of the Mac approach can be found here
(https://canvas.sydney.edu.au/courses/35882/pages/project-software-install-instructions-mac) . A
summary of the Linux approach can be found here
(https://canvas.sydney.edu.au/courses/35882/pages/project-software-install-instructions-linux) .
Codeblocks installation instructions:
https://www.codeblocks.org/downloads/binaries/
(https://www.codeblocks.org/downloads/binaries/)
For Windows, choose the codeblocks-20.03mingw-setup.exe if you do not already have GCC
installed. This is the 64bit version.
SDL2 download, install, integrate with Codeblocks instructions:
https://lazyfoo.net/tutorials/SDL/01_hello_SDL/windows/codeblocks/index.php
(https://lazyfoo.net/tutorials/SDL/01_hello_SDL/windows/codeblocks/index.php)
2021/11/1 下午8:06 Project Software Install Instructions: ELEC1601/ELEC9601 Introduction to Computer Systems
https://canvas.sydney.edu.au/courses/35882/pages/project-software-install-instructions 2/3
SDL_gfx download, install, integrate with Codeblocks instructions:
download from: https://sourceforge.net/projects/sdl2gfx/
(https://sourceforge.net/projects/sdl2gfx/)
In codeblocks, add SDL_gfx to compiler search directories:
Running Project Template instructions:
Download template code: Template code.zip
(https://canvas.sydney.edu.au/courses/35882/files/20073421?wrap=1)
(https://canvas.sydney.edu.au/courses/35882/files/20073421/download?download_frd=1)
In codeblocks, create a new project, then add all files to project. [Project tab > Add files ...] Make
sure all .c files are added to debug/release:
2021/11/1 下午8:06 Project Software Install Instructions: ELEC1601/ELEC9601 Introduction to Computer Systems
https://canvas.sydney.edu.au/courses/35882/pages/project-software-install-instructions 3/3
Copyright © The University of Sydney. Unless otherwise indicated, 3rd party material has been reproduced and communicated to you
by or on behalf of the University of Sydney in accordance with section 113P of the Copyright Act 1968 (Act). The material in this
communication may be subject to copyright under the Act. Any further reproduction or communication of this material by you may be
the subject of copyright protection under the Act. Do not remove this notice.
Live streamed classes in this unit may be recorded to enable students to review the content. If you have concerns about this, please
visit our student guide (https://canvas.sydney.edu.au/courses/4901/pages/zoom) and contact the unit coordinator.
Make sure the SDL2.dll is in the same project directory as all of the .c files
To change the robot automatic navigation, you need to edit: robotAutoMotorMove in robot.c
学霸联盟学霸联盟