Commit graph

27 commits

Author SHA1 Message Date
Marco Casaroli
37a1f0e068 audioutils/lame: pin the checkout and build its AVX-512 sources
The bundled encoder was checked out from lame's trunk with no revision, so
every build took whatever trunk happened to be at that moment.  lame's trunk
grows vector tiers over time, and each one adds sources that the two build
files have to name:  r6655 offered AVX2 to the vector routines on 2026-07-25,
and r6718 and r6720 added an AVX-512 tier on 2026-07-30.  The AVX-512 sources
were never listed, so sim:alsa stopped linking on x86 hosts:

  takehiro.c:332:    undefined reference to `quantize_lines_xrpow_avx512'
  takehiro.c:533:    undefined reference to `ix_max_avx512'
  takehiro.c:569:    undefined reference to `count_bit_esc_avx512'
  vbrquantize.c:261: undefined reference to `calc_sfb_noise_x34_avx512'

Pin the checkout to r6720 through a LAME_VERSION variable, as the rest of
apps/ pins its third-party sources, and list the three AVX-512 files that
revision provides.  The pin is what keeps the two in step:  the source list is
maintained by hand, so it can only be correct for a known revision.

The checkout is also only performed when lame/configure is absent and is never
updated afterwards, so before this an unpinned tree was frozen at whatever
trunk was on the day it was first built.  Anyone who checked out before
2026-07-30 still links and cannot reproduce the failure, which is why this
surfaced only in CI.

Makefile named just vector/xmm_quantize_sub.c and none of the other vector
sources, so a Make build on an x86 host fails the same way with a longer list
of symbols, from SSE2 upwards.  CI builds sim:alsa through CMake only, so that
half was latent rather than visible.  Both files now list the same nine
sources under the same host condition.

Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>

Assisted-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-31 19:44:51 -03:00
Marco Casaroli
3ecd036f8f audioutils/lame: Add CMake vector sources.
Add the SSE2 and AVX2 vector implementation files to the CMake libmp3lame target for x86 simulator hosts. LAME's enabled runtime dispatch paths call these functions, so omitting them leaves sim:alsa with unresolved symbols at link time.

Non-x86 simulator hosts continue to use LAME's scalar implementation.

Assisted-by: Zed:GPT-5.6 Terra
Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
2026-07-26 08:33:06 -03:00
Matteo Golin
d273af4834 applications/audioutils/morsey: Update Morsey version
Use newer version without compile time warnings that prevent CI from
building.

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2026-07-23 09:31:29 +02:00
Matteo Golin
4d3bb6e7c9 audioutils/morsey: Add the Morsey library
This commit adds the Morsey library (Apache 2.0 licensed) to be
downloaded from an external repository so it can be used in NuttX
applications.

This library parses ASCII text into Morse code marks to be played by a
user-implemented 'transmit' function (i.e. over an LED, buzzer, audio
sink, etc.).

Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
2026-07-21 05:46:11 -03:00
hanzhijian
81accb0832 apps: fix distclean for partial builds and residual .kconfig files
The current distclean implementation has two issues:

1. Application.mk does not remove .kconfig on distclean, so stale
   config fragments from earlier builds can pollute subsequent ones.

2. Several external-library Makefiles (lame, libshvc, libulut) run
   "make -C <subdir> distclean" without checking whether the
   subdirectory exists.  When the library was never downloaded (common
   in CI partial-build environments), distclean fails with "No such
   file or directory".

Fix:

- Application.mk: add $(call DELFILE, .kconfig) to the distclean
  target so that .kconfig is cleaned along with .built, .depend, etc.

- audioutils/lame/Makefile: guard the distclean recipe with
  "if [ -d $(DST_PATH) ]; then ...; fi" and use $(MAKE) instead
  of bare make.

- netutils/libshvc/Makefile, netutils/libulut/Makefile: same
  directory-existence guard for their distclean recipes.

- crypto/wolfssl/Makefile: change "distclean:" to "distclean::"
  (double-colon) so it does not override the distclean:: rule
  inherited from Application.mk.

Signed-off-by: hanzhijian <hanzhijian@zepp.com>
2026-07-09 09:25:33 +08:00
Jiri Vlasak
d0fa5af39b audioutils: Add RTTTL parsing library
Add a simple library for parsing Ring Tone Text Transfer Language
(RTTTL).

Signed-off-by: Jiri Vlasak <jvlasak@elektroline.cz>
2026-05-26 09:55:31 -03:00
Huang Qi
4e8a0ae4c4 style: Fix coding style violations in nuttx-apps
Fix various coding style issues including:
- Case statement formatting
- Include placement and ordering
- Whitespace issues
- Long line formatting
- Bracket alignment

