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

Add SoCo method to determine HDMI/Optical input audio format #832

Merged
merged 8 commits into from Oct 11, 2021

Conversation

rytilahti
Copy link
Contributor

@rytilahti rytilahti commented May 18, 2021

This is extracted from #780 to avoid overloading that PR with multiple different features.

This PR adds two new properties to the device to report the audio input format (e.g., if there is no input and whether the input is dolby digital 5.1 or just PCM stereo) for toslink/hdmi input found on soundbars:

  • soundbar_audio_input_format_code to return the audio input format as reported by the device, and
  • soundbar_audio_input_format to return a human-readable description of the format, if available.

I'm not completely happy about this:

This returns a string representation of the currently active audio input format.
@coveralls
Copy link

coveralls commented May 18, 2021

Coverage Status

Coverage decreased (-1.6%) to 52.613% when pulling 023a8d7 on rytilahti:feat/soundbar_audio_input_format into bb71285 on SoCo:master.

soco/core.py Outdated Show resolved Hide resolved
soco/core.py Outdated Show resolved Hide resolved
soco/core.py Outdated Show resolved Hide resolved
@pwt pwt modified the milestones: 0.24.0, 0.23.0 Jul 7, 2021
@rytilahti rytilahti changed the title WIP: Add soundbar_audio_input_format Add soundbar_audio_input_format{_code} to access toslink/hdmi input format Jul 7, 2021
@rytilahti
Copy link
Contributor Author

Added some tests & did some fine tuning. @pwt please let me know if there's some other changes that are still needed to get this merged!

tests/test_core.py Outdated Show resolved Hide resolved
@pwt pwt changed the title Add soundbar_audio_input_format{_code} to access toslink/hdmi input format Add SoCo method to determine HDMI/Optical input audio format Oct 11, 2021
@pwt pwt merged commit bc20bc5 into SoCo:master Oct 11, 2021
@rytilahti rytilahti deleted the feat/soundbar_audio_input_format branch October 11, 2021 16:30
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.

None yet

3 participants