homebridge / homebridge-raspbian-image

Official Homebridge Raspberry Pi Image based on Raspberry Pi OS Lite.
http://homebridge.io
BSD 3-Clause "New" or "Revised" License
1.06k stars 64 forks source link

Sound is not working on RPi != 5 #135

Closed Vaxter closed 6 months ago

Vaxter commented 9 months ago

Raspberry Pi Model

Raspberry Pi 4 B

Describe The Bug

Download and flash Homebridge image with RPi Imager.

Setup Codec Zero sound card by following the official documentation: https://www.raspberrypi.com/documentation/accessories/audio.html#raspberry-pi-codec-zero

Try to record sound: arecord -f cd test.wav

Recording is empty.

I have tested this on PRi4, RPi Zero WH and RPi Zero 2 W, same results - empty recording.

Do the same thing on RPi 5, everything works as expected.

Use RPi OS Lite or any other image on any RPi version, again everything works.

Logs

Error that arecord sometimes shows, but not always:
Recording WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
overrun!!! (at least 1.091 ms long)
overrun!!! (at least 0.165 ms long)
^CAborted by signal Interrupt...
NorthernMan54 commented 9 months ago

You could install RPI OS lite then install the homebridge apt package. That is what is done within the homebridge raspbian package.

https://github.com/homebridge/homebridge/wiki/Install-Homebridge-on-Raspbian

Vaxter commented 9 months ago

That’s fine for me, but I am developing a HB plugin for hooking an analog intercom to HB and I don’t think that everyone would be willing to do this.

Anyhow, there is an issue that should be fixed…

NorthernMan54 commented 9 months ago

As fixing this requires the HAT you are using, could you look into what is missing from the Homebridge Image, and we can add it.

The build is here, which is pretty straight forward - https://github.com/homebridge/homebridge-raspbian-image/blob/latest/.github/workflows/create_raspbian_pi-gen.yml

github-actions[bot] commented 8 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] commented 7 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] commented 6 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] commented 6 months ago

This issue has been closed as no further activity has occurred.