Meta tags:
description= Use AirPlay to stream to UPnP/Sonos & Chromecast devices - philippe44/AirConnect;
Headings (most frequently used words):
uh, oh, navigation, and, start, automatically, saved, searches, airconnect, to, upnp, sonos, files, parameters, in, tips, http, source, footer, search, code, repositories, users, issues, pull, requests, provide, feedback, philippe44, send, audio, chromecast, players, using, airplay, menu, use, filter, your, results, more, quickly, folders, latest, commit, history, repository, installing, running, common, information, config, file, linux, macos, credits, aiwipro, under, windows, synology, installation, player, specific, hints, misc, specificities, delay, when, switching, track, or, latency, explained, compiling, from, about, releases, 55, packages, contributors, languages, content, length, transfer, modes, topics, resources, license, stars, watchers, forks, bose, soundtouch, pioneer, phorus, play, fi,
Text of the page (most frequently used words):
the (211), and (89), that (58), for (58), not (46), audio (45), use (43), http (40), you (39), upnp (39), will (38), this (36), can (35), player (32), #players (32), when (32), sonos (31), airplay (30), #airconnect (29), rtp (25), file (25), airupnp (24), but (24), your (22), there (20), all (20), set (20), chromecast (19), using (19), default (19), have (18), start (18), with (17), frames (17), command (16), some (16), are (16), source (15), might (15), version (15), service (15), string (15), time (14), delay (14), then (14), has (14), does (14), see (13), from (13), length (13), macos (13), github (12), received (12), support (12), port (12), name (12), bridge (11), build (11), code (11), line (11), iphone (11), silence (11), where (11), only (11), key (11), content (11), security (10), one (10), they (10), parameter (10), network (10), flush (10), new (10), aircast (10), view (9), devices (9), work (9), example (9), frame (9), connection (9), stop (9), immediately (9), play (9), latency (9), application (9), same (9), config (9), executable (9), while (8), please (8), more (8), buffer (8), sent (8), any (8), create (8), open (8), mode (8), mp3 (8), lib (8), reload (7), stream (7), option (7), need (7), get (7), here (7), windows (7), send (7), available (7), playback (7), device (7), these (7), encoding (7), flac (7), common (7), install (7), below (7), don (6), com (6), playing (6), cannot (6), client (6), request (6), made (6), data (6), note (6), than (6), before (6), large (6), most (6), other (6), issue (6), between (6), track (6), like (6), change (6), section (6), case (6), static (6), libraries (6), after (6), volume (6), value (6), window (6), linux (6), cpu (6), search (6), local (6), openssl (6), enterprise (6), navigation (5), page (5), license (5), readme (5), adding (5), philippe44 (5), built (5), platform (5), native (5), many (5), video (5), speakers (5), close (5), last (5), every (5), congestion (5), real (5), format (5), ios (5), seconds (5), simply (5), needed (5), works (5), try (5), range (5), add (5), http_length (5), must (5), run (5), each (5), path (5), xml (5), plist (5), ports (5), aac (5), usr (5), community (4), was (4), error (4), loading (4), repository (4), dlna (4), just (4), otherwise (4), script (4), used (4), exact (4), control (4), speaker (4), protocol (4), allow (4), continuous (4), receive (4), sending (4), binary (4), non (4), which (4), being (4), pull (4), parameters (4), understand (4), should (4), chunked (4), another (4), directory (4), system (4), users (4), tips (4), master (4), group (4), now (4), appear (4), automatically (4), log (4), type (4), sudo (4), enable (4), also (4), interactive (4), solutions (4), them (4), files (4), dylib (4), zip (4), issues (4), stars (3), resources (3), topics (3), make (3), commits (3), update (3), how (3), cmd (3), played (3), because (3), public (3), almost (3), still (3), missing (3), restart (3), once (3), into (3), normally (3), again (3), exit (3), possible (3), lost (3), happens (3), burst (3), delays (3), its (3), response (3), creates (3), clock (3), without (3), self (3), switch (3), pause (3), chunk (3), first (3), very (3), adds (3), expect (3), wire (3), applications (3), why (3), want (3), size (3), message (3), lots (3), quality (3), fails (3), load (3), app (3), libstdc (3), avahi (3), best (3), codec (3), out (3), bose (3), soundtouch (3), click (3), stored (3), user (3), true (3), library (3), above (3), configuration (3), systemd (3), following (3), disable (3), target (3), var (3), arm (3), 1000 (3), 2000 (3), count (3), maximum (3), recommended (3), pcm (3), 1152 (3), artwork (3), metadata (3), buffering (3), force (3), advanced (3), opt (3), changelog (3), commit (3), insights (3), requests (3), signed (3), settings (3), tab (3), refresh (3), session (3), sign (3), saved (3), documentation (3), feedback (3), grade (3), features (3), copilot (3), explore (3), information (2), manage (2), status (2), footer (2), 2026 (2), makefile (2), releases (2), latest (2), forks (2), 247 (2), about (2), speed (2), lot (2), clone (2), probably (2), git (2), init (2), pre (2), binaries (2), know (2), bash (2), able (2), directly (2), look (2), way (2), computer (2), ipad (2), mac (2), amount (2), advance (2), usually (2), although (2), synchronization (2), sometimes (2), inserted (2), soon (2), been (2), server (2), necessary (2), buffers (2), 500 (2), ones (2), numbered (2), forward (2), decoded (2), raw (2), were (2), transmitted (2), sets (2), long (2), shall (2), two (2), obviously (2), lack (2), notion (2), sequentially (2), udp (2), means (2), often (2), networks (2), detection (2), certain (2), beginning (2), further (2), transmission (2), initial (2), portion (2), enough (2), handle (2), flow (2), such (2), comes (2), 8ms (2), body (2), starts (2), shuttering (2), controller (2), exist (2), side (2), clients (2), explained (2), unfortunately (2), nothing (2), identify (2), addition (2), produced (2), additional (2), later (2), tracks (2), stops (2), until (2), few (2), consume (2), byte (2), quickly (2), creating (2), act (2), virtual (2), instead (2), fact (2), looking (2), pipe (2), plays (2), deal (2), second (2), what (2), through (2), existing (2), better (2), read (2), next (2), trying (2), header (2), worse (2), who (2), effect (2), standard (2), clear (2), optional (2), stacks (2), main (2), provide (2), transfer (2), anything (2), grab (2), mdns (2), 5353 (2), etc (2), skipping (2), seems (2), problem (2), cases (2), noflush (2), https (2), www (2), misc (2), found (2), well (2), including (2), address (2), 192 (2), review (2), under (2), volumes (2), individual (2), created (2), specific (2), installation (2), launch (2), tools (2), xxx (2), apple (2), dtd (2), dict (2), array (2), docker (2), thanks (2), systemctl (2), manually (2), online (2), uses (2), bitrate (2), 128 (2), 16384 (2), wav (2), factor (2), commands (2), icy (2), enables (2), too (2), drift (2), tweaking (2), except (2), apply (2), synchronized (2), details (2), freebsd (2), solaris (2), disables (2), interface (2), listen (2), 49152 (2), card (2), rate (2), changes (2), save (2), normal (2), machines (2), messages (2), itunes (2), airfoil (2), typing (2), machine (2), options (2), terminal (2), chmod (2), aarch64 (2), libcrypto (2), libssl (2), links (2), arm64 (2), x86_64 (2), x86 (2), updater (2), buildall (2), gitmodules (2), gitignore (2), gitattributes (2), 686 (2), actions (2), menu (2), projects (2), discussions (2), appearance (2), cancel (2), searches (2), repositories (2), business (2), developer (2), customer (2), services (2), devops (2), perform, action, share, personal, cookies, contact, docs, privacy, terms, inc, batchfile, shell, languages, contributors, packages, jun, report, watching, watchers, activity, doing, clonings, shallow, depth, submodule, rebuild, apps, general, oriented, intended, cross, call, compiler, sure, compiling, asked, synchronisation, tablet, youtube, due, bridging, done, controlled, achieve, known, sec, output, timing, maintains, relay, their, lucky, match, reproductible, stable, over, during, ensure, unlikely, though, interrupted, anyway, empty, resumes, less, potentially, transformed, receives, resent, hold, waiting, nice, held, larger, forwards, numbers, guarantee, delivery, wifi, consecutive, requested, receiver, artificial, hide, happen, expects, rest, regulated, tcp, forwarded, continuation, 1st, sample, expecting, follow, delaying, starve, bridges, realtime, synchronous, asynchronous, words, push, avoid, increase, depending, difference, say, faster, 300s, 5mins, 297s, moves, sources, sends, consumed, counting, come, likely, occurs, stutter, solves, establishing, permanent, wait, buffered, even, wires, whole, retrieve, functions, function, seen, recent, versions, anymore, decide, could, big, nowadays, closing, pushes, previous, thing, stopping, pausing, pushing, paragraph, won, quick, summary, far, sender, concerned, established, analogue, question, times, hear, switching, randomly, accessible, searchable, 128kb, smart, guess, keep, recently, bytes, resend, always, ask, 200, full, tried, accept, makes, things, claim, resort, fake, around, hours, http_header, fallback, omitted, possibility, divided, chunks, variable, unknown, claims, explicitely, poor, itself, poorly, defined, certified, difficulty, streamed, infinite, coming, modes, specificities, complaining, glibcxx_3, provided, copy, right, symlink, trick, messing, ld_library_path, origin, older, distributions, exclusive, preventing, respond, queries, daemon, conf, disallow, causes, workaround, ignore, delayed, unify, broadcasting, finding, guide, somebody, fixes, his, neilgrogan, ubnt, disappear, regularly, router, filtering, multicast, packets, asus, rt68u, login, ssh, echo, sys, class, net, br0, multicast_snooping, stay, reboot, pioneer, phorus, synchonisation, grouping, ungrouping, level, slave, did, chpusch, pick, identified, visit, browser, identifiers, column, uuid, zone, 168, 126, 1400, changing, changed, respect, relative, values, perfect, stil, test, reset, move, cursor, others, removed, already, detected, split, hints, maitaining, package, automatic, syno, eizedev, synology, utf, doctype, dtds, propertylist, label, programarguments, runatload, launchonlyonce, keepalive, launchagents, credits, aiwipro, container, follows, 1activegeek, custom, cleaning, cactus, rpi, lite, boot, cmdline, txt, bin, journalctl, unit, description, wants, execstart, failure, restartsec, wantedby, multi, assuming, limits, limit, log_limit, max_players, global, 320kb, blocksize, reduced, lower, 320, 4096, applies, scaling, hardware, media_volume, url, displayed, codecs, supports, upnp_max, discovered, dedicated, enabled, dropping, producion, fast, slow, bad, normaly, 500ms, negative, silent, restarts, overload, choice, regardless, tickets, requesting, noise, heard, timings, adjusted, adjustements, cause, overrun, underrun, playbacks, daemonize, method, disabling, tty, daemonizes, pid, followed, tweak, fixed, dummy, specify, reported, ifconfig, ipconfig, iface, searched, ethernet, bind, authorized, explanation, groups, supported, media, reference, generated, scan, 30s, prev, paused, started, typed, prompt, current, named, includes, inside, dependence, 3rd, party, shared, ssl, especially, old, systems, linkage, blessing, curse, reasons, scope, pretty, technical, help, terminates, relaunch, background, startup, else, required, screen, heos, double, running, host, webserver, nat, runs, ter, faserf, extra, discovery, upnp_socket, permanently, rtsp, random, firewall, directories, permissions, store, microsoft, redistributable, dlls, put, exe, least, number, brew, really, unless, regular, steps, dynamic, intel, downloaded, unzip, select, wget, githubusercontent, installing, alac, plain, encoded, display, artist, title, album, access, sparc, mips, powerpc, raspberry, detect, proxy, capabilities, items, history, date, folders, tags, branches, star, fork, notification, notifications, dismiss, alert, switched, accounts, resetting, focus, qualifiers, our, query, filter, results, submit, include, email, contacted, piece, take, input, seriously, syntax, jump, pricing, premium, ons, powered, collections, trending, archive, program, accelerator, maintainer, lab, programs, fund, developers, sponsors, partners, trust, center, forum, skills, ebooks, reports, events, webinars, stories, software, development, topic, industries, government, manufacturing, financial, healthcare, industry, devsecops, modernization, nonprofits, startups, small, medium, teams, enterprises, company, marketplace, blog, leaks, secret, protection, secure, find, fix, vulnerabilities, plan, instant, dev, environments, codespaces, automate, workflow, workflows, integrate, external, mcp, registry, direct, agents, merge, write, creation, toggle, skip,
Text of the page (random words):
isable the service type sudo systemctl disable airupnp service to view the log journalctl u airupnp service on rpi lite add the following to the boot cmdline txt init bin systemd obviously from the above example only use x if you want a custom configuration thanks cactus for systemd cleaning 1activegeek has made a docker container here that follows the update of this repository thanks start automatically in macos credits aiwipro create the file com aircast bridge plist in library launchagents xml version 1 0 encoding utf 8 doctype plist public apple dtd plist 1 0 en http www apple com dtds propertylist 1 0 dtd plist version 1 0 dict key label key string com aircast bridge string key programarguments key array string path aircast macos string string z string string x string string path aircast xml string string f string string path aircast log string array key runatload key true key launchonlyonce key true key keepalive key true dict plist where path is the path where you ve stored the aircast executable without the it can be for example users xxx airconnect where xxx is your user name start automatically under windows there are many tools that allow an application to be run as a service you can try this one synology installation eizedev is now maitaining a package for automatic installation launch of airupnp on syno s here player specific hints and tips sonos the upnp version is often used with sonos players when a sonos group is created only the master of that group will appear as an airplay player and others will be removed if they were already detected if the group is later split then individual players will re appear when changing volume of a group each player s volume is changed trying to respect the relative values it s not perfect and stil under test now to reset all volumes to the same value simply move the cursor to 0 and then to the new value all players will have the same volume then you need to use the sonos application to change individual volumes to identify your sonos players pick an identified ip address and visit the sonos status page in your browser like http 192 168 1 126 1400 support review click zone players and you will see the identifiers for your players in the uuid column bose soundtouch chpusch has found that bose soundtouch work well including synchonisation as for sonos you need to use bose s native application for grouping ungrouping i don t have a soundtouch system so i cannot do the level of slave master detection i did for sonos pioneer phorus play fi some of these speakers only support mp3 misc tips when players disappear regularly it might be that your router is filtering out multicast packets for example for a asus ac rt68u you have to login by ssh and run echo 0 sys class net br0 bridge multicast_snooping but it does not stay after a reboot lots of users seems to have problem with unify and broadcasting finding players here is a guide https www neilgrogan com ubnt sonos made by somebody who fixes the issue for his sonos some airplay controller send a flush and immediately start sending new audio when skipping track this causes airconnect to issue a stop and almost immediately a play command which seems to be a problem for certain players sonos in some cases a possible workaround is to ignore flush request see config file or use noflush on the command line but this has side effect on pause as silence frames are sent at best restart is delayed and worse case it might not work with some codec flac some older avahi distributions grab the port mdns port 5353 for exclusive use preventing airconnect to respond to queries please set disallow other stacks no in etc avahi avahi daemon conf if the non static version fails to load complaining that glibcxx_3 4 29 is missing please have a look there and use the existing libraries i ve provided in that repository you can simply copy the right libstdc so 6 0 29 in the directory where airconnect is and create symlink for libstdc so and libstdc so 6 then use the ld_library_path origin app trick it will work without messing anything in your system http upnp specificities http content length and transfer modes lots of upnp player have very poor quality http and upnp stacks in addition of upnp itself being a poorly defined certified standard one of the main difficulty comes from the fact that airconnect cannot provide the length of the file being streamed as the source is an infinite real time rtp flow coming from the airplay source the http standard is clear that the content length header is optional and can be omitted when server does not know the size of the source if the client is http 1 1 there is another possibility which is to use chunked mode where the body of the message is divided into chunks of variable length this is explicitely made for case of unknown source length and an http client that claims to support 1 1 must support chunked encoding the default mode of airupnp is no content length http_length 1 but unfortunately some players can t deal with that you can then try chunked encoding http_length 3 but some players who claim to be http 1 1 do not support it there is a last resort option to add a large fake content length http_length 0 it is set to 2 31 1 so around 5 hours of playback with flac re encoding note that if player is http 1 0 and http_header is set to 3 airupnp will fallback no content length the command line option g has the same effect that http_length in the common section of a config file this might still not work as some players do not understand that the source is not a randomly accessible searchable file and want to get the first e g 128kb to try to do some smart guess on the length close the connection re open it from the beginning and expect to have the same content i m trying to keep a buffer of last recently sent bytes to be able to resend it but that does not always works normally players should understand that when they ask for a range and the response is 200 full content it means the source does not support range request but some don t i ve tried to add a header accept no range but that makes things worse most of the time delay when switching track or source i ve received that question many times why is there sometimes many seconds of delay when i switch track or source from my iphone before i hear the change to understand it s better that you read the next paragraph but as you probably won t here is a quick summary of how airplay works as far as the sender e g your iphone is concerned once the connection with an airplay speaker is established this connection is almost like a analogue wire with a delay buffer of 1 or 2 seconds what ios does nowadays is that when you switch between tracks instead of closing the connection and re creating one it just pushes the new audio through the existing connection so you might have the 1 2 seconds of previous audio in the pipe before the new audio plays same thing when stopping pausing playback ios simply stops pushing audio through the wire there is a function to flush the audio in the pipe so that new audio plays immediately but i ve seen that recent versions of ios don t use it anymore or some applications decide to not flush while they could that s not a big deal with most airplay speakers it s a 1 2 second delay but with airconnect the airplay speaker is not a speaker it s a upnp or chromecast player they do not at all act like virtual wires they instead expect to have the whole track available as a file and retrieve data from it as needed in fact one of the key functions that airconnect does is looking like a wire to iphone and looking like a file to the upnp cc usually upnp cc players consume a large chunk of that file before they start to play to handle network congestion but some don t and simply start playing at the first received byte counting that the large chunk will come quickly but that chunk buffer does not exist for airconnect as audio is produced in real time by the iphone so if a player starts at the first byte it will very likely lack audio data when a network congestion occurs and playback will stutter the parameter http latency solves this issue by creating a silence buffer sent in a burst when establishing a connection but this creates a permanent delay between the iphone and the player some upnp cc players wait to have buffered enough data before they start playing and again because that data is built in real time by airconnect this other delay adds up to the latency parameter even if http latency is 0 when you switch between tracks or sources or pause stop if your iphone sends this flush command then airconnect immediately stops the upnp cc player but if there is no flush command it will play until these silence self buffers are consumed that can be more than a few seconds in addition the delay can increase with time depending of clock speed difference between the iphone and the upnp cc say that the iphone s clock is 1 faster than the player s clock then when it has produced 300s 5mins of audio the player has received it all but it has only played 297s so there is an additional delay of 3s if the iphone moves track without the flush command then the upnp cc player will start playing new audio or stop http latency self buffer length 3 seconds later that can be a lot unfortunately there is nothing i can do about that by not using the flush command ios or application using airplay create an issue that airconnect has no way to identify or avoid latency parameters explained these bridges receive realtime synchronous audio from the airplay controller in the format of rtp frames and forward it to the chromecast upnp sonos player in an http asynchronous continuous audio binary format notion of frames does not exist on that side in other words the airplay clients push the audio using rtp and the chromecast upnp sonos players pull the audio using an http get request a player using http to get its audio expects to receive an initial large portion of audio as the response to its get and this creates a large enough buffer to handle most further network congestion delays the rest of the audio transmission is regulated by the player using tcp flow control but when the source is an airplay rtp device there is no such large portion of audio available in advance to be sent to the player as the audio comes to the bridge in real time every 8ms a rtp frame is received and is immediately forwarded as the continuation of the http body if the cc upnp sonos players starts to play immediately the 1st received audio sample expecting an initial burst to follow then any network congestion delaying rtp audio will starve the player and create shuttering the http parameter allow a certain amount of silence frames to be sent to the chromecast upnp sonos player in a burst at the beginning then while this artificial silence is being played it s possible for the bridge to build a buffer of rtp frames that will then hide network delays that might happen in further rtp frames transmission this delays the start of the playback by http ms but rtp frames are transmitted using udp which means there is no guarantee of delivery so frames might be lost from time to time happens often on wifi networks to allow detection of lost frames they are numbered sequentially 1 2 n so every time two received frames are not consecutive the missing ones can be requested again by the airplay receiver normally the bridge forwards immediately every rtp frame using http and again in http the notion of frame numbers does not exit it s just the continuous binary audio so it s not possible to send audio non sequentially when using http for example if received rtp frames are numbered 1 2 3 6 this bridge will forward once decoded and transformed into raw audio 1 2 3 immediately using http but when it receives 6 it will re request 4 and 5 to be resent and hold 6 while waiting if 6 were to be transmitted immediately the chromecast upnp sonos will play 1 2 3 6 not nice the rtp parameter sets for how long frame 6 shall be held before adding two silence frames for 4 and 5 and send sending 4 5 6 obviously if this delay is larger than the buffer in the chromecast upnp sonos player playback will stop by lack of audio note that rtp does not delay playback start when f is set silence frames will be inserted as soon as no rtp frames have been received during rtp ms this ensure that a continuous stream of audio is available on the http server this might be necessary for some players that close the http connection if they have not received data for some time it s unlikely though note that otherwise when rtp stream is interrupted for more than http ms the upnp cc player will stop anyway as it will have empty buffers still as soon as the rtp stream resumes the bridge will receive frame n where the last received one might be n 500 so it will request the up to rtp missing ones might be less than 500 and restart playing at n http so potentially silence will be inserted many have asked for a way to do video audio synchronisation so that upnp sonos players can be used as speakers when playing video on a computer or tablet youtube for example due to this rtp to http bridging this cannot be done as the exact time when an audio frame is played cannot be controlled on the http client airplay speakers can achieve that because the iphone ipad mac player will delay the video by a known amount send the audio in advance usually 2 sec and then control the exact time when this audio is output by the speaker but although airconnect has the exact request timing and maintains synchronization with the player it cannot relay that synchronization to the speakers upnp protocol does not allow this and sonos has not made their protocol public sometimes you might get lucky because the video to audio delay will almost match the http player delay but it is not reproductible and will not be stable over time compiling from source it s a makefile oriented build and there is a bash script built sh and windows one build cmd the bash script is intended for cross platform build and you might be able to call directly your native compiler but have a look at the command line in the build sh to make sure it can work please see here to know how to rebuild my apps in general otherwise you can just get the source code and pre built binaries cd git clone http github com philippe44 airconnect cd airconnect git submodule update init nb you can speed up all clonings by a lot by adding depth 1 option to just to a shallow clone you probably don t need all the commits and build doing cd airconnect airupnp make about use airplay to stream to upnp sonos chromecast devices topics chromecast sonos bridge airplay upnp dlna dlna upnp dlna player resources readme license view license uh oh there was an error while loading please reload this page activity stars 4 1k stars watchers 68 watching forks 247 forks report repository releases 55 1 10 1 latest jun 28 2026 54 releases packages...
|