History

Fix sync order issue for scopes

Olav Sørensen committed 4 years ago

Commit da054581 parent a442a3d1 file · +10 −6Browse files

Unified · Split

src/pt2_sync.c+10−6
@@ -157,13 +157,9 @@ void updateChannelSyncBuffer(void) · 156 unmodified lines
157157 if (flags & SET_SCOPE_PERIOD)
158158 scopeSetPeriod(ch, c->period);
159159
160− if (flags & SET_SCOPE_DATA)
161− scope[ch].newData = c->newData;
162−
163− if (flags & SET_SCOPE_LENGTH)
164− scope[ch].newLength = c->newLength;
160+ // the following handling order is important, don't change it!
165161
166− if (flags & STOP_SCOPE) // this must be handled *before* TRIGGER_SCOPE
162+ if (flags & STOP_SCOPE)
167163 scope[ch].active = false;
168164
169165 if (flags & TRIGGER_SCOPE)
@@ -173,6 +169,14 @@ void updateChannelSyncBuffer(void) · 3 unmodified lines
173169 scopeTrigger(ch);
174170 }
175171
172+ if (flags & SET_SCOPE_DATA)
173+ scope[ch].newData = c->newData;
174+
175+ if (flags & SET_SCOPE_LENGTH)
176+ scope[ch].newLength = c->newLength;
177+
178+ // ---------------------------------------------------------------
179+
176180 if (flags & UPDATE_ANALYZER)
177181 updateSpectrumAnalyzer(c->analyzerVolume, c ->analyzerPeriod);
178182

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t