Skip to content

ESP/Speaker: Use a natural sounding volume curve - #167

Merged
ao-david merged 1 commit into
speaker/pr03-netsender-allocfrom
speaker/pr04-volume-curve
Oct 29, 2026
Merged

ao-david merged 1 commit into
speaker/pr03-netsender-allocfrom
speaker/pr04-volume-curve

Conversation

@ao-david

Copy link
Copy Markdown
Member

Stacked on #166.

Maps the 0-100 volume variable onto the TAS5805 digital volume with a square-law amplitude curve (40 * log10(vol / 100) dB) instead of a linear register sweep. This keeps lower settings audible and avoids the large jump at the top of the range. Volume 100 now maps to 0 dB rather than the amplifier's maximum +24 dB, and volume 0 mutes.

Fixes #98.

Map the 0-100 volume setting onto the TAS5805 digital volume using a
square-law amplitude curve (40*log10(vol/100) dB) instead of a linear
register sweep. This keeps lower settings audible and prevents the top
of the range from jumping by ~24 dB. Volume 100 now maps to 0 dB rather
than the amplifier's maximum +24 dB, and volume 0 mutes.
@ao-david
ao-david added this pull request to stack #173 October 29, 2026 06:47
@ao-david
ao-david merged commit 14d01e9 into main Oct 29, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ESP Speaker: Add more natural sounding volume scale

1 participant