0
0

Initial commit from DCSP - 2026/1/15 15:11:58

This commit is contained in:
xb
2026-01-15 15:11:58 +08:00
commit c93536b187
100 changed files with 59765 additions and 0 deletions

View File

@@ -0,0 +1,49 @@
#ifndef _SENSOR_ORBIT_INFO_H_
#define _SENSOR_ORBIT_INFO_H_
#include <stdint.h>
#include <iostream>
using namespace std;
/// @brief 步进指令和步进反馈指令中的公共部分
typedef struct __attribute__((packed))
{
uint8_t pack_id; //节点编号
double posi_x_J2000; //X轴位置
double posi_y_J2000; //Y轴位置
double posi_z_J2000; //Z轴位置
double velo_x_J2000; //X轴速度
double velo_y_J2000; //Y轴速度
double velo_z_J2000; //Z轴速度
double q0_J2000; //惯性系四元数
double q1_J2000;
double q2_J2000;
double q3_J2000;
} BASIC_CMDER;
/// @brief 步进反馈指令
typedef struct __attribute__((packed))
{
double Epoch; //历元时间
BASIC_CMDER resCmder;
} STEP_CMDER_RES;
uint8_t orbit_info_initz(string path);
uint8_t set_orbit_info(uint8_t *frame,double AttiVelECI[3], double EulerVVLH[3], double AttiMtxVVLH[3][3], double MtxECI2VVLH[3][3]);
uint8_t get_orbit_info(uint8_t *frame,uint8_t id);
uint8_t generate_orbit_info(double orbInfo[6], double Tar_orbInfo[6], double AttiVelECI[3],
double EulerVVLH[3], double AttiMtxVVLH[3][3], double MtxECI2VVLH[3][3],
double* mjd, double* Epoch2017,
double SatMass, double SatMtxI[3][3], double ThrustForce[3], double Tq[3], double WheelAM[3]);
uint8_t get_orbit_epoic(double *Epoch);
uint8_t get_orbit_posi(double *posi);
uint8_t get_orbit_velo(double *velo);
uint8_t get_orbit_Q(double *Q);
uint8_t get_orbit_flag(void);
//double get_orbit_mjd(void);
uint8_t get_orbit_source_flag(void);
#endif