Ajout polling du statut du board
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include "GeneralMessagesLogDispatcher.h"
|
||||
#include "CPUWatchdogConfig.h"
|
||||
|
||||
|
||||
CComputerBoardInterface::CComputerBoardInterface()
|
||||
{
|
||||
mWatchdogTimeout = CPU_DEFAULT_WATCHDOG_TIMEOUT;
|
||||
@@ -119,4 +120,39 @@ int CComputerBoardInterface::SetWatchdogSettings(CCPUWatchdogConfig *Settings)
|
||||
{
|
||||
mWatchdogEnabled = Settings->mWatchdogEnabled;
|
||||
mWatchdogTimeout = Settings->mWatchdogTimeout;
|
||||
|
||||
return RET_OK;
|
||||
}
|
||||
|
||||
CComputerBoardState CComputerBoardInterface::GetComputerBoardState()
|
||||
{
|
||||
CComputerBoardState CPUState;
|
||||
|
||||
float tmp;
|
||||
|
||||
AxGetCPUTemp(&CPUState.mSystemTemperature);
|
||||
// qDebug("CPUState.mSystemTemperature %f",CPUState.mSystemTemperature);
|
||||
AxGetSYSTemp(&CPUState.mSystemTemperature);
|
||||
// qDebug("CPUState.mSystemTemperature %f",CPUState.mSystemTemperature);
|
||||
// AxGetGMCHTemp(&tmp);
|
||||
// qDebug("AxGetGMCHTemp %f",tmp);
|
||||
AxGetCPUVcore(&CPUState.mCPUVcore);
|
||||
// qDebug("CPUState.mCPUVcore %f",CPUState.mCPUVcore);
|
||||
// AxGetNBVTT(&tmp);
|
||||
// qDebug("NBVTT %f",tmp);
|
||||
AxGet3V(&CPUState.mSystem3V3);
|
||||
// qDebug("CPUState.mSystem3V3 %f",CPUState.mSystem3V3);
|
||||
AxGet5V(&CPUState.mSystem5V);
|
||||
// qDebug("CPUState.mSystem5V %f",CPUState.mSystem5V);
|
||||
// AxGet12V(&tmp);
|
||||
// qDebug("AxGet12V %f",tmp);
|
||||
// AxGetNeg5V(&tmp);
|
||||
// qDebug("AxGetNeg5V %f",tmp);
|
||||
// AxGetNeg12V(&tmp);
|
||||
// qDebug("AxGetNeg12V %f",tmp);
|
||||
// AxGetVbat(&tmp);
|
||||
// qDebug("AxGetVbat %f",tmp);
|
||||
|
||||
return CPUState;
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user