fix: the PWR bar stayed at full scale after transmitting
Receiving cleared the two bar percentages but not the values the bars now actually draw from: the watts and the SWR ratio, added when the meters were corrected. So the power bar sat pinned across the panel with the rig plainly receiving — the dash in the label said one thing and the bar another. Every transmit value is cleared now, and the peak-hold state with them: a peak left in the holder would have carried the last transmission's reading into the start of the next one, which is worse, being wrong while it looks live. The panel also draws both bars from zero unless the rig reports transmitting, so a value that has not been refreshed yet cannot show as output.
This commit is contained in:
@@ -193,9 +193,17 @@ func (y *Yaesu) readPanel(mode string, split bool, txHz int64) {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
// Zeroed rather than frozen: a stale SWR bar from the last transmission
|
||||
// reads as a live measurement.
|
||||
// Zeroed rather than frozen: a stale reading from the last transmission
|
||||
// reads as a live one.
|
||||
//
|
||||
// EVERY transmit value has to be cleared here, and the peak-hold state with
|
||||
// them. Clearing only the two bar percentages left the watts and the SWR
|
||||
// ratio standing — the PWR bar stayed at full scale after the operator
|
||||
// stopped transmitting — and a peak left in the holder would have carried
|
||||
// the old reading into the next transmission.
|
||||
y.panel.PowerMeter, y.panel.SWRMeter = 0, 0
|
||||
y.panel.PowerW, y.panel.SWR = 0, 0
|
||||
y.powerPeak, y.powerWPeak, y.swrPeak = meterPeak{}, meterPeak{}, meterPeak{}
|
||||
}
|
||||
|
||||
y.panelCycle++
|
||||
|
||||
Reference in New Issue
Block a user