Hi,
NCS1.9, VScode,
Is there a broadvoice32 sample project for nRF52840?
my problem is:
encode one frame will takes 20ms (but decoding only takes 2ms),
so it can't support 16bit 16khz audio in I2S.
Best regards
Hi,
NCS1.9, VScode,
Is there a broadvoice32 sample project for nRF52840?
my problem is:
encode one frame will takes 20ms (but decoding only takes 2ms),
so it can't support 16bit 16khz audio in I2S.
Best regards
Hi
There is still no official Broadvoice32 support in NCS, no.
As I mentioned in this case you would need to use the implementation from the smart remote 3 reference design.
Best regards
Torbjørn
Hi, Torbjørn
thanks for reply,
i got broadvoice source code from Smart Remote 3 reference design
i created a project and build it for nRF5340-DK / nRF52840-DK,
encode one frame take 58ms,
I have no idea. I don't know where to start,
this problem has bothered me for a long time;
if possible, please help me look at the code project zip.


thanks
Best regards
Hi
You mean it takes 58ms on the nRF52840 or on the nRF5340?
I will try to get some input from one of the developers on this, if they have some advice on ways to optimize the library.
Best regards
Torbjørn
Hi,Torbjørn
thank you very much.
yes, encode one frame will takes 58ms on the nRF52840 or on the nRF5340.
decode only takes 5ms.
zip is very simple test project.
Best regards
Hi
The developer had some general advice you could try:
- Check which compiler optimizations you are using. gcc -O2 without nano-lib would be best suited for performance.
- Try to find loops in the code where things like 'multiply and accumulate' is handled, and replace this with ASM inline DSP instructions. The Cortex M4 and M33 has various different DSP SIMD instructions which can accelerate these things significantly. Please note that this is significantly more work, since it requires more of a code rewrite, and a good understanding of the DSP functionality in the ARM core.
Best regards
Torbjørn
Hi,
thanks for reply,
i think,i cannot transform code with ASM.
# SPDX-License-Identifier: Apache-2.0
cmake_minimum_required(VERSION 3.20.0)
LINK_LIBRARIES(m)
LINK_LIBRARIES(c)
LINK_LIBRARIES(gcc)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(bv32_floating)
set(CMAKE_BUILD_TYPE RELEASE)
set(CMAKE_C_FLAGS "-O2 -ggdb")
set(CMAKE_C_FLAGS_DEBUG "-O2 -ggdb")
set(CMAKE_C_FLAGS_RELEASE "-O2 -ggdb")
set(CMAKE_CXX_FLAGS "-O2 -ggdb")
set(CMAKE_CXX_FLAGS_DEBUG "-O2 -ggdb")
set(CMAKE_CXX_FLAGS_RELEASE "-O2 -ggdb")
Is that so? and cmake how to remove nano-lib?
it still 58ms.
Best regards
Hi
Are you saying those changes made no difference on the runtime?
What if you set CONFIG_SPEED_OPTIMIZATIONS=y in your project configuration?
To remove nano-lib it should be sufficient to set the following configuration:
CONFIG_NEWLIB_LIBC_NANO=n
For both of these changes please take a loot at your RAM and flash usage, to see if there is any change after you build. If the RAM or flash consumption doesn't change then the configuration change has no effect.
Best regards
Torbjørn
Hi
Are you saying those changes made no difference on the runtime?
What if you set CONFIG_SPEED_OPTIMIZATIONS=y in your project configuration?
To remove nano-lib it should be sufficient to set the following configuration:
CONFIG_NEWLIB_LIBC_NANO=n
For both of these changes please take a loot at your RAM and flash usage, to see if there is any change after you build. If the RAM or flash consumption doesn't change then the configuration change has no effect.
Best regards
Torbjørn
Hi,
thanks for reply,
CMakelists.txt
remove_definitions(-O0)
add_definitions(-w)
add_definitions(-O2)
prj.conf
Hi
Then I am out of ideas unfortunately.
Have you been in touch with one of our regional sales managers?
Then you could contact him/her and ask if it is possible to get someone in R&D to investigate this further.
If you don't have a sales contact in Nordic just let me know, and I will send you the contact details.
Best regards
Torbjørn