aboutsummaryrefslogtreecommitdiffstats
path: root/Lessons/Lesson_19/UefiLessonsPkg/HelloWorld/HelloWorld.c
blob: 29a4812d3be23256dd84ddf4ae8c96cedcbbd6ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <Library/UefiBootServicesTableLib.h>
#include <Library/UefiLib.h>

EFI_STATUS
EFIAPI
UefiMain (
  IN EFI_HANDLE        ImageHandle,
  IN EFI_SYSTEM_TABLE  *SystemTable
  )
{
  SystemTable->ConOut->OutputString(SystemTable->ConOut, L"Hello World!\n");
  gST->ConOut->OutputString(gST->ConOut, L"Hello again!\n");
  Print(L"Bye!\n");

  UINTN Index;
  gBS->WaitForEvent(1, &(gST->ConIn->WaitForKey), &Index);
  gST->ConIn->Reset(gST->ConIn, FALSE);
  return EFI_SUCCESS;
}