Affected modules:
- audioutils, examples, include
- netutils, system

Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2026-01-12 00:54:48 +08:00
Alin Jerpelea
7e9cf0237d audioutils: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-12-19 15:25:28 +08:00
xinbingnan
febd738ce5 nxaudio: fix audio stop logic to prevent buffer addition after STOP signal
- Ensure `AUDIO_STOP` via `ioctrl` is followed by `mq_send STOP` without race conditions.
- Modify loop condition to correctly handle `running = false` upon receiving STOP signal.
- Resolve potential issue where `AUDIO_MSG_DEQUEUE` could still accept buffers after STOP signal due to timing.

Before:
- `nxaudio_stop` would call `ioctrl AUDIO_STOP` followed by `mq_send STOP`, which might lead to `AUDIO_MSG_DEQUEUE` accepting buffers after STOP.

After:
- Synchronized the sequence of `ioctrl AUDIO_STOP` and `mq_send STOP` to prevent buffer addition after STOP.
- Enhanced loop condition to accurately reflect the STOP state.

Signed-off-by: xinbingnan <xinbingnan@xiaomi.com>
2024-11-08 01:41:15 +08:00
shizhenghui
fd40e25e67 lame: update CMakeLists.txt
Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-08-27 22:08:13 +08:00
shizhenghui
cf4847c4fe libmad: Add download libmad.zip to CMakeLists.txt
Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-08-27 22:08:13 +08:00
shizhenghui
309f42ea21 apps: add lame Makefile & CMakeLists.txt
Signed-off-by: shizhenghui <shizhenghui@xiaomi.com>
2024-08-22 08:37:03 +02:00
cuiziwei
62e2011e48 apps/audioutils:Add libmad library.
libmad0-dev and libmad0-dev cannot be installed simultaneously, which causes conflicts when compiling sim m32 and sim m64. Therefore, the libmad library has been ported to apps/audioutils and will be compiled with NuttX.

Signed-off-by: cuiziwei <cuiziwei@xiaomi.com>
2024-08-21 01:24:44 +08:00
SPRESENSE
8cd8866d87 audioutils/fmsynth: Fix CMakeLists.txt
Fix a configuration name used in CMakeLists.txt.
2024-06-28 20:17:04 +08:00
simbit18
dadbea7e3b fix nxstyle
fix Relative file path does not match actual file.
Add missing Apache Foundation copyright header
2024-04-30 00:02:31 +08:00
Takayoshi Koizumi
17539f1340 Fix illegal coding style on nxaudio.c
Make it as 2 lines
2024-02-28 15:30:26 +08:00
SPRESENSE
2b4a25c8d5 examples/fmsynth: Fix freaze when execute it in 2nd time
Fix a freaze BUG when the example is executed again after 1st execution.
2024-02-28 15:30:26 +08:00
raiden00pl
397da8f752 remove audioutils/xxx/README.md. Migrated to Documentation/applications/audioutils 2023-10-30 10:00:01 +08:00
SPRESENSE
4a4c550ced audioutils/fmsynth: Add create instance for static
To use this with static instance, add create function with
arguments.
2023-07-31 22:48:52 -07:00
xuxin19
7f3246cfdf cmake:migrate apps CMakeLists for [audioutils benchmarks]
audioutils
  ├── fmsynth
  ├── mml_parser
  └── nxaudio
 benchmarks
  └── coremark

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-07-27 07:22:21 -07:00
chao an
4d79a5cbaf add initial cmake build system
Co-authored-by: Daniel Agar <daniel@agar.ca>
Signed-off-by: chao an <anchao@xiaomi.com>
2023-07-08 13:52:02 +08:00
Xiang Xiao
21bc466a2b Remove the tail space char from all files
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-03-03 00:18:36 +02:00
Xiang Xiao
893387b2c5 Fix the minor style issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 19:07:16 +02:00
Xiang Xiao
4941182cc6 Make.defs: Change "ifeq ($(XXX),y)" to "ifneq ($(XXX),)
to support the tristate option correctly and unify the usage

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 14:59:08 +02:00
Takayoshi Koizumi
80eb94da8a audioutils/nxaudio: Add audio utility library for nuttx audio
Add an utility  library for easier use of NuttX's Audio driver.
2022-08-25 20:29:55 +09:00
Takayoshi Koizumi
40c506f3a0 audioutils/fmsynth: Add FM synthesizer library
Add simple FM synthesizer library in audioutils.
2022-08-25 20:29:55 +09:00
Takayoshi Koizumi
5040719911 audioutils/mml_parser: Add mml_parser library
Add Music Macro Language parser library in audioutils.
audioutils is also created for several audio utilities
not only mml_parser.
2022-05-07 13:56:53 +08:00