Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(feature) allow users to select LEFT or RIGHT channel #255

Open
softhack007 opened this issue Nov 28, 2022 · 0 comments
Open

(feature) allow users to select LEFT or RIGHT channel #255

softhack007 opened this issue Nov 28, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@softhack007
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
It seems there are devices that cannot be configured for LEFT channel (like M5StickC), and sometimes it would be interesting to change to LEFT or RIGHT channel without needing a special firmware for each channel.

Describe the solution you'd like

  • Additional drop-down in sound input settings: LEFT, RIGHT
  • Changes will need a restart (because I2S driver is only configured at startup)
  • simple solution with minimal code changes

Describe alternatives you've considered
it would also be possible to always request left+right channel from I2S, and do a down-mix in software. However this has some drawbacks:

  • loss of volume - especially when one channels is silent then left+right / 2 = 0.5 left
  • doubles the buffer needed to store I2S samples, even when only one channel contains audio
  • i2s internal samples queues would also be doubled
  • Usually music is playing on both channels, so there will not be much difference (for SRWLED) compared to only using one channel.

Additional context
There is already the possibility for users to self-compile SRWLED for using I2S right channel:

build_flags = -D I2S_USE_RIGHT_CHANNEL

@softhack007 softhack007 added the enhancement New feature or request label Nov 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant