Works with micro:bit V2
Using these blocks requires the micro:bit V2 hardware. If you use any blocks that attempt access flash memory on a micro:bit v1 board, you will see the 927 error code on the screen.
The audio recording extension lets you record and play back audio with the micro:bit. If your version of the micro:bit has a microphone you can record a brief amount of audio and play it back on the speaker or at a sound output pin. Audio that you record is stored in an audio buffer and can be played later or recorded over with new audio.
Using these blocks requires the micro:bit V2 hardware. If you use any blocks that attempt access flash memory on a micro:bit v1 board, you will see the 927 error code on the screen.
record.startRecording(record.BlockingState.Blocking)
record.playAudio(record.BlockingState.Blocking)
record.setSampleRate(11000)
record.setMicGain(record.AudioLevels.Low)
record.audioStatus(record.AudioStatus.Playing)
start recording, play audio, set sample rate, set mic gain, audio status
audio-recording