#include  <Uefi.h>
#include  <Library/UefiLib.h>
#include  <Library/ShellCEntryLib.h>

#include "Print9.h"

EFI_GUID gEfiPrint9ProtocolGuid =
                { 0xf05976ef, 0x83f1, 0x4f3d, 
                  { 0x86, 0x19, 0xf7, 0x59, 
                    0x5d, 0x41, 0xe5, 0x61 } };

extern EFI_BOOT_SERVICES         *gBS;

int
EFIAPI
main (
  IN int Argc,
  IN CHAR16 **Argv
  )
{
        EFI_PRINT9_PROTOCOL     *Print9Protocol;
        EFI_STATUS              Status;

        // Search for the Print9 Protocol
        Status = gBS->LocateProtocol(
                        &gEfiPrint9ProtocolGuid,
                        NULL,
                        (VOID **)&Print9Protocol
                );
        if (EFI_ERROR(Status)) {
                Print(L"Can't find Print9Protocol.\n");
                return EFI_SUCCESS;
        }
        
        Print(L"Find Print9Protocol.\n"); 
        Print9Protocol->UnicodeSPrintAsciiFormat();
        Print(L"\n"); 
        return EFI_SUCCESS;
}

