mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-26 01:35:41 +03:00
Update RPM data in smartport and frsky_hub telemetry
Both previously displayed eRPM. frsky_hub RPM data is constrained to int16 so the value sent is RPM/10. Updates per review and function renaming
This commit is contained in:
parent
063f3829d4
commit
809c2a950b
8 changed files with 16 additions and 9 deletions
|
@ -673,7 +673,7 @@ static bool osdDrawSingleElement(uint8_t item)
|
|||
const char motorNumber = '1' + i;
|
||||
// if everything is OK just display motor number else R, T or C
|
||||
char warnFlag = motorNumber;
|
||||
if (ARMING_FLAG(ARMED) && osdConfig()->esc_rpm_alarm != ESC_RPM_ALARM_OFF && escData->rpm <= osdConfig()->esc_rpm_alarm) {
|
||||
if (ARMING_FLAG(ARMED) && osdConfig()->esc_rpm_alarm != ESC_RPM_ALARM_OFF && calcEscRpm(escData->rpm) <= osdConfig()->esc_rpm_alarm) {
|
||||
warnFlag = 'R';
|
||||
}
|
||||
if (osdConfig()->esc_temp_alarm != ESC_TEMP_ALARM_OFF && escData->temperature >= osdConfig()->esc_temp_alarm) {
|
||||
|
@ -820,7 +820,7 @@ static bool osdDrawSingleElement(uint8_t item)
|
|||
|
||||
case OSD_ESC_RPM:
|
||||
if (feature(FEATURE_ESC_SENSOR)) {
|
||||
tfp_sprintf(buff, "%5d", escDataCombined == NULL ? 0 : (escDataCombined->rpm * 100) / (motorConfig()->motorPolesCount / 2));
|
||||
tfp_sprintf(buff, "%5d", escDataCombined == NULL ? 0 : calcEscRpm(escDataCombined->rpm));
|
||||
}
|
||||
break;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue