Rev 2726 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2726 | Rev 3386 | ||
---|---|---|---|
1 | #include <efi.h> |
1 | #include <efi.h> |
2 | #include <efilib.h> |
2 | #include <efilib.h> |
3 | 3 | ||
4 | EFI_STATUS |
4 | EFI_STATUS |
5 | efi_main (EFI_HANDLE image, EFI_SYSTEM_TABLE *systab) |
5 | efi_main (EFI_HANDLE image, EFI_SYSTEM_TABLE *systab) |
6 | { |
6 | { |
7 | EFI_INPUT_KEY efi_input_key; |
7 | EFI_INPUT_KEY efi_input_key; |
8 | EFI_STATUS efi_status; |
8 | EFI_STATUS efi_status; |
9 | 9 | ||
10 | InitializeLib(image, systab); |
10 | InitializeLib(image, systab); |
11 | 11 | ||
12 | Print(L"HelloLib application started\n"); |
12 | Print(L"HelloLib application started\n"); |
13 | 13 | ||
14 | Print(L"\n\n\nHit any key to exit this image\n"); |
14 | Print(L"\n\n\nHit any key to exit this image\n"); |
15 | WaitForSingleEvent(ST->ConIn->WaitForKey, 0); |
15 | WaitForSingleEvent(ST->ConIn->WaitForKey, 0); |
16 | 16 | ||
17 | ST->ConOut->OutputString(ST->ConOut, L"\n\n"); |
17 | ST->ConOut->OutputString(ST->ConOut, L"\n\n"); |
18 | 18 | ||
19 | efi_status = ST->ConIn->ReadKeyStroke(ST->ConIn, &efi_input_key); |
19 | efi_status = ST->ConIn->ReadKeyStroke(ST->ConIn, &efi_input_key); |
20 | 20 | ||
21 | Print(L"ScanCode: %xh UnicodeChar: %xh\n", |
21 | Print(L"ScanCode: %xh UnicodeChar: %xh\n", |
22 | efi_input_key.ScanCode, efi_input_key.UnicodeChar); |
22 | efi_input_key.ScanCode, efi_input_key.UnicodeChar); |
23 | 23 | ||
24 | return EFI_SUCCESS; |
24 | return EFI_SUCCESS; |
25 | } |
25 | } |
26 | 26 |