User Tools

Site Tools


notes:data:fall2023:projects:btt0

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
notes:data:fall2023:projects:btt0 [2023/08/27 14:54] – [Obtain source of latest release of Vircon32 (emulator and DevTools)] cburlingnotes:data:fall2023:projects:btt0 [2023/08/30 21:11] (current) – [Extract files, read instructions, install needed dependencies] jhimmel2
Line 5: Line 5:
 ====Obtain source of latest release of Vircon32 (emulator and DevTools)==== ====Obtain source of latest release of Vircon32 (emulator and DevTools)====
  
-To obtain the latest source of Vircon32 for both the emulator and DevTools, navigate to the [[http://www.vircon32.com/index.html|Vircon32]] homepage. On the left navigation bar you will want to click **Emulator** and click for **Emulator for PC** Scroll to the bottom of the new page under the **Assets** toggle you will see Source code. +To obtain the latest source of Vircon32 for both the emulator and DevTools, navigate to the [[http://www.vircon32.com/index.html|Vircon32]] homepage. On the left navigation menu you will want to click **Emulator** and click **Emulator for PC**  
 + 
 +Scroll to the bottom of the new page under the **Assets** toggle you will see Source code. 
  
 For Unix based systems including Pi you will want to download the (tar.gz) version. For Unix based systems including Pi you will want to download the (tar.gz) version.
Line 16: Line 18:
 Open your terminal, navigate to where your file was saved (Most likely Downloads) and proceed to extract it. Open your terminal, navigate to where your file was saved (Most likely Downloads) and proceed to extract it.
  
-You now have a directory of the same name as that archived file, **cd** into it and read the Readme.md+You will now have a directory of the same name as that archived file, **cd** into it and read the Readme.md
  
-Following the Readme.md install the needed dependencies and create the appropriate directories.+Following the Readmeinstall the needed dependencies and create the appropriate directories.
  
 To begin you will want to start with either the DevelopmentTools or Emulator To begin you will want to start with either the DevelopmentTools or Emulator
  
-cd into of those two directories and <code>mkdir build</code>+cd into one of those two directories and perform <code>mkdir build</code>
  
-It may be helpful to have the Readme available while you're in the build directory, start by installing cmake if it's not already installed and perform step 2 in the Readme as indicated. To install cmake, and any other dependencies you may need for Vircon32, use: <code>sudo apt install [library]</code>+It may be helpful to have the Readme available while you're in the build directory. Start by installing cmake if it's not already installed. Perform step 2 in the Readme as indicated. To install cmake or any other dependencies you may need for Vircon32, use: <code>sudo apt install [package]</code>
  
-You should receive an error saying MSYS Makefiles don't exist and you'll be given a list of options to use. Use the Unix Makefiles and repeat.+You should receive an error saying MSYS Makefiles doesn't exist and you'll be given a list of options to use. For Linux/Pi users, use the Unix Makefiles and repeat.
  
-You'll now get an error about not having a file called CMakeLists.txt Find that file and copy it into builds, although as long as CMakeLists.txt is in the same directory as the builds directory (DesktopEmulator or DevelopmentTools), it should work fine.+You'll now get an error about not having a file called CMakeLists.txt Find that file and copy it into builds, although as long as CMakeLists.txt is in the same directory as the builds directory (DesktopEmulator/build or DevelopmentTools/build), it should work fine.
  
-Keep trying to run command #3 in the Readme, it'll likely need further dependencies before it can get through without experiencing an error. The dependencies needed are listed at the bottom of the Readme. Use the following command to search for the necessary libraries, those library names should be all lowercase when searched. <code>aptitude search [Dependency]</code>+Keep trying to run command #3 in the Readme, it'll likely need further dependencies before it can get through without experiencing an error. The dependencies needed are listed at the bottom of the Readme. Use the following command to search for the necessary libraries, those library names should be all lowercase when searched. <code>aptitude search [package]</code>
  
-You'll likely be given a bunch of libraries when running this command, look for one that resembles the closest to what was listed in the Readme, and ends in _dev. Install it using the command format given above. You are (or will be) a developer in this class, you'll need these libraries installed moving forward. When you test out command #3 from the Readme again, you'll know it worked if you don't get the error for that specific dependency.+You'll likely be given a bunch of packages when running this command, look for the ones that resemble lib[package]-dev. Install it using the command format given above. You are (or will be) a developer in this class, you'll need these packages installed moving forward. When you test out command #3 from the Readme again, you'll know it worked if you don't get the error for that specific dependency.
  
 +When searching for libraries, you may get the following error:
  
 +E: Unable to locate package
 +
 +In this case first check your spelling and make sure it is correct.  If the issue persists, try running with the command sudo apt update to make the current system is up to date.  
 ====Prepare and build (for system/OS)==== ====Prepare and build (for system/OS)====
 Replicate section per system/OS you are building for Replicate section per system/OS you are building for
Line 43: Line 49:
  
 To save the path of your emulator and dev-tools in a Linux environment you need to use this command. To save the path of your emulator and dev-tools in a Linux environment you need to use this command.
-<code>+<code bash>
   pi@raspberry:~$ export PATH="/path-to-dev-tools:$PATH"   pi@raspberry:~$ export PATH="/path-to-dev-tools:$PATH"
   pi@raspberry:~$ export PATH="/path-to-emulator:$PATH"   pi@raspberry:~$ export PATH="/path-to-emulator:$PATH"
Line 50: Line 56:
 to see if the path was added correctly input the (echo "$PATH") command, at this point your path should look something like this. to see if the path was added correctly input the (echo "$PATH") command, at this point your path should look something like this.
  
-<code> +<code bash
- /opt/Vircon32/Emulator:/usr/loacl/Devtools:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin+ /opt/Vircon32/Emulator:/usr/local/Devtools:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
 </code> </code>
  
 These paths are temporary and will not save after you exit the terminal so its ok to mess up at this stage. After you are sure that you got the correct file path, its time to add them to your system so that they don't erase after you close the terminal. These paths are temporary and will not save after you exit the terminal so its ok to mess up at this stage. After you are sure that you got the correct file path, its time to add them to your system so that they don't erase after you close the terminal.
  
-<code>+<code bash>
   pi@raspberry:~$ nano ~/.bashrc   pi@raspberry:~$ nano ~/.bashrc
 </code> </code>
  
 At the bottom of this file add the two commands that you used to add the file paths, and boom you can now use the command line tools from the emulator and Devtools wherever you are on your system. 8-) At the bottom of this file add the two commands that you used to add the file paths, and boom you can now use the command line tools from the emulator and Devtools wherever you are on your system. 8-)
 +
 +If you’re having trouble locating the files, you can check the install_manifest.txt file in the build directory to see where the files are stored.  
 ====Creating your hello.c, hello.xml, and make.sh file==== ====Creating your hello.c, hello.xml, and make.sh file====
  
