Create Mission Select screen

This commit is contained in:
2023-03-06 23:42:01 +01:00
parent 8a2bdc347c
commit 7476e09fed
76 changed files with 46727 additions and 414 deletions

View File

@ -10,5 +10,13 @@ KEEP extern const uint32_t indicesGb[] TEXT_LOCATION_FLASH_ATTRIBUTE;
// Remap all strings
TEXT_LOCATION_FLASH_PRAGMA
KEEP extern const uint32_t indicesGb[] TEXT_LOCATION_FLASH_ATTRIBUTE = {
0 // T___SINGLEUSE_6GPV: "FaSTTUBe"
33, // T_MANUAL: "Manual Driving"
61, // T_INSPECTION: "Inspection"
93, // T_EBS: "EBS Test"
72, // T_TRACKDRIVE: "Trackdrive"
83, // T_AUTOX: "Autocross"
102, // T_SKIDPAD: "Skidpad"
48, // T_ACCEL: "Acceleration"
17, // T___SINGLEUSE_M5X7: "Invalid Mission"
0 // T___SINGLEUSE_6GPV: "Choose a mission"
};

View File

@ -60,7 +60,15 @@ extern const touchgfx::TypedText::TypedTextData* const typedTextDatabaseArray[];
TEXT_LOCATION_FLASH_PRAGMA
KEEP extern const touchgfx::Unicode::UnicodeChar texts_all_languages[] TEXT_LOCATION_FLASH_ATTRIBUTE = {
0x46, 0x61, 0x53, 0x54, 0x54, 0x55, 0x42, 0x65, 0x0 // @0 "FaSTTUBe"
0x43, 0x68, 0x6f, 0x6f, 0x73, 0x65, 0x20, 0x61, 0x20, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x0, // @0 "Choose a mission"
0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20, 0x4d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x0, // @17 "Invalid Mission"
0x4d, 0x61, 0x6e, 0x75, 0x61, 0x6c, 0x20, 0x44, 0x72, 0x69, 0x76, 0x69, 0x6e, 0x67, 0x0, // @33 "Manual Driving"
0x41, 0x63, 0x63, 0x65, 0x6c, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x0, // @48 "Acceleration"
0x49, 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x0, // @61 "Inspection"
0x54, 0x72, 0x61, 0x63, 0x6b, 0x64, 0x72, 0x69, 0x76, 0x65, 0x0, // @72 "Trackdrive"
0x41, 0x75, 0x74, 0x6f, 0x63, 0x72, 0x6f, 0x73, 0x73, 0x0, // @83 "Autocross"
0x45, 0x42, 0x53, 0x20, 0x54, 0x65, 0x73, 0x74, 0x0, // @93 "EBS Test"
0x53, 0x6b, 0x69, 0x64, 0x70, 0x61, 0x64, 0x0 // @102 "Skidpad"
};
TEXT_LOCATION_FLASH_PRAGMA

View File

@ -6,13 +6,13 @@
#include <texts/TypedTextDatabase.hpp>
extern touchgfx::GeneratedFont& getFont_verdana_20_4bpp();
extern touchgfx::GeneratedFont& getFont_verdana_40_4bpp();
extern touchgfx::GeneratedFont& getFont_verdana_10_4bpp();
extern touchgfx::GeneratedFont& getFont_CHINN____30_4bpp();
extern touchgfx::GeneratedFont& getFont_CHINN____20_4bpp();
const touchgfx::Font* touchgfx_fonts[] = {
&(getFont_verdana_20_4bpp()),
&(getFont_verdana_40_4bpp()),
&(getFont_verdana_10_4bpp())
&(getFont_CHINN____30_4bpp()),
&(getFont_CHINN____20_4bpp())
};
extern const touchgfx::TypedText::TypedTextData typedText_database_DEFAULT[];
@ -20,7 +20,15 @@ extern const touchgfx::TypedText::TypedTextData* const typedTextDatabaseArray[];
TEXT_LOCATION_FLASH_PRAGMA
const touchgfx::TypedText::TypedTextData typedText_database_DEFAULT[] TEXT_LOCATION_FLASH_ATTRIBUTE = {
{ 0, touchgfx::LEFT, touchgfx::TEXT_DIRECTION_LTR }
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 2, touchgfx::CENTER, touchgfx::TEXT_DIRECTION_LTR },
{ 1, touchgfx::LEFT, touchgfx::TEXT_DIRECTION_LTR }
};
TEXT_LOCATION_FLASH_PRAGMA
@ -60,10 +68,10 @@ void resetFont(touchgfx::FontId fontId)
touchgfx_fonts[0] = &(getFont_verdana_20_4bpp());
break;
case 1:
touchgfx_fonts[1] = &(getFont_verdana_40_4bpp());
touchgfx_fonts[1] = &(getFont_CHINN____30_4bpp());
break;
case 2:
touchgfx_fonts[2] = &(getFont_verdana_10_4bpp());
touchgfx_fonts[2] = &(getFont_CHINN____20_4bpp());
break;
}
}