Skip to content

Commit

Permalink
AP_OSD: use RC().get_link_stats() for extra stats
Browse files Browse the repository at this point in the history
  • Loading branch information
olliw42 committed Oct 12, 2024
1 parent a8a1851 commit 60994b4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libraries/AP_OSD/AP_OSD_Screen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2092,7 +2092,7 @@ void AP_OSD_Screen::draw_rc_tx_power(uint8_t x, uint8_t y)

void AP_OSD_Screen::draw_rc_rssi_dbm(uint8_t x, uint8_t y)
{
const int8_t rssidbm = AP::crsf()->get_link_status().rssi_dbm;
const int8_t rssidbm = AP::RC().get_link_status().rssi_dbm;
const bool blink = -rssidbm < osd->warn_rssi;
bool btfl = is_btfl_fonts();

Expand All @@ -2115,7 +2115,7 @@ void AP_OSD_Screen::draw_rc_rssi_dbm(uint8_t x, uint8_t y)

void AP_OSD_Screen::draw_rc_snr(uint8_t x, uint8_t y)
{
const int8_t snr = AP::crsf()->get_link_status().snr;
const int8_t snr = AP::RC().get_link_status().snr;
const bool blink = snr < osd->warn_snr;
bool btfl = is_btfl_fonts();
if (snr == INT8_MIN) {
Expand Down Expand Up @@ -2154,7 +2154,7 @@ void AP_OSD_Screen::draw_rc_active_antenna(uint8_t x, uint8_t y)

void AP_OSD_Screen::draw_rc_lq(uint8_t x, uint8_t y)
{
const int16_t lqv = AP::crsf()->get_link_status().link_quality;
const int16_t lqv = AP::RC().get_link_status().link_quality;
const bool blink = lqv < osd->warn_lq;
bool btfl = is_btfl_fonts();
bool prefix_rf = check_option(AP_OSD::OPTION_RF_MODE_ALONG_WITH_LQ);
Expand Down

0 comments on commit 60994b4

Please sign in to comment.