void mainBoardCommonMainInit(RobotConfig* robotConfig) { // LOG the BoardName appendStringCRLF(getAlwaysOutputStreamLogger(), getBoardName()); // Increase the Log Level to DEBUG if the config bit are set Logger* logger = getLoggerInstance(); if (isConfigSet(robotConfig, CONFIG_DEBUG)) { logger->globalLogLevel = LOG_LEVEL_DEBUG; } appendString(getInfoOutputStreamLogger(), "GLOBAL LEVEL : "); appendLevelAsString(getInfoOutputStreamLogger(), logger->globalLogLevel); println(getInfoOutputStreamLogger()); }
void initStartMatch(StartMatch* startMatch, RobotConfig* robotConfig, EndMatch* endMatch, IsMatchStartedFunction* isMatchStartedFunctionParam, LoopUntilStartHandleFunction* loopUntilStartHandleFunction, MatchHandleInstructionFunction* matchHandleInstructionFunction) { startMatch->robotConfig = robotConfig; startMatch->endMatch = endMatch; startMatch->isMatchStartedFunction = isMatchStartedFunctionParam; startMatch->loopUntilStartHandleFunction = loopUntilStartHandleFunction; startMatch->matchHandleInstructionFunction = matchHandleInstructionFunction; startMatch->waitForStart = !isConfigSet(robotConfig, CONFIG_DONT_WAIT_FOR_START); }
/** * As there is a problem during init to load the config. * We send it after */ void initEndMatchConfig() { doNotEnd = isConfigSet(CONFIG_DO_NOT_END); }
unsigned char isConfigBalise() { refreshConfig(); return isConfigSet(CONFIG_USE_BALISE_MASK); }