Posts: 9
Joined: Sep 2016
Reputation:
0
I have a project to do a receiver app for airplay using c language. unfortunately, the function of airplay here in kodi is written in c++ and i am not good enough to understand c++. Is there a complete guide/documentation on how kodi implemented the airplay function?
Right now I have written a simple code to let avahi broadcast the _airplay._tcp service which i read from the log of kodi and by editing the sample code in client-publish-service.c of avahi examples, but my phone doens't detect it yet. I know i'm missing a lot here can someone please explain.
Thanks for your time!
Posts: 9
Joined: Sep 2016
Reputation:
0
<?xml version="1.0" standalone='no'?><!--*-nxml-*-->
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<service-group>
<name replace-wildcards="yes">service on %h</name>
<service>
<type>_airplay._tcp</type>
<port>36667</port>
<txt-record>model=Xbmc,1</txt-record>
<txt-record>deviceid=C4:46:19:70:43:84</txt-record>
<txt-record>srcvers=101.28</txt-record>
<txt-record>features=0x20F7</txt-record>
</service>
<service>
<type>_raop._tcp</type>
<port>36666</port>
<txt-record>txtvers=1</txt-record>
<txt-record>cn=0,1,</txt-record>
<txt-record>ch=2</txt-record>
<txt-record>ek=1</txt-record>
<txt-record>et=0,1</txt-record>
<txt-record>sv=false</txt-record>
<txt-record>tp=UPD</txt-record>
<txt-record>sm=false</txt-record>
<txt-record>ss=16</txt-record>
<txt-record>sr=44100</txt-record>
<txt-record>pw=false</txt-record>
<txt-record>vn=3</txt-record>
<txt-record>da=true</txt-record>
<txt-record>md=0,1,2</txt-record>
<txt-record>am=Kodi,1</txt-record>
<txt-record>vs=130.14</txt-record>
</service>
</service-group>
I have already made a file that includes the text above and i am able to detect it using the avahi-browser -alr command but my phone is still not able to detect it. I believe that there is also a need for http commands but i dont know how to implement it in c language though(I can learn through tutorials I will find).Im hoping to get some ideas on how does kodi get the data or maybe how does the phone able to detect the kodi when airplay is on.
thank you for your response!
Posts: 16,946
Joined: Feb 2011
Reputation:
256
This is over your head. Start with something easier. My 2 cents.
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much:
click here
HowTo setup NFS for Kodi:
NFS (wiki)
HowTo configure avahi (zeroconf):
Avahi_Zeroconf (wiki)
READ THE IOS FAQ!:
iOS FAQ (wiki)
Posts: 9
Joined: Sep 2016
Reputation:
0
I know it is not easy but can you give some guides where to start first? Right now I want to publish a server and let my phone able to detect it and after doing that I will research on how this http requests are processed. Hoping for your help! Thanks Memphiz!
Posts: 16,946
Joined: Feb 2011
Reputation:
256
not enough time for such a side project - sorry.
AppleTV4/iPhone/iPod/iPad: HowTo find debug logs and everything else which the devs like so much:
click here
HowTo setup NFS for Kodi:
NFS (wiki)
HowTo configure avahi (zeroconf):
Avahi_Zeroconf (wiki)
READ THE IOS FAQ!:
iOS FAQ (wiki)