Changing Dir & Prtreg, and Adding Clear Screen - Amateur OS Dev
Expanding the OS.bin image to a "full" 1.44MB, changing 'dir' and 'prtreg' commands to print under the prompt and not clear the screen, and making a clear_screen command stub to work on later, since BIOS int 10h Ah06h does clear screen, but does not return control back to the prompt for some reason.
Playlist link: https://www.youtube.com/playlist?list=PLT7NbkyNWaqajsw8Xh7SP9KJwjfpP8TNX
Source code as of the end of this video:
https://git.sr.ht/~queso_fuego/amateur_os_video_sources/tree/master/item/12_couple_command_changes
Git repos for this OS:
Sourcehut: https://git.sr.ht/~queso_fuego/quesos
Github mirror: https://github.com/queso-fuego/amateuros
Notes (updated ca. 2021):
- dd using the "notrunc" option/flag/whateveryoucallit, takes the data in the if (input file) and writes it to the of (output file), overwriting the data in the output file up to the size of the input file. So anything after the input file amount of space is not overwritten by the dd line.
- On openBSD or other linuxes, you can use 'xxd' as a hexdump utility, to view the hex output of a file, bin or otherwise. Using the -l (length) flag can limit the output to -l number of bytes, e.g.
"xxd -l 512 OS.bin" will show the first 512 bytes of OS.bin as hex
Software used:
VMware Workstation Player - https://www.vmware.com/products/workstation-player/workstation-player-evaluation.html
openBSD - https://www.openbsd.org/
bochs - http://bochs.sourceforge.net/
emacs - https://www.gnu.org/software/emacs/
fasm - https://flatassembler.net/
Twitch:
Like Streamers or games? Catch me live - https://www.twitch.tv/queso_fuego
Stream archive - https://www.youtube.com/channel/UCxi12g3jdQMFiFTA5GVcGMA
Contact:
email - fuegoqueso@gmail.com
twitter - @Queso_Fuego
Thoughts/Notes/Suggestions/Other - Drop a message in the video comments or by email
Credits:
Music from https://incompetech.com:
"Your Call" by Kevin MacLeod (https://incompetech.com)
Licence: CC BY (http://creativecommons.org/licenses/by/4.0/)
The blue title tags:
#osdev #programming #x86asm