#pragma once

#include "myBase.h"
#include "mySystem.h"

typedef struct
{
    std::string saddr;
    std::string desc;
    uint16_t inf;
}stru_self_ptl_cfg_base;


typedef struct
{
    stru_self_ptl_cfg_base base;
    uint8_t type;
    std::string default_value;
    std::string unit;
    std::string min;
    std::string max;
    std::string step;
}stru_self_ptl_cfg_param;


typedef struct
{
    std::vector<stru_self_ptl_cfg_base> st_vec;
    std::vector<stru_self_ptl_cfg_base> mx_vec;
    std::vector<stru_self_ptl_cfg_base> co_vec;
    std::vector<stru_self_ptl_cfg_base> dd_vec;

    std::vector<stru_self_ptl_cfg_param> param_vec;
}stru_self_ptl_cfg;


int self_ptl_cfg_parse(const std::string &path);
stru_self_ptl_cfg* self_ptl_cfg_get();

