diff options
| author | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-04-25 08:19:06 +0200 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal.elmahrouss@icloud.com> | 2024-04-25 08:19:06 +0200 |
| commit | f6a38d6c14b314d7b85855f311527ede869db96f (patch) | |
| tree | 8c6dfa8f2638d14b44ffb7b091e2d69efce34711 /Private/FirmwareKit | |
| parent | 8153dc983802115951836f2b164af371ee6e3d73 (diff) | |
MHR-16: see below.
- Use QR-code to redirect to support page inside bootloader.
- Start working on NewLoader, since the PEF linker is done.
Signed-off-by: Amlal El Mahrouss <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'Private/FirmwareKit')
| -rw-r--r-- | Private/FirmwareKit/EFI/API.hxx | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/Private/FirmwareKit/EFI/API.hxx b/Private/FirmwareKit/EFI/API.hxx index 212f3686..0e2ef200 100644 --- a/Private/FirmwareKit/EFI/API.hxx +++ b/Private/FirmwareKit/EFI/API.hxx @@ -61,9 +61,11 @@ enum { inline UInt32 Platform() noexcept { return kPEMachineAMD64; } /*** - * @brief Raise Hard kernel error. + * @brief Throw an error, stop execution as well. + * @param ErrorCode error code to be print. + * @param Reason reason to be print. */ -inline void RaiseHardError(const EfiCharType *ErrorCode, +inline void ThrowError(const EfiCharType *ErrorCode, const EfiCharType *Reason) noexcept { #ifdef __DEBUG__ ST->ConOut->OutputString(ST->ConOut, L"\r\n*** STOP ***\r\n"); @@ -88,19 +90,19 @@ inline void RaiseHardError(const EfiCharType *ErrorCode, /// Show the QR code now. - constexpr auto ver = 7; + constexpr auto ver = 4; auto ecc = qr::Ecc::H; - auto str = "https://www.mahrouss-logic.com/help"; - auto len = BStrLen(L"https://www.mahrouss-logic.com/help"); + auto str = "https://el-mahrouss-logic.com/"; + auto len = BStrLen(L"https://el-mahrouss-logic.com/"); qr::Qr<ver> encoder; qr::QrDelegate encoderDelegate; - encoder.encode(str, len, ecc, -1); // Automatic mask. + encoder.encode(str, len, ecc, 0); // Manual mask 0 /// tell delegate to draw encoded QR. - encoderDelegate.draw<ver>(encoder, (kHandoverHeader->f_GOP.f_Width - encoder.side_size()) / 2, - (kHandoverHeader->f_GOP.f_Height - encoder.side_size()) - 20); + encoderDelegate.draw<ver>(encoder, (kHandoverHeader->f_GOP.f_Width - encoder.side_size()) - 20, + (kHandoverHeader->f_GOP.f_Height - encoder.side_size()) / 2); #endif // ifdef __NEWBOOT__ |
