mirror of
https://gitee.com/js-yhsec/energy_storage.git
synced 2026-05-28 03:09:24 +08:00
实现系统总览、统计分析的图标数据接口
This commit is contained in:
@@ -5,6 +5,82 @@
|
||||
|
||||
#include "Operator.h"
|
||||
|
||||
struct AppData
|
||||
{
|
||||
/////////////////////////////////////////////
|
||||
/// === 系统 ===
|
||||
int64_t sysActivationTime {};
|
||||
|
||||
/////////////////////////////////////////////
|
||||
/// === 数据库 ===
|
||||
struct {
|
||||
std::string host;
|
||||
int port;
|
||||
std::string user;
|
||||
std::string passwd;
|
||||
} db;
|
||||
|
||||
/////////////////////////////////////////////
|
||||
/// === 系统统计 ===
|
||||
// 累计发电量,单位:kWh
|
||||
double electGenTatal {};
|
||||
// 累计入网电量,单位:kWh
|
||||
double electInTotal {};
|
||||
// 累计收益,单位:元
|
||||
double incomeTotal {};
|
||||
// 碳减排量, 单位:吨
|
||||
double ccers {};
|
||||
|
||||
/////////////////////////////////////////////
|
||||
/// === 环境 ===
|
||||
// 光照度
|
||||
double illuminance {};
|
||||
// 辐照度
|
||||
double irradiance {};
|
||||
// 风速
|
||||
double windspeed {};
|
||||
// 温度
|
||||
double temperature {};
|
||||
// 湿度
|
||||
double humidity {};
|
||||
|
||||
/////////////////////////////////////////////
|
||||
/// === 日统计 ===
|
||||
struct {
|
||||
// 发电量
|
||||
double electGen {};
|
||||
// 入网电量
|
||||
double electIn {};
|
||||
// 发电收益金额
|
||||
double incomeElect {};
|
||||
// 储能电量
|
||||
double electStorage {};
|
||||
// 储能次数
|
||||
int numStore {};
|
||||
// 放电电量
|
||||
double electDischarge {};
|
||||
// 放电次数
|
||||
int numDischarge {};
|
||||
// 用电电量
|
||||
double electLoad {};
|
||||
// 充电电量
|
||||
double electCharge {};
|
||||
// 充电次数
|
||||
int numCharge {};
|
||||
// 充电收益
|
||||
double incomeCharge {};
|
||||
|
||||
// 故障次数
|
||||
int numFault {};
|
||||
// 故障次数:光伏设备
|
||||
int numFaultSolar {};
|
||||
// 故障次数:储能设备
|
||||
int numFaultStorage {};
|
||||
// 故障次数:负荷设备
|
||||
int numFaultLoad {};
|
||||
} statDay;
|
||||
};
|
||||
|
||||
class Application
|
||||
{
|
||||
public:
|
||||
@@ -22,7 +98,6 @@ public:
|
||||
|
||||
void runThreadMain();
|
||||
|
||||
|
||||
void runThreadDevice();
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user