@@ 258,7 258,7 @@ package body NFC_Tags is
TLV_Len => Len,
Found => Status);
if Status then
- AVR.UART.Put ("NDEF message at ");
+ Print_Str (PM_Strings.NDEF_Message_At_PM'Address);
AVR.UART.Put (Data => NDEF_Loc, Base => 10);
AVR.UART.CRLF;
@@ 267,11 267,11 @@ package body NFC_Tags is
Print_NDEF_Record (NFC_Data, NDEF_Header);
end if;
else
- AVR.UART.Put ("No NDEF TLV found");
+ Print_Str (PM_Strings.No_NDEF_TLV_Found_PM'Address);
AVR.UART.CRLF;
end if;
else
- AVR.UART.Put ("Failed to read block from the tag");
+ Print_Str (PM_Strings.Failed_To_Read_Block_PM'Address);
AVR.UART.CRLF;
end if;
end Read_Forum_Type_2_Tag;
@@ 302,7 302,7 @@ package body NFC_Tags is
Buf => Block,
Status => Status);
if not Status then
- AVR.UART.Put ("Failed to write block");
+ Print_Str (PM_Strings.Failed_To_Write_Block_PM'Address);
AVR.UART.CRLF;
exit;
else
@@ 39,6 39,10 @@ package PM_Strings is
Type_2_Tag_Str : constant AVR.Strings.AVR_String := "NFC Forum Type 2 tag";
Type_4_Tag_Failed_Str : constant AVR.Strings.AVR_String := "Failed to select type 4 tag";
BLOCK_Str : constant AVR.Strings.AVR_String := "BLOCK ";
+ Failed_To_Read_Block_Str : constant AVR.Strings.AVR_String := "Failed to read block from the tag";
+ No_NDEF_TLV_Found_Str : constant AVR.Strings.AVR_String := "No NDEF TLV found";
+ Failed_To_Write_Block_Str : constant AVR.Strings.AVR_String := "Failed to write block";
+ NDEF_Message_At_Str : constant AVR.Strings.AVR_String := "NDEF message at ";
Select_Action_PM : constant Text_In_Progmem := (Select_Action_Str'Length, Select_Action_Str);
Read_NFC_PM : constant Text_In_Progmem := (Read_NFC_Str'Length, Read_NFC_Str);
@@ 56,6 60,10 @@ package PM_Strings is
Type_2_Tag_PM : constant Text_In_Progmem := (Type_2_Tag_Str'Length, Type_2_Tag_Str);
Type_4_Tag_Failed_PM : constant Text_In_Progmem := (Type_4_Tag_Failed_Str'Length, Type_4_Tag_Failed_Str);
BLOCK_PM : constant Text_In_Progmem := (BLOCK_Str'Length, BLOCK_STR);
+ Failed_To_Read_Block_PM : constant Text_In_Progmem := (Failed_To_Read_Block_Str'Length, Failed_To_Read_Block_Str);
+ No_NDEF_TLV_Found_PM : constant Text_In_Progmem := (No_NDEF_TLV_Found_Str'Length, No_NDEF_TLV_Found_Str);
+ Failed_To_Write_Block_PM : constant Text_In_Progmem := (Failed_To_Write_Block_Str'Length, Failed_To_Write_Block_Str);
+ NDEF_Message_At_PM : constant Text_In_Progmem := (NDEF_Message_At_Str'Length, NDEF_Message_At_Str);
pragma Linker_Section (Select_Action_PM, ".progmem");
pragma Linker_Section (Read_NFC_PM, ".progmem");
@@ 73,4 81,8 @@ package PM_Strings is
pragma Linker_Section (Type_2_Tag_PM, ".progmem");
pragma Linker_Section (Type_4_Tag_Failed_PM, ".progmem");
pragma Linker_Section (BLOCK_PM, ".progmem");
+ pragma Linker_Section (Failed_To_Read_Block_PM, ".progmem");
+ pragma Linker_Section (No_NDEF_TLV_Found_PM, ".progmem");
+ pragma Linker_Section (Failed_To_Write_Block_PM, ".progmem");
+ pragma Linker_Section (NDEF_Message_At_PM, ".progmem");
end PM_Strings;