![BMS24串上位机 12串上位机 2级菊花链 上位机](https://img-blog.csdnimg.cn/direct/fb4575074009410a807b008941c60096.png)
```c
if (buffer[0] == 0xAA && buffer[1] == 0x01 )
{
num++;
data_package.Text = num.ToString();
clean1_all();
textBox1.AppendText(num.ToString());
textBox1.AppendText(" 已接收电池串1信息!\r\n");
V1_Box.Text = ((buffer[2] << 8) + buffer[3]).ToString();
V2_Box.Text = ((buffer[4] << 8) + buffer[5]).ToString();
V3_Box.Text = ((buffer[6] << 8) + buffer[7]).ToString();
V4_Box.Text = ((buffer[8] << 8) + buffer[9]).ToString();
V5_Box.Text = ((buffer[10] << 8) + buffer[11]).ToString();
V6_Box.Text = ((buffer[12] << 8) + buffer[13]).ToString();
V7_Box.Text = ((buffer[14] << 8) + buffer[15]).ToString();
V8_Box.Text = ((buffer[16] << 8) + buffer[17]).ToString();
V9_Box.Text = ((buffer[18] << 8) + buffer[19]).ToString();
V10_Box.Text = ((buffer[20] << 8) + buffer[21]).ToString();
V11_Box.Text = ((buffer[22] << 8) + buffer[23]).ToString();
V12_Box.Text = ((buffer[24] << 8) + buffer[25]).ToString();
tol1_V_Box.Text =( (buffer[32] << 8) + buffer[33]).ToString();
SOC1_Box.Text = ((buffer[34] << 8) + buffer[35]).ToString();
progressBar1.Value = Convert.ToInt32(SOC1_Box.Text);
cur1_Box.Text = ((buffer[36] << 8) + buffer[37]).ToString();
temp1_1_Box.Text = buffer[38].ToString();
temp1_2_Box.Text = buffer[45].ToString();
if (buffer[58] != 0)
{
DSG_STA.Text = ("开启");
}
else { DSG_STA.Text = ("关闭"); }
if (buffer[59] != 0)
{
CHG_STA.Text = ("开启");
}
else { CHG_STA.Text = ("关闭"); }
MAX1_V_Box.Text = ((buffer[41] << 8) + buffer[42]).ToString();
MIN1_V_Box.Text = ((buffer[43] << 8) + buffer[44]).ToString();
Diff1_V_Box.Text = ((buffer[41] << 8) + buffer[42] - ((buffer[43] << 8) + buffer[44])).ToString();
}
![通信协议](https://img-blog.csdnimg.cn/direct/9113a427ffd64e7baf358df94deeefe7.png)
有需要的同学可以跟楼主私信要上位机