添加电压和温度
This commit is contained in:
parent
036f9505b8
commit
e35d808b94
|
@ -10,15 +10,15 @@
|
|||
<TargetName>stm32f407</TargetName>
|
||||
<ToolsetNumber>0x4</ToolsetNumber>
|
||||
<ToolsetName>ARM-ADS</ToolsetName>
|
||||
<pArmCC>5050106::V5.05 update 1 (build 106)::ARMCC</pArmCC>
|
||||
<pCCUsed>5050106::V5.05 update 1 (build 106)::ARMCC</pCCUsed>
|
||||
<pArmCC>5060960::V5.06 update 7 (build 960)::.\ARMCC</pArmCC>
|
||||
<pCCUsed>5060960::V5.06 update 7 (build 960)::.\ARMCC</pCCUsed>
|
||||
<uAC6>0</uAC6>
|
||||
<TargetOption>
|
||||
<TargetCommonOption>
|
||||
<Device>STM32F407ZGTx</Device>
|
||||
<Vendor>STMicroelectronics</Vendor>
|
||||
<PackID>Keil.STM32F4xx_DFP.2.16.0</PackID>
|
||||
<PackURL>http://www.keil.com/pack/</PackURL>
|
||||
<PackID>Keil.STM32F4xx_DFP.3.0.0</PackID>
|
||||
<PackURL>https://www.keil.com/pack/</PackURL>
|
||||
<Cpu>IRAM(0x20000000,0x00020000) IRAM2(0x10000000,0x00010000) IROM(0x08000000,0x00100000) CPUTYPE("Cortex-M4") FPU2 CLOCK(12000000) ELITTLE</Cpu>
|
||||
<FlashUtilSpec></FlashUtilSpec>
|
||||
<StartupFile></StartupFile>
|
||||
|
@ -187,7 +187,6 @@
|
|||
<RvdsVP>2</RvdsVP>
|
||||
<RvdsMve>0</RvdsMve>
|
||||
<RvdsCdeCp>0</RvdsCdeCp>
|
||||
<nBranchProt>0</nBranchProt>
|
||||
<hadIRAM2>1</hadIRAM2>
|
||||
<hadIROM2>0</hadIROM2>
|
||||
<StupSel>8</StupSel>
|
||||
|
@ -1068,8 +1067,8 @@
|
|||
<TargetCommonOption>
|
||||
<Device>STM32F407VGTx</Device>
|
||||
<Vendor>STMicroelectronics</Vendor>
|
||||
<PackID>Keil.STM32F4xx_DFP.2.16.0</PackID>
|
||||
<PackURL>http://www.keil.com/pack/</PackURL>
|
||||
<PackID>Keil.STM32F4xx_DFP.3.0.0</PackID>
|
||||
<PackURL>https://www.keil.com/pack/</PackURL>
|
||||
<Cpu>IRAM(0x20000000,0x00020000) IRAM2(0x10000000,0x00010000) IROM(0x08000000,0x00100000) CPUTYPE("Cortex-M4") FPU2 CLOCK(12000000) ELITTLE</Cpu>
|
||||
<FlashUtilSpec></FlashUtilSpec>
|
||||
<StartupFile></StartupFile>
|
||||
|
@ -1238,7 +1237,6 @@
|
|||
<RvdsVP>2</RvdsVP>
|
||||
<RvdsMve>0</RvdsMve>
|
||||
<RvdsCdeCp>0</RvdsCdeCp>
|
||||
<nBranchProt>0</nBranchProt>
|
||||
<hadIRAM2>1</hadIRAM2>
|
||||
<hadIROM2>0</hadIROM2>
|
||||
<StupSel>8</StupSel>
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -21,13 +21,22 @@ extern "C" {
|
|||
|
||||
typedef struct {
|
||||
const char* key; // JSON 中的键,比如 "BCU_2"
|
||||
uint8_t groupId; // mqtt因为json长度限制,这里面用于分组传输,从0开始,
|
||||
uint16_t input; // get_val的入参,用于获取key对应的数据
|
||||
uint8_t groupId; // mqtt因为json长度限制,这里面用于分组传输,从0开始,
|
||||
uint16_t input; // get_val的入参,用于获取key对应的数据
|
||||
uint32_t (*get_val)(uint16_t); // 对应值的获取函数
|
||||
} devPointMap;
|
||||
|
||||
typedef struct {
|
||||
const char* key; // JSON 中的键,比如 "BCU_"后面不带数字,数据后面通过BCU_pointId组合
|
||||
uint16_t pointId; // 用于记录开始的测点号,见bcu模型
|
||||
uint16_t startCellIndex; // 开始的电压序号(入参)
|
||||
uint16_t endCellIndex; // 结束的电压序号(入参)
|
||||
uint32_t (*get_val)(uint16_t); // 对应值的获取函数
|
||||
} devCellPointMap;
|
||||
|
||||
extern const devPointMap bms_points[];
|
||||
extern const devCellPointMap bms_volt_points[];
|
||||
extern const devCellPointMap bms_temp_points[];
|
||||
|
||||
void mqtt_publish_bms_data(uint32_t basetime);
|
||||
|
||||
|
|
|
@ -20,7 +20,9 @@ extern "C" {
|
|||
#include "drv_rtc.h"
|
||||
|
||||
typedef struct {
|
||||
const char* key; // JSON 中的键,比如 "BCU_2"
|
||||
const char* key; // JSON 中的键,比如 "BCU_2"
|
||||
uint8_t groupId; // mqtt因为json长度限制,这里面用于分组传输,从0开始,
|
||||
uint16_t input; // get_val的入参,用于获取key对应的数据
|
||||
uint32_t (*get_val)(uint16_t); // 对应值的获取函数
|
||||
} devPointMap;
|
||||
|
||||
|
|
Loading…
Reference in New Issue