diff --git a/backends/kiibohd.py b/backends/kiibohd.py index 1abf8e5..b29c465 100644 --- a/backends/kiibohd.py +++ b/backends/kiibohd.py @@ -129,7 +129,7 @@ class Backend: ## Result Macro List ## - self.fill_dict['ResultMacroList'] = "ResultMacro ResultMacroList[] = {\n" + self.fill_dict['ResultMacroList'] = "const ResultMacro ResultMacroList[] = {\n" # Iterate through each of the result macros for result in range( 0, len( macros.resultsIndexSorted ) ): @@ -137,6 +137,10 @@ class Backend: self.fill_dict['ResultMacroList'] += "};" + ## Result Macro Record ## + self.fill_dict['ResultMacroRecord'] = "ResultMacroRecord ResultMacroRecordList[ ResultMacroNum ];" + + ## Trigger Macros ## self.fill_dict['TriggerMacros'] = "" @@ -164,7 +168,7 @@ class Backend: ## Trigger Macro List ## - self.fill_dict['TriggerMacroList'] = "TriggerMacro TriggerMacroList[] = {\n" + self.fill_dict['TriggerMacroList'] = "const TriggerMacro TriggerMacroList[] = {\n" # Iterate through each of the trigger macros for trigger in range( 0, len( macros.triggersIndexSorted ) ): @@ -173,6 +177,10 @@ class Backend: self.fill_dict['TriggerMacroList'] += "};" + ## Trigger Macro Record ## + self.fill_dict['TriggerMacroRecord'] = "TriggerMacroRecord TriggerMacroRecordList[ TriggerMacroNum ];" + + ## Max Scan Code ## self.fill_dict['MaxScanCode'] = "#define MaxScanCode 0x{0:X}".format( macros.overallMaxScanCode ) diff --git a/templates/kiibohdKeymap.h b/templates/kiibohdKeymap.h index 2d0c293..49ca35b 100644 --- a/templates/kiibohdKeymap.h +++ b/templates/kiibohdKeymap.h @@ -45,6 +45,12 @@ <|ResultMacroList|> +// -- Trigger Macro Record + +// Keeps a record/state of each result macro +<|ResultMacroRecord|> + + // -- Trigger Macros // Trigger Macro Guides @@ -57,6 +63,12 @@ <|TriggerMacroList|> +// -- Trigger Macro Record List + +// Keeps a record/state of each trigger macro +<|TriggerMacroRecord|> + + // ----- Trigger Maps -----