完成基于bsp的bmi088编写,更新can comm的CAN配置

This commit is contained in:
NeoZng
2023-04-13 16:09:03 +08:00
parent 4a2bc01525
commit ec005f163c
8 changed files with 77 additions and 115 deletions

View File

@@ -174,6 +174,12 @@ float* Norm3d(float* v)
return v;
}
// 计算模长
float NormOf3d(float *v)
{
return Sqrt(v[0] * v[0] + v[1] * v[1] + v[2] * v[2]);
}
// 三维向量叉乘v1 x v2
void Cross3d(float* v1, float* v2,float* res)
{

View File

@@ -88,7 +88,7 @@ extern uint8_t GlobalDebugMode;
#define VAL_MAX(a, b) ((a) > (b) ? (a) : (b))
/**
* @brief 返回一块干净的内<E79A84><EFBFBD>?,不过仍然需要强制转<E588B6><EFBFBD>?为你需要的类型
* @brief 返回一块干净的内<E79A84>?,不过仍然需要强制转<E588B6>?为你需要的类型
*
* @param size 分配大小
* @return void*
@@ -116,6 +116,8 @@ int float_rounding(float raw);
float* Norm3d(float* v);
float NormOf3d(float* v);
void Cross3d(float* v1, float* v2, float* res);
float Dot3d(float* v1, float* v2);