mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2026-06-02 14:04:47 -04:00
Allow modems to limit/control input rate
- Modems can now over-ride user rate input and lock/step as needed - Separate digital code defs a bit more so it’s not required when disabled - Testing FSK based on @andresv ’s example at https://github.com/jgaeddert/liquid-dsp/issues/9
This commit is contained in:
@@ -461,7 +461,7 @@ void WaterfallCanvas::OnMouseMoved(wxMouseEvent& event) {
|
||||
bwDiff = -bwDiff;
|
||||
}
|
||||
|
||||
int currentBW = demod->getBandwidth();
|
||||
int currentBW = dragBW;
|
||||
|
||||
currentBW = currentBW + bwDiff;
|
||||
if (currentBW > CHANNELIZER_RATE_MAX) {
|
||||
@@ -472,6 +472,7 @@ void WaterfallCanvas::OnMouseMoved(wxMouseEvent& event) {
|
||||
}
|
||||
|
||||
demod->setBandwidth(currentBW);
|
||||
dragBW = currentBW;
|
||||
}
|
||||
|
||||
if (dragState == WF_DRAG_FREQUENCY) {
|
||||
@@ -601,6 +602,7 @@ void WaterfallCanvas::OnMouseDown(wxMouseEvent& event) {
|
||||
DemodulatorInstance *demod = wxGetApp().getDemodMgr().getActiveDemodulator();
|
||||
if (demod) {
|
||||
dragOfs = (long long) (mouseTracker.getMouseX() * (float) getBandwidth()) + getCenterFrequency() - (getBandwidth() / 2) - demod->getFrequency();
|
||||
dragBW = demod->getBandwidth();
|
||||
}
|
||||
wxGetApp().getDemodMgr().setActiveDemodulator(wxGetApp().getDemodMgr().getActiveDemodulator(), false);
|
||||
}
|
||||
|
||||
@@ -68,6 +68,7 @@ private:
|
||||
float hoverAlpha;
|
||||
int linesPerSecond;
|
||||
float scaleMove;
|
||||
int dragBW;
|
||||
|
||||
SpectrumVisualDataQueue visualDataQueue;
|
||||
Timer gTimer;
|
||||
|
||||
Reference in New Issue
Block a user