don't disable interrupts as we are using a ring buffer
This commit is contained in:
parent
852f78b4fe
commit
f5b7492de6
1 changed files with 0 additions and 2 deletions
2
main.c
2
main.c
|
@ -106,12 +106,10 @@ int main(void) {
|
||||||
int32_t adc_current_index;
|
int32_t adc_current_index;
|
||||||
int32_t j;
|
int32_t j;
|
||||||
if (drawRequested) {
|
if (drawRequested) {
|
||||||
IntMasterDisable(); // critical section
|
|
||||||
adc_current_index = gADCBufferIndex - 128;
|
adc_current_index = gADCBufferIndex - 128;
|
||||||
for (j=0; j<LOCAL_BUF_LEN; j++) {
|
for (j=0; j<LOCAL_BUF_LEN; j++) {
|
||||||
local_adc_buffer[j] = gADCBuffer[ADC_BUFFER_WRAP(adc_current_index + j)];
|
local_adc_buffer[j] = gADCBuffer[ADC_BUFFER_WRAP(adc_current_index + j)];
|
||||||
}
|
}
|
||||||
IntMasterEnable();
|
|
||||||
drawRequested = 0;
|
drawRequested = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue