Load File from Disk Blocks & Other Abstractions | UEFI Dev (in C)

Поділитися
Вставка
  • Опубліковано 3 лип 2024
  • 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 filter in OBS, so Fs and Ss and words in general should be less cut off now.
    Links:
    uefi.org/specifications (uefi & other specifications)
    UEFI Programming playlist:
    • UEFI Programming in C
    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 53054ca1c0d2f3c172d377f1bccb6638dc328632
    Repo state at the end of this video:
    git checkout 20ff7f39ba9ca2aade5ffce975b9ff08ee8e2044
    Next video:
    - Loading and running a separate program to draw to the GOP framebuffer, to later act as an OS kernel so this can be an actual bootloader. Will load and run plain binary, ELF, and PE programs, all of them 64 bit position independant executables (PIE files).
    Join the Community Discord: / discord
    Contact:
    queso_fuego.srht.site/contact.html
    - Let me know if there's anything specific you'd like to see!
    Questions about setup/software/etc.?
    Check the FAQ: queso_fuego.srht.site/about.html
    0:00:00 intro, plan for this video
    0:01:34 menu option to read file, outline logic
    0:07:33 function to read ESP file into buffer
    0:33:27 logic to parse DATAFLS.INF file for info
    0:42:25 strstr, strlen, isdigit (ignore broken strcmp)
    1:02:44 functions to get disk blocks into buffer & get mediaID
    1:33:02 print test data from buffer, small setup for next video
    Music credits:
    [Chiptune] Medieval: Minstrel Dance by RandomMind
    Music: www.chosic.com/free-music/all/
    #uefidev #cprogramming #loadingfiles
  • Наука та технологія

КОМЕНТАРІ • 5

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

    nice!

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

    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 місяці тому +1

      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.

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

    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