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

No Airplay Entity on iPhone #5

Open
grant-cpt opened this issue Jun 5, 2024 · 11 comments
Open

No Airplay Entity on iPhone #5

grant-cpt opened this issue Jun 5, 2024 · 11 comments

Comments

@grant-cpt
Copy link

grant-cpt commented Jun 5, 2024

I have no entity to Airplay to. Is it because of this first warning message?

/usr/lib/python3/dist-packages/supervisor/options.py:474: UserWarning: Supervisord is running as root and it is searching for its configuration file in default locations (including its current working directory); you probably want to specify a "-c" argument specifying an absolute path to a configuration file for improved security.
  self.warnings.warn(
2024-06-05 13:11:52,486 CRIT Supervisor is running as root.  Privileges were not dropped because no user is specified in the config file.  If you intend to run as root, you can set user=root in the config file to avoid this message.
2024-06-05 13:11:52,486 INFO Included extra file "/etc/supervisor/conf.d/supervisord.conf" during parsing
2024-06-05 13:11:52,505 INFO RPC interface 'supervisor' initialized
2024-06-05 13:11:52,506 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2024-06-05 13:11:52,507 INFO supervisord started with pid 1
2024-06-05 13:11:53,513 INFO spawned: 'apply-config' with pid 7
2024-06-05 13:11:53,523 INFO spawned: 'nqptp' with pid 8
2024-06-05 13:11:53,533 INFO spawned: 'dbus' with pid 9
2024-06-05 13:11:53,544 INFO spawned: 'avahidaemon' with pid 10
2024-06-05 13:11:53,556 INFO spawned: 'shairport' with pid 11
2024-06-05 13:11:53,582 INFO success: apply-config entered RUNNING state, process has stayed up for > than 0 seconds (startsecs)
2024-06-05 13:11:54,671 INFO success: nqptp entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2024-06-05 13:11:54,671 INFO success: dbus entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2024-06-05 13:11:54,671 INFO success: avahidaemon entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2024-06-05 13:11:54,671 INFO success: shairport entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2024-06-05 13:11:56,099 INFO exited: apply-config (exit status 0; expected)
@grant-cpt grant-cpt changed the title WARN exited: shairport (exit status 1; not expected) No Airplay Entity on iPhone Jun 5, 2024
@JohannVR
Copy link
Owner

JohannVR commented Jun 5, 2024

Hmm, that's weird. My logs look about the same. You could try to install Portainer from this Repo on your Home Assistant Host and open the console of the container running airplay, then run supervisorctl stop shairport after that you can see the whole logs by running shairport-sync -v, check if there is an error there

@grant-cpt
Copy link
Author

Not seeing anything standing out here. But I'm also not sure what to look out for here

root@f5833945-airplay2:/# supervisorctl stop shairport
shairport: stopped
root@f5833945-airplay2:/# shairport-sync -v
         0.004929687 "shairport.c:2252" Startup in AirPlay 2 mode, with features 0x405fca00,0x1c340 on device "b8:27:eb:66:ef:d6".
         0.000131407 "shairport.c:2291" Version String: "4.3.2-2-g165431a8-AirPlay2-smi10-alac-OpenSSL-Avahi-pa-soxr-metadata-mqtt-sysconfdir:/etc"
         0.000024843 "shairport.c:2310" Command Line: "shairport-sync -v".
         0.001029740 "shairport.c:2346" Log Verbosity is 1.
         0.010829948 "shairport.c:2394" disable_resend_requests is off.
         0.000114427 "shairport.c:2395" diagnostic_drop_packet_fraction is 0.000000. A value of 0.0 means no packets will be dropped deliberately.
         0.000045000 "shairport.c:2399" statistics_requester status is 0.
         0.000037292 "shairport.c:2404" rtsp listening port is 7000.
         0.000042135 "shairport.c:2405" udp base port is 6001.
         0.000035521 "shairport.c:2406" udp port range is 10.
         0.000077760 "shairport.c:2407" player name is "Lounge Speaker".
         0.000103386 "shairport.c:2408" backend is "pa".
         0.000041979 "shairport.c:2409" run_this_before_play_begins action is "(null)".
         0.000166406 "shairport.c:2410" run_this_after_play_ends action is "(null)".
         0.000031615 "shairport.c:2411" wait-cmd status is 0.
         0.000037760 "shairport.c:2412" run_this_before_play_begins may return output is 0.
         0.000038229 "shairport.c:2413" run_this_if_an_unfixable_error_is_detected action is "(null)".
         0.000037032 "shairport.c:2415" run_this_before_entering_active_state action is  "(null)".
         0.000041354 "shairport.c:2417" run_this_after_exiting_active_state action is  "(null)".
         0.000037187 "shairport.c:2419" active_state_timeout is  10.000000 seconds.
         0.000140886 "shairport.c:2420" mdns backend "(null)".
         0.000046354 "shairport.c:2422" interpolation setting is "auto".
         0.000036979 "shairport.c:2426" interpolation soxr_delay_threshold is 30000000.
         0.000126354 "shairport.c:2427" resync time is 0.050000 seconds.
         0.000055990 "shairport.c:2428" resync recovery time is 0.100000 seconds.
         0.000038177 "shairport.c:2429" allow a session to be interrupted: 0.
         0.000036250 "shairport.c:2430" busy timeout time is 0.
         0.000035104 "shairport.c:2431" drift tolerance is 0.002000 seconds.
         0.000035781 "shairport.c:2432" password is "(null)".
         0.000103177 "shairport.c:2433" default airplay volume is: -24.000000.
         0.000084636 "shairport.c:2434" high threshold airplay volume is: -16.000000.
         0.000255937 "shairport.c:2436" check for higher-than-threshold volume for new play session is disabled.
         0.000239584 "shairport.c:2442" ignore_volume_control is 0.
         0.000103125 "shairport.c:2446" volume_max_db is not set
         0.000669583 "shairport.c:2447" volume range in dB (zero means use the range specified by the mixer): 0.
         0.000089948 "shairport.c:2449" volume_range_combined_hardware_priority (1 means hardware mixer attenuation is used first) is 0.
         0.000022917 "shairport.c:2453" playback_mode is 0 (0-stereo, 1-mono, 1-reverse_stereo, 2-both_left, 3-both_right).
         0.000016093 "shairport.c:2455" disable_synchronization is 0.
         0.000013177 "shairport.c:2456" use_mmap_if_available is 1.
         0.000013907 "shairport.c:2457" output_format automatic selection is enabled.
         0.000013437 "shairport.c:2461" output_rate automatic selection is enabled.
         0.000012188 "shairport.c:2465" audio backend desired buffer length is 0.350000 seconds.
         0.000013906 "shairport.c:2467" audio_backend_buffer_interpolation_threshold_in_seconds is 0.020000 seconds.
         0.000015625 "shairport.c:2469" audio backend latency offset is 0.000000 seconds.
         0.000013229 "shairport.c:2471" audio backend silence lead-in time is "auto".
         0.000012448 "shairport.c:2475" zeroconf regtype is "_raop._tcp".
         0.000012865 "shairport.c:2476" decoders_supported field is 3.
         0.000010885 "shairport.c:2477" use_apple_decoder is 1.
         0.000012552 "shairport.c:2478" alsa_use_hardware_mute is 0.
         0.000012083 "shairport.c:2482" no special mdns service interface was requested.
         0.000860313 "shairport.c:2485" configuration file name "/etc/shairport-sync.conf" resolves to "/etc/shairport-sync.conf".
         0.000114062 "shairport.c:2492" metadata enabled is 1.
         0.000022032 "shairport.c:2493" metadata pipename is "/tmp/shairport-sync-metadata".
         0.000017291 "shairport.c:2494" metadata socket address is "(null)" port 0.
         0.000014532 "shairport.c:2496" metadata socket packet size is "500".
         0.000013593 "shairport.c:2497" get-coverart is 1.
         0.000011771 "shairport.c:2500" mqtt is disabled.
         0.000011198 "shairport.c:2501" mqtt hostname is core-mosquitto, port is 1883.
         0.000019896 "shairport.c:2502" mqtt topic is airplay2.
         0.000012552 "shairport.c:2503" mqtt will not publish raw metadata.
         0.000112969 "shairport.c:2504" mqtt will publish parsed metadata.
         0.000028125 "shairport.c:2505" mqtt will not publish cover Art.
         0.000015052 "shairport.c:2506" mqtt remote control is enabled.
         0.000013437 "shairport.c:2515" loudness is 0.
         0.000011198 "shairport.c:2516" loudness reference level is -20.000000
         0.001030417 "rtsp.c:4193" metadata pipe name is "/tmp/shairport-sync-metadata".
         0.011602812 "shairport.c:2643" NQPTP is online.
         1.493081666 "shairport.c:255" "soxr" interpolation has been chosen.

@grant-cpt
Copy link
Author

Not perhaps related to this line?

0.000080521 "shairport.c:2494" metadata socket address is "(null)" port 0.

@JohannVR
Copy link
Owner

JohannVR commented Jun 5, 2024

I don't think so, my logs look about the same, and it works for me. Maybe it has something to do with your Wi-Fi setup? I'm not really sure what else it could be :/

@grant-cpt
Copy link
Author

So my Raspberry Pi is connected via LAN. Would that be a problem?

@JohannVR
Copy link
Owner

JohannVR commented Jun 5, 2024

No, that's fine, mine is too, maybe it's a setting in your router that isolates network devices or something like that

@JohannVR
Copy link
Owner

JohannVR commented Jun 5, 2024

You could try to find a solution on this page: Troubleshooting

@grant-cpt
Copy link
Author

Okay, so I took out Adguard from the mix, rebooted the Raspberry Pi, and now things are working.

I had to however, unmute the USB sound card

@grant-cpt
Copy link
Author

So I decided to ditch the custom linux install of Home Assistant (Supervised) and just run HAOS. Things work a lot better out the box (in regards to the Airplay device popping up) but now I can't unmute the USB sound card. Any ideas before I default over to aux?

@JohannVR
Copy link
Owner

JohannVR commented Jun 5, 2024

Sorry, I don't really know what you mean by unmuting the sound card, shouldn't the card be unmuted if you're using it to play audio?

@grant-cpt
Copy link
Author

I found the solution.

Step 1:

~ # ha audio info
audio:
  application:
  - addon: d9d497bbc073e98489f888d465f8c03e
    index: 0
    mute: false
    name: Shairport Sync
    stream_index: 8
    stream_type: output
    volume: 1
  card:
  - driver: module-alsa-card.c
    index: 4
    name: alsa_card.platform-bcm2835_audio
    profiles:
    - active: true
      description: Stereo Output
      name: output:stereo-fallback
    - active: false
      description: "Off"
      name: "off"
  - driver: module-alsa-card.c
    index: 5
    name: alsa_card.usb-MV-SILICON_mvsilicon_B1_usb_audio_20190808-00
    profiles:
    - active: true
      description: Analog Stereo Output
      name: output:analog-stereo
    - active: false
      description: Digital Stereo (IEC958) Output
      name: output:iec958-stereo
    - active: false
      description: "Off"
      name: "off"
  input: []
  output:
  - applications: []
    card: 4
    default: false
    description: Built-in Audio Stereo
    index: 7
    mute: false
    name: alsa_output.platform-bcm2835_audio.stereo-fallback
    volume: 0.857696533203125
  - applications:
    - addon: d9d497bbc073e98489f888d465f8c03e
      index: 0
      mute: false
      name: Shairport Sync
      stream_index: 8
      stream_type: output
      volume: 1
    card: 5
    default: true
    description: mvsilicon B1 usb audio Analog Stereo
    index: 8
    mute: false
    name: alsa_output.usb-MV-SILICON_mvsilicon_B1_usb_audio_20190808-00.analog-stereo
    volume: 0.541168212890625
host: 172.30.32.4
update_available: false
version: 2023.12.0
version_latest: 2023.12.0

With focus on the output:

output:
  - applications: []
    card: 4
    default: false
    description: Built-in Audio Stereo
    index: 7
    mute: false
    name: alsa_output.platform-bcm2835_audio.stereo-fallback
    volume: 0.857696533203125
  - applications:
    - addon: d9d497bbc073e98489f888d465f8c03e
      index: 0
      mute: false
      name: Shairport Sync
      stream_index: 8
      stream_type: output
      volume: 1
    card: 5
    default: true
    description: mvsilicon B1 usb audio Analog Stereo
    index: 8
    mute: false
    name: alsa_output.usb-MV-SILICON_mvsilicon_B1_usb_audio_20190808-00.analog-stereo
    volume: 0.541168212890625

Step 2: Unmute (index 8 as this is my USB sound card in question)

ha audio volume output --index 8 --unmute

Step 3: Set desired volume

ha audio volume output --index 8 --volume 100

So why all the above?
I've got a speaker with Bluetooth, Aux, Phono & USB Input. The USB input is shown up as an USB sound card

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