This commit is contained in:
Fancy code 2024-03-06 00:23:17 -08:00
parent d3dca44f91
commit b4d5fa020d
5 changed files with 26 additions and 8 deletions

View File

@ -1,3 +1,17 @@
/*
* Copyright (c) 2023 Fancy Code.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "AppMonitor.h" #include "AppMonitor.h"
#include "ILog.h" #include "ILog.h"
StatusCode AppMonitor::GetProductInfo(AppGetProductInfo &param) StatusCode AppMonitor::GetProductInfo(AppGetProductInfo &param)
@ -11,6 +25,7 @@ StatusCode AppMonitor::GetProductInfo(AppGetProductInfo &param)
} }
StatusCode AppMonitor::GetDeviceAttr(AppGetDeviceAttr &param) StatusCode AppMonitor::GetDeviceAttr(AppGetDeviceAttr &param)
{ {
LogInfo("AppMonitor::GetDeviceAttr.\n");
param.mUUID = "test"; param.mUUID = "test";
param.mSoftVersion = "test"; param.mSoftVersion = "test";
param.mOtaVersion = "test"; param.mOtaVersion = "test";
@ -24,6 +39,7 @@ StatusCode AppMonitor::GetDeviceAttr(AppGetDeviceAttr &param)
} }
StatusCode AppMonitor::GetMediaInfo(AppGetMeidaInfo &param) StatusCode AppMonitor::GetMediaInfo(AppGetMeidaInfo &param)
{ {
LogInfo("AppMonitor::GetMediaInfo.\n");
param.mRtspUrl = "test"; param.mRtspUrl = "test";
param.mTransport = "test"; param.mTransport = "test";
param.mPort = 123; param.mPort = 123;
@ -31,6 +47,7 @@ StatusCode AppMonitor::GetMediaInfo(AppGetMeidaInfo &param)
} }
StatusCode AppMonitor::GetSdCardInfo(AppGetSdCardInfo &param) StatusCode AppMonitor::GetSdCardInfo(AppGetSdCardInfo &param)
{ {
LogInfo("AppMonitor::GetSdCardInfo.\n");
param.mStatus = SdCardStatus::CARD_DAMAGED; param.mStatus = SdCardStatus::CARD_DAMAGED;
param.mFree = 0; param.mFree = 0;
param.mTotal = 0; param.mTotal = 0;
@ -38,6 +55,7 @@ StatusCode AppMonitor::GetSdCardInfo(AppGetSdCardInfo &param)
} }
StatusCode AppMonitor::GetBatteryInfo(AppGetBatteryInfo &param) StatusCode AppMonitor::GetBatteryInfo(AppGetBatteryInfo &param)
{ {
LogInfo("AppMonitor::GetBatteryInfo.\n");
param.mCapacity = 0; param.mCapacity = 0;
param.mChargeStatus = ChargeStatus::CHARGING; param.mChargeStatus = ChargeStatus::CHARGING;
return CreateStatusCode(STATUS_CODE_OK); return CreateStatusCode(STATUS_CODE_OK);

View File

@ -12,8 +12,8 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
#ifndef DATAPROCESSING_H #ifndef DATA_PROCESSING_H
#define DATAPROCESSING_H #define DATA_PROCESSING_H
#include "IMissionManager.h" #include "IMissionManager.h"
#include "IStateMachine.h" #include "IStateMachine.h"
#include <functional> #include <functional>

View File

@ -12,8 +12,8 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
#ifndef MISSIONMANAGER_H #ifndef MISSION_MANAGER_H
#define MISSIONMANAGER_H #define MISSION_MANAGER_H
#include "IMissionManager.h" #include "IMissionManager.h"
class MissionManager : public IMissionManager class MissionManager : public IMissionManager
{ {

View File

@ -12,8 +12,8 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
#ifndef MISSIONMANAGERMAKEIMPL_H #ifndef MISSION_MANAGER_MAKE_PTR_H
#define MISSIONMANAGERMAKEIMPL_H #define MISSION_MANAGER_MAKE_PTR_H
#include "IMcuManager.h" #include "IMcuManager.h"
#include "IMissionManager.h" #include "IMissionManager.h"
#include "IStateMachine.h" #include "IStateMachine.h"

View File

@ -12,8 +12,8 @@
* See the License for the specific language governing permissions and * See the License for the specific language governing permissions and
* limitations under the License. * limitations under the License.
*/ */
#ifndef MISSIONSTATEMACHINE_H #ifndef MISSION_STATE_MACHINE_H
#define MISSIONSTATEMACHINE_H #define MISSION_STATE_MACHINE_H
// #include "IDeviceManager.h" // #include "IDeviceManager.h"
#include "IMcuManager.h" #include "IMcuManager.h"
#include "IMissionManager.h" #include "IMissionManager.h"