{"id":13343763,"url":"https://github.com/stuffmatic/microdsp-zephyr-demos","last_synced_at":"2025-08-09T14:21:13.209Z","repository":{"id":148958430,"uuid":"567701894","full_name":"stuffmatic/microdsp-zephyr-demos","owner":"stuffmatic","description":"A collection of demo apps showing how to do real time audio processing on a microcontroller using Zephyr (nRF Connect SDK) and the microdsp Rust library.","archived":false,"fork":false,"pushed_at":"2023-01-17T19:56:39.000Z","size":66972,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-03T22:01:45.477Z","etag":null,"topics":["audio","dsp","i2s","nordicsemi","nrf-connect-sdk","nrf52","nrf53","rust","rust-embedded","zephyr","zephyr-rtos"],"latest_commit_sha":null,"homepage":"https://github.com/stuffmatic/microdsp","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stuffmatic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-18T11:27:06.000Z","updated_at":"2025-01-21T12:21:34.000Z","dependencies_parsed_at":null,"dependency_job_id":"dfc76a43-2db2-4510-9406-bcd92436f46a","html_url":"https://github.com/stuffmatic/microdsp-zephyr-demos","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuffmatic%2Fmicrodsp-zephyr-demos","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuffmatic%2Fmicrodsp-zephyr-demos/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuffmatic%2Fmicrodsp-zephyr-demos/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stuffmatic%2Fmicrodsp-zephyr-demos/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stuffmatic","download_url":"https://codeload.github.com/stuffmatic/microdsp-zephyr-demos/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250817679,"owners_count":21492198,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audio","dsp","i2s","nordicsemi","nrf-connect-sdk","nrf52","nrf53","rust","rust-embedded","zephyr","zephyr-rtos"],"created_at":"2024-07-29T19:32:00.690Z","updated_at":"2025-04-25T12:31:31.558Z","avatar_url":"https://github.com/stuffmatic.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# microdsp Zephyr demos\n\nThis is a collection of demos showing how to do real time, full duplex audio processing on a microcontroller using [Zephyr](https://zephyrproject.org/) ([nRF Connect SDK](https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/index.html])) and the [microdsp](https://github.com/stuffmatic/microdsp) Rust library (scroll down for videos).\n\nThe [microdsp_demos](microdsp_demos) Rust crate contains the demo apps and is added to the Zephyr build using [`zephyr_add_rust_library`](https://github.com/stuffmatic/zephyr_add_rust_library).\n\nThe demo apps have been tested with nRF Connect SDK v2.1.2 and the following boards.\n\n* [nRF52840 DK](https://www.nordicsemi.com/Products/Development-hardware/nRF52840-DK)\n* [nRF5340 DK](https://www.nordicsemi.com/Products/Development-hardware/nRF5340-DK)\n\n## Demos\n\nIn the videos below, an nRF52840 DK board is used together with breakout boards for a [WM8940](datasheets/1912111437_Cirrus-Logic-WM8904CGEFL-RV_C323845.pdf) audio codec and an analog MEMS microphone. KiCad projects and JLCPCB fabrication files for these breakout boards are available [here](https://github.com/stuffmatic/kicad-boards).\n\n### Normalized least mean squares filter\n\nThis demo shows how to use a normalized least mean squares (NLMS) filter to reduce leakage of sound from the speaker in the signal recorded by the microphone.\n\nhttps://user-images.githubusercontent.com/2444852/212998568-db2bd389-72e6-4a60-9e16-2c0528aea2fb.mov\n\n* __Button 1__ - Toggle speaker output\n* __Button 2__ - Toggle NLMS filter\n* __Button 3__ - Toggle recording\n* __Button 4__ - Toggle playback\n* __LED 1__ - On when speaker output is active\n* __LED 2__ - On when the NLSM filter is active\n* __LED 3__ - On when recording\n* __LED 4__ - On when playing back recording\n\n### MPM pitch detection demo\n\nA (very) simple ukulele tuner. Each of the four LEDs turns on when a pitch close to the corresponding ukulele string is detected.\n\nhttps://user-images.githubusercontent.com/2444852/212776229-e64f0f90-aea1-44fe-b742-57fd5b93aa86.mov\n\n* __LED 1__ - On when the pitch is close to 392 Hz\n* __LED 2__ - On when the pitch is close to 262 Hz\n* __LED 3__ - On when the pitch is close to 330 Hz\n* __LED 4__ - On when the pitch is close to 440 Hz\n\n### Spectral flux novelty detection demo\n\nThis demo shows how to detect transients and \"starts of sounds\" using spectral changes over time rather than just signal amplitude changes.\n\nhttps://user-images.githubusercontent.com/2444852/212776266-3e04822a-fc46-4194-af9e-635a33bfee35.mov\n\n* __LED 1__ - Toggles between on and off for each detected novelty peak\n\n## Selecting which demo to build\n\nThe [`microdsp_demos`](microdsp_demos) Rust crate is compiled as part of the Zephyr build using [`zephyr_add_rust_library`](https://github.com/stuffmatic/zephyr_add_rust_library), which is called from [CMakeLists.txt](CMakeLists.txt). The `EXTRA_CARGO_ARGS` argument is used to specify which demo app to build by enabling one of the following cargo features:\n\n* `nlms_demo` - Normalized least mean squares filter demo\n* `sfnov_demo` -Spectral flux novelty detection demo\n* `mpm_demo` - MPM pitch detection demo\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstuffmatic%2Fmicrodsp-zephyr-demos","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstuffmatic%2Fmicrodsp-zephyr-demos","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstuffmatic%2Fmicrodsp-zephyr-demos/lists"}