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

variable bitrates confusing my legacy amplifier #231

Open
eiland-asbl opened this issue Jul 14, 2022 · 2 comments
Open

variable bitrates confusing my legacy amplifier #231

eiland-asbl opened this issue Jul 14, 2022 · 2 comments

Comments

@eiland-asbl
Copy link

okay, its really my problem, but i have a legacy amplifier, a TX-8050 , and it has a hard time when i switch between youtube items, the first one is played fine, but then, when i switch to another one, it gets really confused to the bitrate (i assume) and starts playing super warped (slow).

i tried forcing mopidy and icecast2 to resample, but to no avail.

is there a away that mopidy-youtube could send out less confusing audio, for my poor old amp?

@natumbri
Copy link
Owner

natumbri commented Jul 15, 2022

Interesting issue, and not something that I've ever come across. I also use an older amplifier (NAD T754). I feed an analog signal generated by an external DAC. My amp doesn't have a USB input, but I have previously had success feeding it a digital signal by SPDIF.

Perhaps you could try limiting the formats that mopidy-youtube uses?

In youtube.py at around line 415 is the code that sets the parameters passed to get the youtube url:

                ytdl_options = {
                    "format": "bestaudio/ogg/mp3/m4a/best",
                    "proxy": self.proxy,
                    "cachedir": False,
                    "nopart": True,
                    "retries": 10,
                }

You could try changing the format line to something like "format": "mp3", to limit it to mp3 only, and see if that helps?

@eiland-asbl
Copy link
Author

i turned it into "format": "mp3", but then it triggers errors :(

DEBUG    2022-07-15 19:46:19,322 [3479268:YouTubeBackend-2] mopidy_youtube
  youtube PlaybackProvider.translate_uri "youtube:video:yTrH0nQQZ84"
[youtube] yTrH0nQQZ84: Downloading webpage
[youtube] yTrH0nQQZ84: Downloading player dfd2e197
ERROR: requested format not available
ERROR    2022-07-15 19:46:20,298 [3479268:YouTubeCoreListener-9] mopidy_youtube
  audio_url error ERROR: requested format not available (videoId: yTrH0nQQZ84)
DEBUG    2022-07-15 19:46:20,298 [3479268:YouTubeBackend-2] mopidy.backend
  Backend translated URI from youtube:video:yTrH0nQQZ84 to None
WARNING  2022-07-15 19:46:20,299 [3479268:Core-7] mopidy.core.tracklist
  Track is not playable: youtube:video:yTrH0nQQZ84
DEBUG    2022-07-15 19:46:20,299 [3479268:Audio-1] mopidy.audio.gst
  Changing state to GST_STATE_READY: result=GST_STATE_CHANGE_SUCCESS
DEBUG    2022-07-15 19:46:20,300 [3479268:YouTubeBackend-2] mopidy_youtube

oh and did i mention that with the original setup my computer has no problem playing the audio decently?

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

No branches or pull requests

2 participants