Good morning,
DK: nrf5340 Audio DK
SDK : V2.0.0
Toolchain Manager: V1.1.3
nRF Connect for Desktop: v3.11.1
I am trying to work with nrf5340 Audio DK. I was able to run and flash the "nrf5340 Audio" application to three of my DKs (2 headsets and 1 gateway) three days back. Then there was some issue and I was not able to build. I then deleting all the data and reinstalling the Nrf Connect for Desktop, Toolchain Manager and VSCode. I did an automatic installation using toolchain manager. Still I am not able to build the application properly.
This is how my files are located/alligned.
Please note that I am using SBC codec. These were the steps which I followed.
1. I followed this documentation from Nordic.
2. I set up the audio repositoy as follows.
west config manifest.group-filter +nrf5340_audio west update
Since I was not using LC3, I did not provide credential for login and the "ERROR: update failed for project sdk-lc3" was generated in the log. I believe this is ok since I am not using LC3 codec.
3. I added these lines in the prj.conf file.
# Adding support for SBC codec CONFIG_SW_CODEC_SBC=y
4. I commented out these two lines in overlay-headset.conf and overlay-gateway.conf
#CONFIG_LC3_ENC_CHAN_MAX=1 #CONFIG_LC3_DEC_CHAN_MAX=1
5. Afterwards I commented out the line 815 in audio_datapath.c. When I initially tested, the DKs always disconencts in between the audio streaming. After searching in the devzone, I found out this was a known issue when using SBC. And this workarround was suggested.
if (pcm_size != (BLK_STEREO_SIZE_OCTETS * NUM_BLKS_IN_FRAME)) { //ERR_CHK_MSG(-ECANCELED, "Decoded audio has wrong size"); }
6. I also edited nrf5340_audio_dk_devices.json file as follows.
[ { "nrf5340_audio_dk_snr": 1050103097, "nrf5340_audio_dk_dev": "headset", "channel": "left" }, { "nrf5340_audio_dk_snr": 1050156899, "nrf5340_audio_dk_dev": "gateway", "channel": "NA" }, { "nrf5340_audio_dk_snr": 1050189690, "nrf5340_audio_dk_dev": "headset", "channel": "right" } ]
7. Initially I was having a lot of issues with path / includes. I followed this post to edit the error squirrels to solve the issue.
8. I then navigated to the required directory to run the python script. There is a west build error as seen in the screenshots.
I am able to compile and flash other example applications to my nrf52840DK. Eg: ble peripheral BMS sample.
Here is the generated support information
IMPORTANT: The data below could contain sensitive or confidential information about your environment. If you do not wish this to be seen by others, please make sure to remove it before sharing. For help and support, visit the Nordic DevZone at https://devzone.nordicsemi.com/. { "platform": { "os": "win32", "osVersion": "Windows 10 Pro", "osKernel": "10.0.18363", "vscode": "1.69.1", "electron": "18.3.5", "node": "v16.13.2" }, "system": { "date": "2022-07-15T07:38:32.367Z", "vscodeRoot": "c:\\Users\\acp\\AppData\\Local\\Programs\\Microsoft VS Code\\resources\\app", "nrfConnectForDesktopInstalled": true, "vscodeUptime": "00:00:37", "osUptime": "18:45:36", "cpu": { "model": "Intel(R) Core(TM) i5-4460 CPU @ 3.20GHz", "speed": "3200 MHz", "count": 2 }, "memory": { "total": "7.88 GB", "free": "1.68 GB" } }, "workspace": { "name": "Untitled (Workspace)", "workspaceFile": "1657809163024", "folders": [ "c:\\acpncs\\cus_app\\cuss_nrf5340_audio" ] }, "extensions": { "internal": { "nordic-semiconductor.nrf-connect": { "version": "2022.7.242", "path": "c:\\Users\\acp\\.vscode\\extensions\\nordic-semiconductor.nrf-connect-2022.7.242-win32-x64", "isActive": true }, "nordic-semiconductor.nrf-terminal": { "version": "2022.7.21", "path": "c:\\Users\\acp\\.vscode\\extensions\\nordic-semiconductor.nrf-terminal-2022.7.21", "isActive": true }, "nordic-semiconductor.nrf-devicetree": { "version": "2022.7.36", "path": "c:\\Users\\acp\\.vscode\\extensions\\nordic-semiconductor.nrf-devicetree-2022.7.36", "isActive": true }, "nordic-semiconductor.nrf-kconfig": { "version": "2022.7.24", "path": "c:\\Users\\acp\\.vscode\\extensions\\nordic-semiconductor.nrf-kconfig-2022.7.24", "isActive": true } }, "external": { "marus25.cortex-debug": "1.4.4", "ms-vscode.cpptools": "1.10.8", "ms-vscode-remote.remote-wsl-recommender": "0.0.15", "ms-vscode.js-debug": "1.69.0", "ms-vscode.js-debug-companion": "1.0.18", "ms-vscode.vscode-js-profile-table": "1.0.2", "trond-snekvik.gnu-mapfiles": "1.1.0", "twxs.cmake": "0.0.17" } }, "tools": { "c:\\acpncs\\toolchains\\v2.0.0\\opt\\zephyr-sdk\\arm-zephyr-eabi\\bin\\arm-zephyr-eabi-gcc.exe": "0.14.1", "C:\\Program Files (x86)\\SEGGER\\JLink\\JLink.exe": "7.58b", "C:\\Program Files (x86)\\Nordic Semiconductor\\nrf-command-line-tools\\bin\\nrfjprog.exe": "10.15.4", "C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\Scripts\\nrfutil.exe": null, "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\cmake.exe": "3.20.5", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\Scripts\\west.exe": "0.13.1", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\python.exe": "3.8.2", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\ninja.exe": "1.9.0", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\gperf.exe": "3.1", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\dtc.exe": "1.4.7", "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\gn.exe": "2039", "c:\\acpncs\\toolchains\\v2.0.0\\mingw64\\bin\\git.exe": "2.26.2.windows.1" }, "sdks": [ { "version": "2.0.0", "path": "c:\\acpncs\\v2.0.0" } ], "toolchains": [ { "version": "2.0.0", "path": { "$mid": 1, "fsPath": "c:\\acpncs\\toolchains\\v2.0.0", "_sep": 1, "path": "/C:/acpncs/toolchains/v2.0.0", "scheme": "file" } } ], "connectedDevices": [ { "serialNumber": "683725803" } ], "deviceProviders": [ "nrfjprog" ], "config": { "nordic-semiconductor.nrf-connect": { "topdir": "${nrf-connect.sdk:2.0.0}", "toolchain": { "path": "${nrf-connect.toolchain:2.0.0}" }, "ozonePath": "", "applications": [ "c:\\acpncs\\cus_app\\cuss_peripheral_bms", "${workspaceFolder}" ], "applicationOptions": {}, "kconfig": { "interface": "kconfig" }, "welcome": { "showOnStartup": true }, "west": { "env": { "$base": "terminal" } }, "boardRoots": [], "enableTelemetry": null, "taskBindings": {}, "debugging": { "backend": "Cortex-Debug" }, "activeAppFollowActiveEditor": true }, "nordic-semiconductor.nrf-terminal": { "terminalMode": "character" }, "marus25.cortex-debug": { "armToolchainPath": null, "armToolchainPrefix": "arm-none-eabi", "gdbPath": null, "objdumpPath": null, "JLinkGDBServerPath": null, "openocdPath": null, "pyocdPath": null, "PEGDBServerPath": null, "stutilPath": null, "stlinkPath": null, "stm32cubeprogrammer": null, "enableTelemetry": true, "flattenAnonymous": false, "registerUseNaturalFormat": true, "variableUseNaturalFormat": true, "dbgServerLogfile": null, "showRTOS": false, "showDevDebugOutput": "none" } }, "environment": { "westExe": "west", "westEnv": { "ELECTRON_RUN_AS_NODE": "1", "HOME": "C:\\SPB_Data", "HOMEDRIVE": "C:", "HOMEPATH": "\\Users\\acp", "Path": "c:\\acpncs\\toolchains\\v2.0.0\\mingw64\\bin;c:\\acpncs\\toolchains\\v2.0.0\\mingw64\\libexec\\git-core;c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin;c:\\acpncs\\toolchains\\v2.0.0\\opt\\zephyr-sdk\\arm-zephyr-eabi\\bin;c:\\acpncs\\toolchains\\v2.0.0\\arm-zephyr-eabi\\bin;c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\Scripts;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Python35\\Scripts\\;C:\\Python35\\;C:\\Program Files (x86)\\Common Files\\Oracle\\Java\\javapath;C:\\Program Files\\Common Files\\Microsoft Shared\\Windows Live;C:\\Program Files (x86)\\Common Files\\Microsoft Shared\\Windows Live;C:\\ProgramData\\Oracle\\Java\\javapath;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Microsoft SQL Server\\80\\Tools\\Binn\\;C:\\Program Files (x86)\\Skype\\Phone\\;C:\\Program Files (x86)\\Windows Live\\Shared;C:\\Program Files\\Meditech\\MiniFlip\\bin;C:\\Program Files\\PuTTY\\;C:\\Windows\\System32\\OpenSSH\\;C:\\gstreamer\\1.0\\x86_64\\bin;C:\\Users\\acp\\Documents\\Meditech_Adarsh\\bin;C:\\Program Files (x86)\\Pico Technology\\PicoScope6\\;C:\\Program Files\\TortoiseSVN\\bin;C:\\ProgramData\\chocolatey\\bin;C:\\Program Files\\MATLAB\\MATLAB Runtime\\v93\\runtime\\win64;C:\\Program Files (x86)\\Nordic Semiconductor\\nrf-command-line-tools\\bin\\;C:\\Program Files\\CMake\\bin;C:\\Program Files\\Git\\cmd;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\;C:\\Program Files (x86)\\GNU Tools Arm Embedded\\9 2019-q4-major\\bin;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Launcher\\;C:\\Users\\acp\\AppData\\Local\\Microsoft\\WindowsApps;C:\\Users\\acp\\AppData\\Local\\GitHubDesktop\\bin;;C:\\Users\\acp\\AppData\\Local\\Programs\\Microsoft VS Code\\bin", "ZEPHYR_BASE": "c:\\acpncs\\v2.0.0\\zephyr", "ZEPHYR_TOOLCHAIN_VARIANT": "zephyr", "ZEPHYR_SDK_INSTALL_DIR": "c:\\acpncs\\toolchains\\v2.0.0\\opt\\zephyr-sdk", "PYTHONPATH": "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin;c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\Lib;c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin\\Lib\\site-packages", "Python3_ROOT": "c:\\acpncs\\toolchains\\v2.0.0\\opt\\bin" }, "inherited": { "ELECTRON_RUN_AS_NODE": "1", "HOME": "C:\\SPB_Data", "HOMEDRIVE": "C:", "HOMEPATH": "\\Users\\acp", "Path": "C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Python35\\Scripts\\;C:\\Python35\\;C:\\Program Files (x86)\\Common Files\\Oracle\\Java\\javapath;C:\\Program Files\\Common Files\\Microsoft Shared\\Windows Live;C:\\Program Files (x86)\\Common Files\\Microsoft Shared\\Windows Live;C:\\ProgramData\\Oracle\\Java\\javapath;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Microsoft SQL Server\\80\\Tools\\Binn\\;C:\\Program Files (x86)\\Skype\\Phone\\;C:\\Program Files (x86)\\Windows Live\\Shared;C:\\Program Files\\Meditech\\MiniFlip\\bin;C:\\Program Files\\PuTTY\\;C:\\Windows\\System32\\OpenSSH\\;C:\\gstreamer\\1.0\\x86_64\\bin;C:\\Users\\acp\\Documents\\Meditech_Adarsh\\bin;C:\\Program Files (x86)\\Pico Technology\\PicoScope6\\;C:\\Program Files\\TortoiseSVN\\bin;C:\\ProgramData\\chocolatey\\bin;C:\\Program Files\\MATLAB\\MATLAB Runtime\\v93\\runtime\\win64;C:\\Program Files (x86)\\Nordic Semiconductor\\nrf-command-line-tools\\bin\\;C:\\Program Files\\CMake\\bin;C:\\Program Files\\Git\\cmd;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\;C:\\Program Files (x86)\\GNU Tools Arm Embedded\\9 2019-q4-major\\bin;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Launcher\\;C:\\Users\\acp\\AppData\\Local\\Microsoft\\WindowsApps;C:\\Users\\acp\\AppData\\Local\\GitHubDesktop\\bin;;C:\\Users\\acp\\AppData\\Local\\Programs\\Microsoft VS Code\\bin", "PATH": "C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Users\\acp\\.nrfconnect-apps\\node_modules\\pc-nrfconnect-toolchain-manager\\resources\\nrfutil-toolchain-manager\\win32\\vcruntime140.dll;C:\\Python35\\Scripts\\;C:\\Python35\\;C:\\Program Files (x86)\\Common Files\\Oracle\\Java\\javapath;C:\\Program Files\\Common Files\\Microsoft Shared\\Windows Live;C:\\Program Files (x86)\\Common Files\\Microsoft Shared\\Windows Live;C:\\ProgramData\\Oracle\\Java\\javapath;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\Microsoft SQL Server\\80\\Tools\\Binn\\;C:\\Program Files (x86)\\Skype\\Phone\\;C:\\Program Files (x86)\\Windows Live\\Shared;C:\\Program Files\\Meditech\\MiniFlip\\bin;C:\\Program Files\\PuTTY\\;C:\\Windows\\System32\\OpenSSH\\;C:\\gstreamer\\1.0\\x86_64\\bin;C:\\Users\\acp\\Documents\\Meditech_Adarsh\\bin;C:\\Program Files (x86)\\Pico Technology\\PicoScope6\\;C:\\Program Files\\TortoiseSVN\\bin;C:\\ProgramData\\chocolatey\\bin;C:\\Program Files\\MATLAB\\MATLAB Runtime\\v93\\runtime\\win64;C:\\Program Files (x86)\\Nordic Semiconductor\\nrf-command-line-tools\\bin\\;C:\\Program Files\\CMake\\bin;C:\\Program Files\\Git\\cmd;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python310\\;C:\\Program Files (x86)\\GNU Tools Arm Embedded\\9 2019-q4-major\\bin;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\Scripts\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Python38\\;C:\\Users\\acp\\AppData\\Local\\Programs\\Python\\Launcher\\;C:\\Users\\acp\\AppData\\Local\\Microsoft\\WindowsApps;C:\\Users\\acp\\AppData\\Local\\GitHubDesktop\\bin;;C:\\Users\\acp\\AppData\\Local\\Programs\\Microsoft VS Code\\bin" }, "toolchainPath": "c:\\acpncs\\toolchains\\v2.0.0", "toolchainBinPath": "c:\\acpncs\\toolchains\\v2.0.0\\opt\\zephyr-sdk\\arm-zephyr-eabi\\bin", "toolchainVersion": "2.0.0" }, "terminal": { "shell": null, "defaultProfile": null } }
This is the first time I am using nRF Connect SDK. I have also not worked with zephyr RTOS. Most of the concepts are new. I have had some experience with nRF5 SDK.
I would really appreciate your feedback.
Thank you for your time.
best regards,
Adarsh