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

Extreme Audio stuttering with wireless connection on RPI4 #717

Open
0Flush0 opened this issue Jan 27, 2025 · 2 comments
Open

Extreme Audio stuttering with wireless connection on RPI4 #717

0Flush0 opened this issue Jan 27, 2025 · 2 comments

Comments

@0Flush0
Copy link

0Flush0 commented Jan 27, 2025

Issue

I have installed the newest version of crankshaft ng on my rpi4.
The device starts up in hotspot mode and when connecting to the wifi, android auto wireless works.
Touch and everything is working, altho more laggy than with using a cable. What makes it unusable, is the great amount of lag with spotify playback.
The audio stutters and lags behind, sometimes playing faster then breaking down. Audio works fine with cable connection.

Setup

  1. RPI 4
  2. HDMI Touchscreen 7 inch 1024x600
  3. Aux connection to the speakers
  4. Using a Sandisk Extreme Pro UHS-1
  5. My RPI4 is in a metal case (Maybe bad reception, but my wifi tester app shows 75mbits max)

What have i tried

  1. Increasing CPU and GPU clock, also increased video memory.
  2. Changed wifi mode to 5ghz Raspberry pi 4 hotspot 2.4GHz, not 5Ghz. #439
  3. Used different phones with battery optimizations disabled
  4. Client mode is just not working for me: Wifi0 interface is down, couldnt fix it via ssh and manually connecting: Some file not found error

Results

  1. From the steps i have taken it seems the lag has somewhat improved, but not enough.
  2. Is hotspot mode to hard to handle for the RPI4

My suspicion is some kind of wifi bottleneck.
Thanks in advance!

@pswiifanwmi
Copy link

I had this issue too, intermittently.

What I mean by that is if my car and my Pi have been off for several hours, and I start Android Auto up, it behaves relatively normally. If I turn the Pi off and on again after a couple minutes, I get the same scenario as you've described. What I noticed by checking my phone settings, is that when I'm experiencing the lagging, the phone is actually connected to the Pi in Wifi 4 mode instead of Wifi 5 as I had programmed.

I have since replaced this setup with a $60 Android Auto/Carplay device from China. It works well enough and operates in Wifi 4 with none of the lagging. Audio quality is worse, but it doesn't lag like Crankshaft on the Pi 4 does (and it boots in half the time).

All of this is to say that this device does something that Crankshaft does not that makes running in WiFi 4 more consistent. I suspect there is a lower quality audio codec running that takes up less bandwidth.

I do wonder how a WiFi 6 adapter would fare with Crankshaft, and if there would be problems similar to those with the integrated adapter. The kernel version that currently ships with Crankshaft NG doesn't support any WiFi 6 adapters, so unless there is a major update to the OS, there is nothing we can do to test it.

@viletuna
Copy link

viletuna commented Feb 5, 2025

@pswiifanwmi

I do wonder how a WiFi 6 adapter would fare with Crankshaft, and if there would be problems similar to those with the integrated adapter. The kernel version that currently ships with Crankshaft NG doesn't support any WiFi 6 adapters, so unless there is a major update to the OS, there is nothing we can do to test it.

Matt replied in a discussion post I made saying he's planning on updating to the latest OS

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

3 participants