User description
Fixes merge conflicts from #11100
PR Type
Enhancement
Description
-
Adds barometer altitude and vario sensor support to CRSF telemetry
-
Combines altitude and vertical speed into single packet frame
-
Implements legacy barometer packet mode configuration option
-
Updates frame type definitions and payload sizes for new sensors
Diagram Walkthrough
flowchart LR
A["CRSF Telemetry"] --> B["Legacy Mode"]
A --> C["New Mode"]
B --> D["Vario Sensor Frame"]
B --> E["Altitude in GPS Frame"]
C --> F["Combined Alt-Vario Frame"]
C --> G["ASL Altitude in GPS Frame"]
F --> H["Altitude + Vertical Speed"]
File Walkthrough
| Relevant files |
|---|
| Enhancement |
crsf.hAdd barometer altitude vario sensor frame types
src/main/rx/crsf.h
- Added
CRSF_FRAME_BAROMETER_ALTITUDE_VARIO_PAYLOAD_SIZE constant (3 bytes) - Added
CRSF_FRAME_AIRSPEED_PAYLOAD_SIZE constant (2 bytes) - Renamed
CRSF_FRAMETYPE_BAROMETER_ALTITUDE to
CRSF_FRAMETYPE_BAROMETER_ALTITUDE_VARIO_SENSOR - Added
CRSF_FRAMETYPE_AIRSPEED_SENSOR frame type definition
|
+4/-1 |
crsf.cImplement barometer altitude vario sensor telemetry
src/main/telemetry/crsf.c
- Added
#include for SCHAR_MIN/SCHAR_MAX constants - Added
#include "sensors/pitotmeter.h" for airspeed sensor support - Modified GPS frame to use configurable altitude source (legacy or GPS
ASL) - Renamed
crsfBarometerAltitude() to
crsfFrameBarometerAltitudeVarioSensor() - Implemented vario (vertical speed) calculation using logarithmic
formula with TBS CRSF standard constants - Consolidated vario and barometer altitude frame scheduling into single
index - Updated frame processing to conditionally send legacy vario or new
combined altitude-vario packet
|
+27/-25 |
|
| Configuration changes |
telemetry.cAdd legacy barometer packet configuration option
src/main/telemetry/telemetry.c
- Incremented telemetry config version from 8 to 9
- Added
crsf_use_legacy_baro_packet field to telemetry config reset template - Fixed trailing comma in mavlink configuration structure
|
+3/-2 |
telemetry.hAdd legacy baro packet config field
src/main/telemetry/telemetry.h
- Added
bool crsf_use_legacy_baro_packet field to telemetryConfig_t structure
|
+1/-0 |
settings.yamlAdd CRSF legacy baro packet YAML setting
src/main/fc/settings.yaml
- Added
crsf_use_legacy_baro_packet setting definition to telemetry config group - Set type as bool with default value OFF
- Included description matching Settings.md documentation
|
+4/-0 |
|
| Documentation |
Settings.mdDocument CRSF legacy barometer packet setting
docs/Settings.md
- Added documentation for
crsf_use_legacy_baro_packet setting - Explains behavior difference between legacy and new altitude packet
modes - Documents default value as OFF
|
+9/-0 |
|
PR Compliance Guide 🔍
All compliance sections have been disabled in the configurations.