【动力学信息增加加速度属性】

This commit is contained in:
weizhihong 2023-10-07 16:40:24 +08:00
parent ff2ac2b74a
commit 9f88fcdaf8
2 changed files with 3 additions and 0 deletions

View File

@ -241,6 +241,7 @@ func decoderDynamicsTrainInfo(buf []byte) *TrainInfo {
trainInfo.TailSpeed2 = math.Float32frombits(binary.BigEndian.Uint32(buf[46:50]))
trainInfo.HeadRadarSpeed = math.Float32frombits(binary.BigEndian.Uint32(buf[50:54]))
trainInfo.TailRadarSpeed = math.Float32frombits(binary.BigEndian.Uint32(buf[54:58]))
trainInfo.Acceleration = math.Float32frombits(binary.BigEndian.Uint32(buf[58:61]))
return trainInfo
}

View File

@ -46,4 +46,6 @@ type TrainInfo struct {
HeadRadarSpeed float32
//尾车雷达速度值m/s
TailRadarSpeed float32
//加速度(m/s^2)
Acceleration float32
}