xiugai
This commit is contained in:
@@ -30,8 +30,7 @@ static bool sendTarget(Serial &serial, double yaw_deg, double pitch_deg, double
|
||||
#endif
|
||||
|
||||
// ---- 新格式: 字符串帧 ----
|
||||
// 格式: "# s <type> <yaw_int> <pitch_int> *\n"
|
||||
// type: 'r'=红色装甲板, 'b'=蓝色, 'u'=未知
|
||||
// 格式: "s <yaw_int> <pitch_int> <dist> <shoot_delay> e\n"
|
||||
int16_t yaw_tmp = static_cast<int16_t>(yaw_deg / ANGLE_SCALE);
|
||||
int16_t pitch_tmp = static_cast<int16_t>(pitch_deg / ANGLE_SCALE);
|
||||
std::string frame = fmt::format("s {} {} {} {} e\n", yaw_tmp, pitch_tmp, dist, shoot_delay);
|
||||
|
||||
Reference in New Issue
Block a user