Changed CurrentTime to a static variable and added function for getting the current time instead

Global variables are really bad practice and should be avoided
This commit is contained in:
Kristian Sloth Lauszus
2018-03-11 17:59:23 +01:00
parent 8f4fc1da8e
commit 6e2eca7829
5 changed files with 10 additions and 9 deletions

View File

@@ -22,7 +22,7 @@ void UsbCommand_GetDebugBuffer(void)
SetDebugBufferUint32(13, I2cWatchdog_RecoveryCounter);
SetDebugBufferUint32(17, KeyScannerCounter);
SetDebugBufferUint32(21, UsbReportUpdateCounter);
SetDebugBufferUint32(25, CurrentTime);
SetDebugBufferUint32(25, Timer_GetCurrentTime());
SetDebugBufferUint32(29, UsbGenericHidActionCounter);
SetDebugBufferUint32(33, UsbBasicKeyboardActionCounter);
SetDebugBufferUint32(37, UsbMediaKeyboardActionCounter);