This post is mostly instructions on how to install the Temple OS on Debian using VirtualBox. Temple OS is an operating system written from scratch by Terry A. Davis in order to make programming and the creation of games more fun. Its shell is a Holy-C compiler where users can write commands in Holy-C and see the generated assembly. Temple OS lacks networking and doesn’t care about security. Every program runs in ring-0 mode, which means that it has full access to the hardware. This is on purpose, because it’s fun. Terry had said many times on his videos that he didn’t want to write another UNIX and his goal was to create a modern Commodore64-like OS where the users can start writing code immediately after boot. If you are not familiar with the Temple OS and Terry A. Davis’s story, you can check the links at the end of this post.
Step 1: VirtualBox installation
The host is Debian:
sudo apt-get install linux-headers-amd64
chmod +x VirtualBox-6.0.10-132072-Linux_amd64.run
Optionally install the extension pack from here: https://www.virtualbox.org/wiki/Downloads
Step 2: Temple OS installation on VirtualBox
First, download the TempleOS iso from here:
Then, on VirtualBox, create a virtual machine selecting “Other 64-bit” OS type and reserve at least 512 MB of RAM.
Then create the VDI as you like and start the VM having the TempleOS.ISO mounted, and you must see the following screen:
y to install the TempleOS, and when the installation is done eject the TempleOS.ISO and restart the vm.
Step 3: PC speaker passthrough
When you boot the vm with the installed TempleOS, you might want to test the “songs” and the music. TempleOS plays music using the pc speaker which cannot be accessed by default from VirtualBox.
- the pc you run the host OS has a pc speaker
- you are using the ALSA sound architecture
pcspkrkernel module is loaded (
modprobe pcspkrto load it, also check the module is not blacklisted)
you can do the following:
1. Unmute the speaker if it’s muted (I usually have it muted by calling
xset b 0 automatically when I start
X). The easiest way is through
alsamixer: run it, press
F6 to select device and select the
HDA Intel PCH (I haven’t tested it with other devices), press enter, move with the arrows until you find the
Beep column, if it’s muted (
MM) press M to unmute and
ESC to exit:
2. Then, check that the pc speaker works on the host:
3. If you can’t hear any sound check if your user has permissions to use the pc speaker. The pc speaker is listed under the
/dev/input directory on Debian (
/dev/input/by-path/platform-pcspkr-event-spkr) where only root and the input group users have permissions and so, you should add your user to the
input group (
adduser $USER input) to be able to play sound from it.
4. Edit the virtual machine settings to be:
5. Pass through the pc speaker to the host:
VBoxManage setextradata "TempleOS" "VBoxInternal/Devices/i8254/0/Config/PassthroughSpeaker" 1
TempleOS is the name of the vm, and
1 is for
/dev/input/by-path/platform-pcspkr-event-spkr according to the VirtualBox documentation.
6. Test the sound by playing a “song” by pressing
Step 4: Playing with the OS
Closing this post, here’s a list of interesting things to do with Temple OS:
- Write Holy-C commands on the shell and disassemble them.
- Use the editor: it is not just a text editor, it can edit any object (graphics objects for example).
- Play the games and modify them to do something different.
- Read the endless documentation about everything that is everywhere: almost every word you select is a link to something.
- Pack words inside the character literals just because you can! (Each character literal is a full 64bit integer number, and so each character can store 8 bytes). “7-bit signed ASCII is retarded!”
- Try to compose music using the app for it.
- Check out the “God” generated messages and songs and try to make sense… just kidding 🙂 although I found it fun to play with the random numbers generator.
- Explore! 🙃
Don’t forget to enable redshift or something similar and reduce the brightness to 0… :p (I really loved the OS but these colors/fonts made my eyes bleed… 😵😎)
Playing games on TempleOS (when we ran it without installing it in our tv-pc):
Out of scope of this post, something I was thinking after I watched the “Down the rabbit hole” documentary on Temple OS:
That image I used at the top was made by Terry A. Davis using a 16 color palette:
Terry wrote in public that this elephant was pleasant to create and after I’ve seen his editor and the way he creates graphics, I suppose that it must really have been so. What is really weird though, is that people thought that he was delusional and he was believing that his drawing was superior than the 16777216 color graphics. Even in the documentary about him, it was mentioned that because he was schizophrenic he believed that his elephant was better than a 16777216 color elephant! I really can’t see how people can misunderstand this phrase so much! Just try to create an elephant 3D object with thousands of polygons in a 16777216 color system and then ray trace it and you will see what he meant. A 16-color palette elephant really is more easy and more pleasant to create! He said to create, not to watch! 🐘🐘🐘
And here are some screenshots from the TempleOS editor where someone can mix and edit objects, plots, source code and text (personally, I loved the concept in the context of an OS that is written to make programming fun! I don’t know if it would be easy to use in another OS, and for other purposes though):
Something that is not very obvious in the screenshots is that most of the 3D objects are also animated. But anyway, just follow the instructions, install the TempleOS and explore yourselves the Demos!
More info on Temple OS can be found in the links below:
- Temple OS website: https://templeos.org/
- Wikipedia article: https://en.wikipedia.org/wiki/TempleOS
- Down the rabbit hole documentary on Terry A. Davis (the divine intellect author), RIP:
- Why 7-bit signed ASCII is retarded: https://www.reddit.com/r/TempleOS_Official/comments/bbvcl1/serious_why_is_7_bit_signed_ascii_retarded/