This commit is contained in:
Matthias Mitscherlich
2023-02-01 13:08:13 +01:00
parent 0c644d404c
commit bc0da9ec9e
3 changed files with 76 additions and 24 deletions
+9 -4
View File
@@ -54,7 +54,7 @@
Clock::Clock(Clock::mode mode)
{
Clock::currentTime = 0;
Clock::currentTime = 40000;
Clock::clockmode = mode;
@@ -71,6 +71,7 @@ void Clock::generateWordlist(list<string>* wordlist)
struct tm tm;
time(&currentTime);
// currentTime += 100;
localtime_r(&currentTime, &tm);
LOGGER_INFO("%lld\n\r", currentTime);
@@ -157,7 +158,7 @@ void Clock::generateWordlist(list<string>* wordlist)
time_t Clock::getTime(void)
{
time(&currentTime);
// time(&currentTime);
return currentTime;
}
@@ -172,11 +173,15 @@ int Clock::calculateHours(struct tm time)
}
// Calculate hours to 12hour system
if (time.tm_hour > 12)
if (hours > 12)
{
hours = hours - 12;
}
// Start at 1, not 0
if (hours == 0)
{
hours++;
}
return hours;
}
+4 -4
View File
@@ -48,10 +48,10 @@
// --------------------------------------------------------------------------------------------------------------------
static const char* ssid = "Kowalski";
static const char* pass = "madagascar";
//static const char* ssid = "vbchaos";
//static const char* pass = "mijninternet";
//static const char* ssid = "Kowalski";
//static const char* pass = "madagascar";
static const char* ssid = "vbchaos";
static const char* pass = "mijninternet";
// --------------------------------------------------------------------------------------------------------------------
// Function declarations