Queso Fuego
Queso Fuego
  • 395
  • 332 436
Printing Configuration Tables & ACPI Table Signatures | UEFI Dev (in C)
Just printing configuration table GUIDs and ACPI table signatures (FACP, APIC, etc.), and am tired as per usual, so this is a pretty boring one. (I'm also on a quest to find the ugliest color combo for thumbnail text that also evokes clip art from gradeschool computer labs)
Errata:
- I changed the acpi table header structure later to be closer to the ACPI 6.5 specification section 21.2.1 acpi_table_header struct, as far as string values for IDs.
- BXPC probably stands for "Bochs PC" but they only had 4 characters to work with.
Links:
uefi.org/specifications (uefi & other specifications)
github.com/tianocore/edk2
UEFI Programming playlist:
ua-cam.com/play/PLT7NbkyNWaqZYHNLtOZ1MNxOt8myP5K0p.html
Git Repo:
github.com/queso-fuego/uefi-dev
Repo state at the start of this video:
git clone --recurse-submodules github.com/queso-fuego/uefi-dev
cd uefi-dev
git checkout b966f8bcdd6c6c17982bf4cd4384e9b185ba2779
Repo state at the end of this video:
git checkout 50de8d4a551458b89c55748b62097a4a2d0704c5
Join the Community Discord: discord.gg/yKm4T89QFn
Contact:
queso_fuego.srht.site/contact.html
If you feel like throwing money my way:
queso_fuego.srht.site/support.html
Questions about setup/software/etc.?
Check the FAQ: queso_fuego.srht.site/about.html
Next video:
- Setting up 4 level paging and maybe a new GDT, to use with remapping the kernel to have actual "full control" over memory when handing off control to the kernel.
Editing/Misc. Notes:
- Trying out Davinci Resolve's youtube 2160p export option for this, with AMD AV1 main10 encoding and AAC audio.
If this ends up with similar (or better?...) quality than the last stuff, then I can trust resolve's defaults which make things simpler for rendering and exporting.
When version 19 is out of beta I'll probably try the subtitle generation and see how that works to add subtitles to these videos.
Currently, using a custom preset for AMD AV1 exports in resolve does not use the GPU or CPU correctly, and is very slow.
The youtube 2160p preset for mp4 AV1 AMD uses the GPU and works fine, and has 40-60% lower bitrates than h265 gpu encoding, for these videos. They have a lot of static background color, and aren't very light (have much natural light), which helps AV1 save a lot of bitrate.
For render speed, my AMD rx 7700 xt took about 50-53% of real time; 53 min for a 98 min video.
Normally h265 takes me about 40-50% of real time, so it seems to be a win for bitrate savings.
But hopefully this video isn't worse quality than usual from that lower bitrate. AV1 _should_ be better quality at lower bitrates anyway, such as less than 1080p, but we'll see how that turns out.
This opens up AV1 streaming as well, for youtube, which can use a constant bit rate and have relatively high quality 1080p+ streams with 6-8k+ bitrate.
I'm also looking into getting a "gamer xD rgb pro n00b-pwner 3000" laptop, or another type of laptop, for windows/gaming/video editing, to take up less room than another desktop (and use less power) and to use when away from home.
I could do things with my main/dev PC while a video is rendering/uploading/etc. and it'd let me remove dualbooting between linux/windows and have a cleaner main system with more storage, better working bluetooth and other things.
I'm assuming nvidia nvenc has better quality for h265 and av1 hardware encoding as well, for resolve exports, or could use the cpu for better quality as time doesn't matter as much not being on my main setup. Or I can render things overnight and use more power/heat that way.
- For programming languages, printing out types and other things would be alot easier in C++ or Rust,
it's already built in or trivial to add, and would have made a lot of development & videos shorter and simpler, as I do a lot of printing values to the screen. Thinking about this for future projects.
0:00:00 add runtime services and config table GUIDs/kernel parms
0:12:04 call runtime services from loaded program
0:18:10 add menu option to print configuration table GUIDs
0:45:36 add menu option to print acpi info (only table signatures for now)
1:31:08 Topics for next video
Music credits:
[Chiptune] Medieval: Minstrel Dance by RandomMind
Music: www.chosic.com/free-music/all/
#uefidev #cprogramming #acpi
Переглядів: 903

Відео

Get Memory Map & Exit Boot Services | UEFI Dev (in C)
Переглядів 1,4 тис.2 місяці тому
Getting a memory map and officially exiting boot services, which means full control over all memory and the machine from that point on e.g. you can load your OS! Errata: - Fixed the error message for the initial GetMemoryMap() call after this video. - While there can be reserved space for firmware and micro controllers, etc. on other devices like SSDs, it's probably more common that a storage d...
Loading/Running Programs | UEFI Dev (in C)
Переглядів 9924 місяці тому
Running a program instead of just printing text files. A program or executable file has a format like any other type of file, and in C it's a relatively simple matter of loading data structures to match the format, loading needed sections of the program to a new buffer, getting the new entry point, and calling that entry point to run the program. A PE file can be slightly easier to load than an...
Load File from Disk Blocks & Other Abstractions | UEFI Dev (in C)
Переглядів 3314 місяці тому
Reading a file from the basic data partition on the disk image, and adding helper functions to get a file into a buffer from the EFI system partition and from disk blocks. Errata: - Not sure why I put an extra error check before the file Read() call, it doesn't do anything and should be removed. Probably from being tired and having tunnel vision. Misc. Notes: - Removed the noise suppression fil...
Block IO Protocol Media Information | UEFI Dev (in C)
Переглядів 3954 місяці тому
Printing Block IO Protocol Media Information, to see what disk partitions are returned by UEFI. Audio Notes: - Trying a different audio setup in OBS for gain, expander, de-esser, eq, compressor, and limiter. This video still had noise suppression, but I removed it after this as words are being cut off occasionally. May have to use it when the HVAC is blowing though. In editing, I'm using izotop...
Delete File & Rename Commands | 32 Bit OS Dev (in C)
Переглядів 5085 місяців тому
Yes, doing this again since the file system is different now, and has directories and other goodies. This video is adding an 'rm' command to delete files, some miscellaneous helper functions and fixes, and a 'ren' command to rename files at the end. OS Dev Playlist: ua-cam.com/play/PLT7NbkyNWaqZYHNLtOZ1MNxOt8myP5K0p.html Git Repos: git.sr.ht/~queso_fuego/quesos github.com/queso-fuego/amateuros ...
Reading Files in the EFI System Partition | UEFI Dev (in C)
Переглядів 6975 місяців тому
Adding and using file protocols to read the EFI System Partition from within a booted EFI application. Notes: - An EFI "image" might only be the application itself, the metadata is only for and about the booted file/application. So I misspoke on that. Links: uefi.org/specifications (uefi & other specifications) UEFI Programming playlist: ua-cam.com/play/PLT7NbkyNWaqZYHNLtOZ1MNxOt8myP5K0p.html G...
Making an Initial File Tree | 32 Bit OS Dev (in C)
Переглядів 6895 місяців тому
Setting up an initial file tree for the OS, instead of only having a root directory. make_disk will copy all files and folders under a host filepath, and use that as the initial file tree for first boot. Other than a couple hardcoded paths for the bootloader, kernel, and a font, this should end up being a lot more flexible and allow an easy way to add files and folders to the OS at build time; ...
Absolute Pointer Protocol & Touchscreen | UEFI Dev (in C)
Переглядів 1,5 тис.7 місяців тому
Adding Absolute Pointer Protocol support & testing for touchscreens/digitizers, and getting multiple Simple Pointer & Absolute Pointer instances working at the same time. Links: uefi.org/specifications (uefi & other specifications) UEFI Programming playlist: ua-cam.com/play/PLT7NbkyNWaqZYHNLtOZ1MNxOt8myP5K0p.html Git Repo: github.com/queso-fuego/uefi-dev Repo state at the start of this video: g...
Timer Event & Printing Date/Time | UEFI Dev (in C)
Переглядів 1,6 тис.7 місяців тому
Making a timer event to print the current date/time every 1 second. Notes: - In the overall menu loop, I probably should have closed the timer event with CloseEvent() before creating a new event each time. Right now it might keep adding timer events every time the user goes into and back out of a menu choice. - My laptop defaults to using UTC, which may be what most other devices do as well. If...
Mouse Cursor & Simple Pointer Protocol | UEFI Dev (in C)
Переглядів 1,2 тис.7 місяців тому
Getting Simple Pointer Protocol instances and trying out basic (albeit inaccurate/stuttery) mouse support. Notes: - Still had an off by 1 error for the gop menu on the laptop, menu_bottom should be (menu_top max-1), without that -1 moving down still shows an invalid mode 5. D'oh! That's fixed now in the repo. - After this video, I tried cloning edk2 and building OVMF, but on alpine linux it fai...
Make & Change Directory Commands | 32 Bit OS Dev (in C)
Переглядів 5517 місяців тому
Adding mkdir and chdir commands for the filesystem, so there can be more things than only a root folder. Notes: - Should probably include "C/stdlib.h" instead of "memory/malloc.h" for malloc use in non-kernel source files. Since stdlib has the C wrapper functions for malloc() and free() and would prevent using fully separate malloc instances in some cases, which isn't needed in the elf header. ...
Loading ELF PIE Executables | 32 Bit OS Dev (in C)
Переглядів 6087 місяців тому
Making an elf loader to replace running flat binary files. Currently it only loads the program headers for an ET_DYN type ELF PIE executable, as I didn't need the section headers, symbol table, or other relocation setups for the calculator (although they may be needed elsewhere). This is also why you should use the correct compiler & linker flags first, or search it up online, to save hours of ...
Set GOP Mode With "Scrolling" Menu | UEFI Dev (in C)
Переглядів 5797 місяців тому
Making choosing a GOP mode a bit better with a "scrolling" menu, and setting the GOP mode. Notes: - This GOP menu is a bit jank on my laptop, as it only has 5 modes (not 30), and I did not handle the case where the maximum GOP mode is less than the screen or menu length. That'll be fixed on the next video! Links: uefi.org/specifications (uefi & other specifications) UEFI Programming playlist: u...
Getting GOP Info | UEFI Dev (in C)
Переглядів 6378 місяців тому
Getting GOP (graphics output protocol) mode information, and faffing about a bit. The next video will have setting the mode, but that's just calling SetMode() from the gop with a mode number. Notes: - Day 3.14159/infinity of changing audio settings: Added a noise gate filter for this video, but removed it afterwards, since it didn't really help that much and made things choppier. - I did try an...
Reset/Shutdown & Main "Menu" | UEFI Dev (in C)
Переглядів 8588 місяців тому
Reset/Shutdown & Main "Menu" | UEFI Dev (in C)
Get User Input / Set Text Mode | UEFI Dev (in C)
Переглядів 7328 місяців тому
Get User Input / Set Text Mode | UEFI Dev (in C)
Basic Printf & Text Mode Info | UEFI Dev (in C)
Переглядів 8448 місяців тому
Basic Printf & Text Mode Info | UEFI Dev (in C)
Reading the Spec & Hello World | UEFI Dev (in C)
Переглядів 1,2 тис.9 місяців тому
Reading the Spec & Hello World | UEFI Dev (in C)
Command Line Flags 2/2 (VHD) | GPT Disk Image | UEFI Dev (in C)
Переглядів 645Рік тому
Command Line Flags 2/2 (VHD) | GPT Disk Image | UEFI Dev (in C)
Command Line Flags 1/2 | GPT Disk Image | UEFI Dev (in C)
Переглядів 520Рік тому
Command Line Flags 1/2 | GPT Disk Image | UEFI Dev (in C)
Adding Files / Directories to the ESP | GPT Disk Image | UEFI Dev (in C)
Переглядів 850Рік тому
Adding Files / Directories to the ESP | GPT Disk Image | UEFI Dev (in C)
EFI System Partition | GPT Disk Image | UEFI Dev (in C)
Переглядів 1,2 тис.Рік тому
EFI System Partition | GPT Disk Image | UEFI Dev (in C)
GPT Headers & Tables | GPT Disk Image | UEFI Dev (in C)
Переглядів 1,7 тис.Рік тому
GPT Headers & Tables | GPT Disk Image | UEFI Dev (in C)
Protective MBR | GPT Disk Image | UEFI Dev (in C)
Переглядів 3 тис.Рік тому
Protective MBR | GPT Disk Image | UEFI Dev (in C)
Intro / Overview | UEFI Dev (in C)
Переглядів 15 тис.Рік тому
Intro / Overview | UEFI Dev (in C)
Syscall Refactors & String Tokens | 32 Bit OS Dev (in C)
Переглядів 628Рік тому
Syscall Refactors & String Tokens | 32 Bit OS Dev (in C)
Debugging Program Loading | 32 bit OS Dev (in C)
Переглядів 367Рік тому
Debugging Program Loading | 32 bit OS Dev (in C)
Read() Syscall | 32 Bit OS Dev (in C)
Переглядів 302Рік тому
Read() Syscall | 32 Bit OS Dev (in C)
Write() Syscall | 32 Bit OS Dev (in C)
Переглядів 365Рік тому
Write() Syscall | 32 Bit OS Dev (in C)

КОМЕНТАРІ

  • @luandkg
    @luandkg 4 дні тому

    Welcome Back 🤩🤩🤩

  • @alexmeh1919
    @alexmeh1919 4 дні тому

    💪👊🔥

  • @offlinemark
    @offlinemark 4 дні тому

    Nice one!

  • @ThatOSDev
    @ThatOSDev 4 дні тому

    Snagged the music ! THANK YOU !! The Laptop definately had a LOT more hardware specs. 👍

    • @QuesoFuego
      @QuesoFuego 4 дні тому

      Yeah, and a lot of it is probably buggy!

    • @ThatOSDev
      @ThatOSDev 3 дні тому

      @@QuesoFuego I'm sure you'll sort it out. :D

  • @RealCatDev
    @RealCatDev 4 дні тому

    Finally!

  • @hampus23
    @hampus23 4 дні тому

    He is back!! 🙌

  • @nesdi6653
    @nesdi6653 5 днів тому

    awesome I been struggling with UEFI over the past months, it's hard to get your mind around for some reason

    • @QuesoFuego
      @QuesoFuego 4 дні тому

      It is a bit scattered around and not well explained. But it's really just an interface or api definitions for a library/framework, that gets info for various devices or parts of firmware. The implementation of that library is hidden, it's implemented in firmware, but you have documentation for how to talk to it, essentially.

  • @GL455_
    @GL455_ 10 днів тому

    Man thank you so much, such a nice video series! Ultimate geek juice XD. And please do digress more!

  • @HichamTamri23
    @HichamTamri23 17 днів тому

    Gordon Freeman?!!! What are u doing here??!!

  • @konstantinrebrov675
    @konstantinrebrov675 Місяць тому

    Hello sir. I have some questions. How old are you? And how long did it take you to get to such a level of programming skills?

    • @QuesoFuego
      @QuesoFuego Місяць тому

      I'm 29, and it's been about 6-7 years of off and on learning and hobby programming, and having a job using a C-like language (RPG). I wouldn't say I have skills, I'm pretty slow with things and it's hard to program on camera and talk and think at the same time, but I do read a lot and try to get several different perspectives or articles on doing any one thing, to be able to understand it. Also making and testing a few different versions before making a video on something. Lately that includes studying documentation or original sources where available, which can take a awhile to piece together a program or project. I'm also pretty stubborn and will keep trying just about every permutation and combination of things until it works, then will remove things until it doesn't work, and try to find a balance between those two. Then think about why it works in that configuration, and if it can be improved further with your new knowledge and understanding, and why, and repeat. I'd say perseverance and time has helped way more than any knowledge or talent, for what it's worth.

  • @PhilosophieVagabonde
    @PhilosophieVagabonde Місяць тому

    i write a recursive solution that work way faster for me : #include <stdio.h> long if_even_odd(long number, long count); long is_even_odd(long number, long count); long calcul_even(long number, long count); long calcul_odd(long number, long count); long if_even_odd (long number, long count) { if (number == 1) return count; return is_even_odd(number, count); } long is_even_odd (long number, long count) { if (number % 2 == 0) return calcul_even(number, count); else return calcul_odd(number, count); } long calcul_even(long number, long count) { number = number / 2; count++; return if_even_odd(number, count); } long calcul_odd(long number, long count) { number = 3 * number + 1; count++; return if_even_odd(number, count); } int main() { long number = 1; long maxterm = 0; long max_number = 1; while (number <= 1000000) { long count = 1; long steps = if_even_odd(number, count); if (steps > maxterm) { maxterm = steps; max_number = number; } number++; } printf("The number with the most terms is %ld with %ld terms ", max_number, maxterm); return 0; }

  • @apgcsoftwares3708
    @apgcsoftwares3708 Місяць тому

    where did this series started?

  • @elpanatv2537
    @elpanatv2537 Місяць тому

    i made a modification to this method of loading a kernel, instead of adding the kernel into the files i made a file called kernel.bin. i think its easier to implement. also nice video!

    • @QuesoFuego
      @QuesoFuego Місяць тому

      That works! It would be simpler, I was curious about reading disk blocks and didn't want to be limited to only the EFI system partition.

  • @user-nv2zu7bg1c
    @user-nv2zu7bg1c Місяць тому

    Hi, can you please tell me how to run your OS from a USB drive?

    • @QuesoFuego
      @QuesoFuego Місяць тому

      You could write the OS.bin file directly to a usb with dd or rufus, but it probably won't work in protected mode unless usb somehow emulates an ide drive. ATA PIO would not work, it needs a proper USB stack, and ehci or xhci support, which is a lot of work. I use a SATA to USB cable to write to an ssd and boot from that, which is less convenient, but works for now.

    • @user-nv2zu7bg1c
      @user-nv2zu7bg1c Місяць тому

      @@QuesoFuego thanks you very much

  • @user-ss3sz7lv5b
    @user-ss3sz7lv5b Місяць тому

    This is great, it's fantastic to watch you think out loud as you go.

  • @xnaaloh4437
    @xnaaloh4437 Місяць тому

    Thanks for the video. I learnt a lot. :) For the string comparison in add_path_to_esp, you could just do memcmp(DIR_Name, start, (11<strlen(start)?11:strlen(start)+1) Because you will also be comparing the 0 byte of start, so you will know for sure whether it is just EFI or EFI 1 or something. 11<strlen(start) because we need to make sure strlen(start)+1 is maximum 11. Hope this helps :)

    • @xnaaloh4437
      @xnaaloh4437 Місяць тому

      Oh wait nvm i forgot that DIR_Name has spaces and not null bytes at the end

    • @xnaaloh4437
      @xnaaloh4437 Місяць тому

      There are 2 ways I can think of solving this, 1. memcpy from start to another char array with length of 11. Then compare that. 2. Make a function in assembly using the rep instruction, with rcx set to 11-strlen(start) and eax to 0x20(space char) Then check if rcx reaches 0, if it does then it is the same, else there is something else after the initial string. The code would be char *aft_name = DIR_Name +strlen(start); int length = 11-strlen(start); asm(“ mov $0x20, %%al mov %[name], %%rdi mov %[len], %%ecx rep scasb mov %%ecx, %[len1]”:(len1)”=m”(length):(name)”m”(aft_name), (len)”m”(length):”rdi”,”ecx”); If(length == 0) printf(“it is equal”);

    • @QuesoFuego
      @QuesoFuego Місяць тому

      I'd probably want to prevent files being added with non-8.3 compliant names when getting the command line flags, or convert file names to 8.3 at that time. That would ensure any file names are 11 length or less and prevent other issues.

  • @TheNotoriousTechNerd
    @TheNotoriousTechNerd Місяць тому

    I am a bit confused by the context of the timer function since you are creating the event in the main menu loop, wouldn't it only refresh the rows and cols when the user exited the set text mode menu and the next event was created and triggered in the main menu loop (since the rows and cols variables are updated only in the main menu loop not by the set text mode menu)? I think when you switched text modes it still wrote to the same row or am I just dumb?

    • @QuesoFuego
      @QuesoFuego Місяць тому

      Yes, it only refreshes the rows/cols from QueryMode(), which is in the main loop. It would stay in the same spot until getting the new row/col values there. Probably would want the context globally or passed around, and update it immediately when needed such as changing the text mode, or using CloseEvent() for the timer event to stop it, and adding back the timer event later.

  • @haroldcruz8550
    @haroldcruz8550 2 місяці тому

    Thank you for being thorough with this tutorial, and the links that you provide are extremely helpful.

  • @haroldcruz8550
    @haroldcruz8550 2 місяці тому

    It's one of my goals for 3 months is to finish this series.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Yeah mine too... 😅 Keep finding stuff to add.

  • @haroldcruz8550
    @haroldcruz8550 2 місяці тому

    What a wonderful find for me. Thank you

  • @harshavardhanghanta4421
    @harshavardhanghanta4421 2 місяці тому

    Thanks!

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Thank you! Appreciate it!

  • @TheNotoriousTechNerd
    @TheNotoriousTechNerd 2 місяці тому

    A bit late to the party xD but if I followed along correctly shouldn't the buffer in the print number function be size 12 because if the integer turns out to be -2,147,483,648 that is 11 characters without the null termination but 12 would include the null. Probably won't show up in more than half the use cases as a bug so thought I would bring it up preemptively.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      It should be 12 yes, to handle the null byte. Otherwise can get the length in digits and make a length specifier for printf, .*s or $1 or similar. I expanded the buffers later on to char[24], int64_t is around 21 or 22 with the sign character and a null byte.

  • @ThatOSDev
    @ThatOSDev 2 місяці тому

    Hey my friend, glad you are still making videos. 👍

  • @benjamindeharo314
    @benjamindeharo314 2 місяці тому

    Do you still plan to do an emulator, and if yes which machine will it be ?

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Yes, some time. Probably an NES or gameboy, or a different 6502 or z80 based machine like C64 or zx spectrum, something like that.

    • @benjamindeharo314
      @benjamindeharo314 2 місяці тому

      @@QuesoFuego That's cool ! Since you're still hesitating on what machine to emulate, I'd suggest the 8080 space invaders arcade machine, as it is somewhere between the chip8 and the gameboy in terms of complexity. But whatever you choose, I'll watch it.

    • @dejavu4379
      @dejavu4379 Місяць тому

      @@QuesoFuego A ZX Spectrum would be cool because the graphics are simple. I always find the tutorials about the Gameboy and NES to be overwhelming, and I'm sure that's the case for most people. The ZX Spectrum is a nice step after the Chip-8 without being overwhelming.

    • @naturerelaxingmusic4961
      @naturerelaxingmusic4961 Місяць тому

      The only video tutorial about space invaders is this one : ua-cam.com/video/Oyz4yRvYK0s/v-deo.html c#, visual studio, using form and all...eww.. The way QuesoFuego is doing it (c/sdl) would be much more instructive.

  • @user-nf3jr3wl9v
    @user-nf3jr3wl9v 2 місяці тому

    Hi Queso, I really interested in low level programming. How can I learn C? Can you suggest a book for beginners with no programming experience and also any other books that will help me with learning low level stuff?

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Learning C would be best done by programming in C, and making projects you are interested in and looking things up when you get stuck or want to know better/different ways of doing something. I can't tell you how to learn, only that it takes a lot of time and effort, and only you can know how you learn things. There isn't a single place or thing for learning programming with no experience, usually school does that or you find some random thing or website and try out html and js, or python, or scratch, or C, or assembly, or anything else, and want to do something with it like make games, cheats, graphics programs, drivers, reverse engineering, making an OS, etc. You search up on the topics that interest you and how to do them, starting could be as simple as writing a text file and compiling it and running the program, or making an index.html page and loading that in the browser, and then you go from there. You'd want to learn a given language's syntax and semantics, control flow, data flow, data structures and algorithms, built-ins, libraries, etc. but you only learn these things by writing the language and making things and running them, and debugging and all the other fun stuff that comes with it. Maybe the most recommended nowadays for C books is: C Programming: A Modern Approach, 2nd Edition by K. N. King But also the classic C book: C Programming Language, 2nd Edition by Brian W. Kernighan and Dennis M. Ritchie You could use gcc with -std=c89 for that book, but some aspects may not work the same today as they did decades ago. For low level in general, ideally you'd know computer organization and architecture, different hardware protocols and communication standards, up through assembly language and the ISA for your given processor, file formats, object and executable formats e.g. ELF vs PE files, and how your OS operates on top of all that and how to interact with it, via syscalls or including system headers, and other means. That would make C and any other higher level languages make more intuitive sense, as to what they can translate into and run as (the actual operations that happen are different on the cpu, but that's getting into hardware that you can't change, more so than software that you can change). A couple books for bottom up learning or more low level topics would be: Code: The Hidden Language of Computer Hardware and Software by Charles Petzold The Elements of Computing Systems, second edition: Building a Modern Computer from First Principles by Noam Nisan, Shimon Computer Systems: A Programmer's Perspective by Randal Bryant, David And also maybe some patterson and hennessy books on computer architecture or organization for a given ISA (x86, arm, risc-v, etc.) A couple assembly language books, as extra. These are for x86, but arm & others probably have similar things out there, and their own assemblers like cc65 for 6502 for e.g. nes programming, things like that: x64 Assembly Language Step-by-Step: Programming with Linux (Tech Today) 4th Edition by Jeff Duntemann Modern X86 Assembly Language Programming: Covers X86 64-bit, AVX, AVX2, and AVX-512 3rd ed. Edition by Daniel Kusswurm

    • @user-nf3jr3wl9v
      @user-nf3jr3wl9v 2 місяці тому

      Thank you so much, I really appreciate this. I will get started on buying the book for c and start my way from their!@@QuesoFuego

  • @MsDuketown
    @MsDuketown 2 місяці тому

    Some game requests for inspiration: * Tapper (1983).. The player has to serve customers with beer, but the gameplay is diagonal. * Paperboy (1985).. Forever classic * Lemmings (1991).. * Frogger (1981).. * Bedlam (1988) I think most of these games could use the same DrawTexture.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Thanks! Will look into doing these. I was trying to do asteroids but with floating point instructions for accurate turning and acceleration it was ending up a lot larger than 1 sector. May still do that anyway and just load additional sectors. Frogger or tapper I think would be easiest out of those, although original lemmings probably doesn't have that complicated logic for path finding/collision. Different jobs and selecting parts of the level would be interesting to implement. Paperboy I'd want to have some sort of scrolling, maybe a generated level or large map, which might overflow a sector by a bit. Appreciate these suggestions!

    • @MsDuketown
      @MsDuketown 2 місяці тому

      @@QuesoFuego thanks for the video.. Architecture-wize I'd opt for an UEFI engine, to provide the first step of drawing (screen, border, colors, fill, etc). You'll only need to unify data structures accordingly. Syntax-wize I could also share some pointers, but I recon this topic nowadays only renders discussion.

  • @hampus23
    @hampus23 2 місяці тому

    It is possible for the firmware to modify the memory map during a call to ExitBootServices(). A so-called "partial shutdown". When that happens, ExitBootServices() will return EFI_INVALID_PARAMETER so you may need to call it again with a new key.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Wow, it's in the thumbnail as well, I really didn't read those 2 sentences until now. Been relying on my laptop behaving correctly for these. Well, I can do this at the start of the next one then. Can have a retry count and loop on ExitBootServices(), if it errors on invalid parameter then will call FreePool() on the mmap buffer, call get_memory_map(), and ExitBootServices() again. Fails after say 3 tries then will count that as the hard error.

    • @hampus23
      @hampus23 2 місяці тому

      ​@@QuesoFuego you can allocate a larger buffer the first time and if the call to ExitBootServices fail you can reuse it 🤷‍♂️ GetMemoryMap should always be called with a buffer larger than it needs to avoid problems.

  • @hampus23
    @hampus23 2 місяці тому

    1:56 There is a lot of typos in the specification 🤣 Saw that many months ago they haven't fixed it yet 🤔

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Yeah not sure why no one proof reads it first

  • @theodoredu31
    @theodoredu31 2 місяці тому

    hi, this is very useful, thank you. But I have a probleme when I try to put the "display_library: sdl" in the .bochsrc file It tell me, when I run the program that the sdl display library is not available. I hope someone can help me, I try to use sdl2 but it doesn't work too. PS: I maybe made mistake, I'm not english.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      You may need a bochs-sdl package if that exists, or you can try "display_library: x" for x11.

    • @theodoredu31
      @theodoredu31 2 місяці тому

      @@QuesoFuego thank you it works perfectly with the display library x

  • @hydradragonantivirus
    @hydradragonantivirus 2 місяці тому

    I can code in UEFI too.

  • @meetpanchal5641
    @meetpanchal5641 2 місяці тому

    I would like to know your profession? are you a UEFI developer or OS developer or other? and which company you workning in? can I connect you on linkedIn. It is just curiosity.

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      I'm a Programmer/Analyst in a transportation company, they do trucking and general freight handling/shipping, warehousing, logistics, etc. I mainly handle backend and (some) full stack applications for an IBM i system (AS/400). Mostly business logic and reports, some database programming and querying, web services, API integrations, scripting, or whatever else they ask for. My primary languages for work are RPG and SQL, maybe kotlin and JS/TS in a few years if we switch over more to mobile devices and cloud apis. Not really open to LinkedIn or IRL connections right now, but might be in the future.

  • @Ahm3dTantawy
    @Ahm3dTantawy 2 місяці тому

    why does this have only few views

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Thumbnail isn't great, very niche topic, lack of SEO, UA-cam algorithm changes all the time, etc. etc.

  • @jas0x139
    @jas0x139 2 місяці тому

    These videos are great. I was following along and learned a lot but hit a wall at bitwise operations so had to stop for a few days until I could understand and do them on my own. Felt great once I got it!

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Awesome, glad to hear it!

  • @aaronvaldes3104
    @aaronvaldes3104 3 місяці тому

    This is awesome. I am using NASM and qemu to teach myself all instruction of the 80386 instructions. I just stumbled upon this site. Where is the source so I can try this?

  • @elwen8525
    @elwen8525 3 місяці тому

    dude how do you increase the amount of charges you have????

    • @QuesoFuego
      @QuesoFuego 2 місяці тому

      Killing enemies gets thin blood which gives the vials, if you mean the charge shots I think that's from story progression for specific characters. Mask de smith gets 3 charges and later 5 when he gets new outfits

  • @x86debug
    @x86debug 3 місяці тому

    Extremely helpful, thank you big time. (I came from ThatOsDev)

  • @samborms
    @samborms 3 місяці тому

    thanks for this serie, from your UEFI applications serie, I made a little example using in line assembly and paste in an UEFI application, it works well, I am using the Getkey() function, but for the moment only gets a one character, I have to improve that function to read more characters to send to the in line assembly functions

    • @QuesoFuego
      @QuesoFuego 3 місяці тому

      ConIn ReadKeyStroke() gets one key at a time, you could loop on that and add to a buffer until you get an ' ' for the enter key, and return then or send the buffer somewhere. That'd be closer to a line buffered stdin.

  • @yingchiahung
    @yingchiahung 3 місяці тому

    謝謝!

    • @QuesoFuego
      @QuesoFuego 3 місяці тому

      Thanks! Appreciate it

  • @ShimoriUta77
    @ShimoriUta77 4 місяці тому

    Dude did the "giggity" 💀

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      Sir, this is a moai house 🗿

  • @DigitLineEletronica
    @DigitLineEletronica 4 місяці тому

    Fantastic thank you

  • @mihaicotin3261
    @mihaicotin3261 4 місяці тому

    You’re amazing !

  • @RealCatDev
    @RealCatDev 4 місяці тому

    Glory to Arstotzka!

  • @AbdullahRajpoot117
    @AbdullahRajpoot117 4 місяці тому

    Love from Pakistan!

    • @smallcube-zn2mm
      @smallcube-zn2mm 4 місяці тому

      Waiting for some Indian to make some hate comments (I am not Pakistani)

  • @ahmadsameh5509
    @ahmadsameh5509 4 місяці тому

    thank you for this amazing tutorial. i would like to add more code to it. is there a way to run this game in more than 512 bytes? if yes where can i find resources for this?

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      Yes, you can load additional disk sectors with bios interrupts, int 13h ah=02 en.m.wikipedia.org/wiki/INT_13H You could load data after the boot sector with that, or anywhere on the disk that it's written to, as long as you know the starting sector number. If it's low or right after the bootsector, then you could use cylinder 0 and head 0, but sector is 1-based, 1-63. ES:BX would point to the memory address to load into.

  • @focuseletronica
    @focuseletronica 4 місяці тому

    Muito top... e se fosse escrito em rust... como seria?

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      Error handling would probably be more streamlined with option types, and structs could have #[repr(C)] or #[repr(packed(1))]. Functions maybe as well, but those may not be needed to have C representations. There's at least 1 UEFI crate for rust I found github.com/rust-osdev/uefi-rs there may be others, I'd have to research how it does things as a wrapper for uefi ------------------------------------------------ O tratamento de erros seria provavelmente mais simplificado com tipos de opção, e os structs poderiam ter #[repr(C)] ou #[repr(packed(1))]. Funções talvez também, mas elas podem não ser necessárias para ter representações em C. Há pelo menos 1 UEFI crate para rust que eu encontrei github.com/rust-osdev/uefi-rs pode haver outros, eu teria que pesquisar como ele faz as coisas como um wrapper para uefi

  • @RealCatDev
    @RealCatDev 4 місяці тому

    nice!

  • @paulwratt
    @paulwratt 4 місяці тому

    yeah, it was definitely interesting (and audio was good too BTW)

  • @alexloktionoff6833
    @alexloktionoff6833 4 місяці тому

    Might you know what are the PIO mode 4 and 5? Does anybody know what is the 'fast PIO mode' actually is?

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      According to this en.wikipedia.org/wiki/Programmed_input%E2%80%93output PIO mode 4 is up to 16.7MB/s and mode 5 is for compact flash and up to 20MB/s, the device itself should report speeds in some parts of the IDENTIFY command output from 0xEC or 0xA1, but DMA/UDMA would usually be faster than any PIO.

    • @alexloktionoff6833
      @alexloktionoff6833 4 місяці тому

      I've looked into the link, and could find only mention about different signal DIOR/DIOW/IORDY timings. I think it makes sense only for PCI IDE adapters, for ISA 8MHz bus clock is the limit. So polling code will be the same for all PIO modes? So what is really the difference for programmer? @@QuesoFuego

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      Polling would the the same, yes. The speed and transfer rate would be different, but that's about it

    • @alexloktionoff6833
      @alexloktionoff6833 4 місяці тому

      Thank you@@QuesoFuego

  • @Mali.97
    @Mali.97 4 місяці тому

    Love this UEFI Dev series of yours !!!

  • @samborms
    @samborms 4 місяці тому

    I had some difficulties following the rhythm of the video, I can complete it and I got the same results, I am starting to understand the information, good video.

    • @QuesoFuego
      @QuesoFuego 4 місяці тому

      Thanks, I will work on making them easier to follow for the future