8 #ifndef MODULES_MIC_MIC_DRV_H_
9 #define MODULES_MIC_MIC_DRV_H_
19 #include "serial_usb_drv.h"
22 #define MIC_CLK_PORT gpioPortB
23 #define MIC_CLK_PIN 12
24 #define MIC_CLK_PDM_LOC 1
27 #define MIC_DATA_PORT gpioPortB
28 #define MIC_DATA_PIN 11
29 #define MIC_DATA_PDM_LOC 3
32 #define MIC_EN_PORT gpioPortA
36 #define BASE_CLK_RATE 19104000
52 MIC_OK = 0, MIC_NOT_INITIALIZED = 1, MIC_BUSY = 2
void micDriver_init(struct MicConfig config)
Initialize the microphone driver.
Definition: mic_drv.c:149
bool isRecording(void)
Gets the status of recording. Getter for the recording flag. Should be called to check if the recordi...
Definition: mic_drv.c:142
enum Mic_Ecode startRecording(int16_t *buffer, uint32_t size)
Single-shot record an audio segment. Sets pointers for sampling into, sets the recording flag,...
Definition: mic_drv.c:102
enum Mic_Ecode stopRecording(void)
Terminates the recording. Stops recording and resets the recording flag.
Definition: mic_drv.c:124