Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit c97ec7e

Browse files
committedJun 14, 2021
Run PDM clock at 2.08MHz
1 parent 2f95bc3 commit c97ec7e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎libraries/PDM/src/rp2040/PDM.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ uint8_t rawBuffer1[RAW_BUFFER_SIZE];
2424
uint8_t* rawBuffer[2] = {rawBuffer0, rawBuffer1};
2525
volatile int rawBufferIndex = 0;
2626

27-
int decimation = 64;
27+
int decimation = 128;
2828

2929
// final buffer is the one to be filled with PCM data
3030
int16_t* volatile finalBuffer;
@@ -178,7 +178,7 @@ void PDMClass::IrqHandler(bool halftranfer)
178178
}
179179

180180
// fill final buffer with PCM samples
181-
Open_PDM_Filter_64(rawBuffer[rawBufferIndex], finalBuffer, 1, &filter);
181+
Open_PDM_Filter_128(rawBuffer[rawBufferIndex], finalBuffer, 1, &filter);
182182

183183
if (cutSamples) {
184184
memset(finalBuffer, 0, cutSamples);

0 commit comments

Comments
 (0)
Please sign in to comment.