Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
145137a
Decrease size of telemetry data structure
ETSells May 7, 2026
7b18443
documentation for telem structure updates
ETSells May 10, 2026
45316a6
Add quat math and prototype body state
NArmistead Jun 9, 2026
ea31f2b
Remap axes
NArmistead Jun 10, 2026
c491e40
Consolidate sensor init functionality
NArmistead Jun 12, 2026
ffc7d75
Clean up and prevent merge conflict
NArmistead Jun 17, 2026
78a4b63
Merge branch 'main' into ES/telemetry-structure-update
ETSells Jun 21, 2026
86930a5
Refactor LoRa: Move async FSM to lora_async.c
ETSells Jun 22, 2026
4b4b880
Merge branch 'ES/telemetry-structure-update' into integration/state-e…
ETSells Jun 22, 2026
76e84ad
Clean old code, split IMU_DATA
NArmistead Jun 22, 2026
0092251
Merge branch 'integration/state-estims-telemetry' into na/quat-body-s…
NArmistead Jun 22, 2026
2d22655
Fix some function arguments
NArmistead Jun 22, 2026
4eccd83
Add quats to dashboard dump
NArmistead Jun 22, 2026
203e341
Remove baro velo
NArmistead Jun 22, 2026
f03bfd1
Fix dashboard dump acceleration Z value
ETSells Jun 22, 2026
fc5ca8e
Change default orientation
NArmistead Jun 22, 2026
6029961
complete comments in math_sdr and convert to doxygen style
NArmistead Jun 23, 2026
55a0ed2
Move COMP_ALPHA macro to sensor
NArmistead Jun 23, 2026
cd5f0a7
Move ST_UID_TYPE and get_uid to telemetry header
NArmistead Jun 23, 2026
91a0198
Rename mount orientaton enum
NArmistead Jun 24, 2026
1276b7b
Move comp filter to its own function, remap mag axes
NArmistead Jun 28, 2026
c0b06af
critical(TM) comment update on comp filter
NArmistead Jun 28, 2026
1edd7ae
Set axis remapping to always use right-handed coordinates
NArmistead Jun 29, 2026
61e4ecd
Undo mag axis remap
NArmistead Jun 30, 2026
e4db23e
Add handling for discarded qualifiers in the allowed emulator warnings
ETSells Jul 6, 2026
fda21c4
Telemetry: Remove text messages since their limited size inhibits the…
ETSells Jul 6, 2026
c857f8a
Comp filter updates
NArmistead Jul 9, 2026
dcaee6f
put statics where they go
NArmistead Jul 9, 2026
654bbb3
Fix gyro -> quat conv & disable acc filter temporarily
ETSells Jul 11, 2026
91d13bb
Comment out a postponed function
ETSells Jul 11, 2026
2680f5b
Try to prevent a potential hardware issue by updating dump size macro
ETSells Jul 14, 2026
719e2eb
Corrections to mount orientation
NArmistead Jul 20, 2026
2c2e9c8
Hopefully better way to do orientation
NArmistead Jul 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 9 additions & 19 deletions commands/commands.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,29 +165,19 @@ void dashboard_construct_dump
DASHBOARD_DUMP_TYPE* dump_buffer_ptr /* must be DASHBOARD_DUMP_SIZE */
)
{

/* IMU (6 axes) */
memcpy( dump_buffer_ptr,
&(sensor_data.imu_data.imu_converted),
sizeof( float ) * 6 );

/* Roll/Pitch + Rates */
dump_buffer_ptr->pitch_angle = sensor_data.imu_data.state_estimate.pitch_angle;
dump_buffer_ptr->roll_angle = sensor_data.imu_data.state_estimate.roll_angle;
dump_buffer_ptr->yaw_angle = sensor_data.imu_data.state_estimate.yaw_angle;
dump_buffer_ptr->pitch_rate = sensor_data.imu_data.state_estimate.pitch_rate;
dump_buffer_ptr->roll_rate = sensor_data.imu_data.state_estimate.roll_rate;
dump_buffer_ptr->yaw_rate = sensor_data.imu_data.state_estimate.yaw_rate;
/* Quats */
dump_buffer_ptr->attitude = sensor_data.state_estimate.attitude;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wow thats way better


/* Baro */
dump_buffer_ptr->baro_pressure = sensor_data.baro_pressure;
dump_buffer_ptr->baro_temp = sensor_data.baro_temp;
dump_buffer_ptr->baro_alt = sensor_data.baro_alt;
dump_buffer_ptr->baro_velo = sensor_data.baro_velo;
dump_buffer_ptr->alt = sensor_data.baro_alt;

/* GPS */
dump_buffer_ptr->gps_dec_longitude = sensor_data.gps_dec_longitude;
dump_buffer_ptr->gps_dec_latitude = sensor_data.gps_dec_latitude;
dump_buffer_ptr->longitude = sensor_data.gps_dec_longitude;
dump_buffer_ptr->latitude = sensor_data.gps_dec_latitude;

/* Controls */
dump_buffer_ptr->acc_z = sensor_data.imu_converted.accel_z;
dump_buffer_ptr->roll_rate = sensor_data.state_estimate.roll_rate;

}
#endif
Expand Down
25 changes: 7 additions & 18 deletions commands/commands.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ extern "C" {
/* platform specific includes */
#if defined( A0002_REV2 ) || defined( A0005_REV1 )
#include "imu.h"
#include "usb.h"
#endif

/*------------------------------------------------------------------------------
Expand Down Expand Up @@ -95,30 +96,18 @@ extern "C" {
#define FIRMWARE_RECEIVER ( 0x11 ) /* Reciever Firmware */

/* Other macros */
#define DASHBOARD_DUMP_SIZE ( 72 )
#define DASHBOARD_DUMP_SIZE ( 36 )

typedef struct __attribute__((packed)) _DASHBOARD_DUMP_TYPE
{
float acc_x;
float acc_y;
QUAT attitude;
float alt;
float latitude;
float longitude;
float acc_z;
float gyro_x;
float gyro_y;
float gyro_z;
float roll_angle;
float pitch_angle;
float yaw_angle;
float roll_rate;
float pitch_rate;
float yaw_rate;
float baro_pressure;
float baro_temp;
float baro_alt;
float baro_velo;
float gps_dec_longitude;
float gps_dec_latitude;
} DASHBOARD_DUMP_TYPE;
_Static_assert( sizeof(DASHBOARD_DUMP_TYPE) == 72, "DASHBOARD_DUMP_TYPE size invalid.");
_Static_assert( sizeof(DASHBOARD_DUMP_TYPE) == DASHBOARD_DUMP_SIZE, "DASHBOARD_DUMP_TYPE size invalid.");

/*------------------------------------------------------------------------------
Function Prototypes
Expand Down
3 changes: 2 additions & 1 deletion debug_sdr/debug_sdr.h
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,8 @@ void debug_callback_handler
#if defined( EMULATOR )
#define debug_ignore_emulator_warnings_start() \
_Pragma("GCC diagnostic push") \
_Pragma("GCC diagnostic ignored \"-Wformat\"")
_Pragma("GCC diagnostic ignored \"-Wformat\"") \
_Pragma("GCC diagnostic ignored \"-Wdiscarded-qualifiers\"")
#else
#define debug_ignore_emulator_warnings_start() /* do nothing */
#endif
Expand Down
23 changes: 15 additions & 8 deletions error_sdr/error_sdr.c
Original file line number Diff line number Diff line change
Expand Up @@ -141,19 +141,23 @@ default_error_handler.error_callback( error_code );
/*******************************************************************************
* *
* PROCEDURE: *
* error_log_warning *
* __sdr_log_warning *
* *
* DESCRIPTION: *
* Place a warning message in the buffer. *
* *
* NOTE: *
* Should be called through the error_log_warning macro for bounds *
* checking. *
* *
*******************************************************************************/
void error_log_warning
void __sdr_log_warning
(
char* message
const char* message
)
{
last_warning.systick = HAL_GetTick();
memcpy( last_warning.message, message, 72 );
memcpy( last_warning.message, message, 36 );
is_pending_warning = true;

} /* error_log_warning */
Expand All @@ -162,19 +166,22 @@ is_pending_warning = true;
/*******************************************************************************
* *
* PROCEDURE: *
* error_log_info *
* __sdr_log_info *
* *
* DESCRIPTION: *
* Place a warning message in the buffer. *
* *
* NOTE: *
* Should be called through the error_log_info macro for bounds checking. *
* *
*******************************************************************************/
void error_log_info
void __sdr_log_info
(
char* message
const char* message
)
{
last_info.systick = HAL_GetTick();
memcpy( last_info.message, message, 72 );
memcpy( last_info.message, message, 36 );
is_pending_info = true;

} /* error_log_info */
Expand Down
26 changes: 21 additions & 5 deletions error_sdr/error_sdr.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ extern "C" {
/*------------------------------------------------------------------------------
Constants
------------------------------------------------------------------------------*/
#define TEXT_MESSAGE_LENGTH 72
#define TEXT_MESSAGE_LENGTH 36

#ifndef F1_TESTBED
#define Error_Handler( a ) error_fail_fast( a ) /* backwards compatible */
Expand Down Expand Up @@ -156,6 +156,22 @@ typedef struct TEXT_MESSAGE
*******************************************************************************/
#define assert_return( condition, retval ) do { if ( !(condition) ) return retval; } while(0)

/* type check, bounds check, then execute */
/* if either of these macros fail to expand, then its possible the user passed a pointer and not a literal. */
#define error_log_warning( string ) \
do { \
_Static_assert( sizeof( "" string ) <= TEXT_MESSAGE_LENGTH, "Warning Message is oversized." ); \
__sdr_log_warning( string ); \
} while(0)

/* type check, bounds check, then execute */
/* if either of these macros fail to expand, then its possible the user passed a pointer and not a literal. */
#define error_log_info( string ) \
do { \
_Static_assert( sizeof( "" string ) <= TEXT_MESSAGE_LENGTH, "Info Message is oversized." ); \
__sdr_log_info( string ); \
} while(0)


/*------------------------------------------------------------------------------
Function Prototypes
Expand All @@ -168,14 +184,14 @@ void error_fail_fast
);

/* warnings and info for telemetry */
void error_log_info
void __sdr_log_info
(
char* message
const char* message
);

void error_log_warning
void __sdr_log_warning
(
char* message
const char* message
);

bool error_get_warning
Expand Down
Loading