Line 68: Line 76:
   * Once created, go to <code>https://github.com/vircon32/ConsoleSoftware/tree/main/Tutorials/RobotGame/Tutorial01A-HelloWorld</code>   * Once created, go to <code>https://github.com/vircon32/ConsoleSoftware/tree/main/Tutorials/RobotGame/Tutorial01A-HelloWorld</code>
   * Copy the contents of each file from GitHub into their respective files in your btt0 directory.   * Copy the contents of each file from GitHub into their respective files in your btt0 directory.
-  * Make sure to go into each file and adjust the names of files as we have changed them compared to what is listed on GitHub. +  * Make sure to go into the make.sh file and adjust the names of files as we have changed them compared to what is listed on GitHub
 + 
 +Its important at this stage to make the make.sh an executable, to do this type chmod +x make.sh, this adds the executable file permission to the file. 
 + 
 +<code bash> 
 +  pi@raspberry:~$ chmod +x make.sh 
 +</code> 
 + 
 +Its finally time to compile your first vircon32 game, to do this do ./make.sh and if no errors occur it should print out build successful. 
 +   
 +There should now be a .v32 file in the bin directory.  Load this into the emulator to run the program. The emulator is in the opt/Vircon32/Emulator file. Cartridges may take time to load. 
 + 
 +After that you will want to make a file similar to hello.c,hello.xml, and make.sh . The file that you are going to submit is going to be a modified version of hello.c . So text on a page, but the amount,size,color,etc is up to you but the changes have to be significant.
notes/data/fall2023/projects/btt0.1693148097.txt.gz · Last modified: 2023/08/27 14:54 by cburling