[TUT] How To Get Airplay On Your iDevice 4.0+

Discussion in 'iPod touch' started by Virtualball, Oct 11, 2010.

  1. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    As I sit here, going over the mountain of coursework that I have yet to even begin for my Comparative Studies class, my mind wanders to the glorious thought of wireless speakers. See, I’m a nerd by nature, so obviously, I think about thinks like Apple’s AirPlay often. After looking up speakers and then laughing at the price tag that would pay for another quarter of my tuition, I got creative. This post will follow my ventures into hacking my iPhone 3GS into running AirPlay and the benefits of said hack.

    Before I start, I know that one must catch their audiences’ attention early on, so I will state how I’m currently using AirPlay. I have a pretty big room in my off-campus house, and I’ve always wanted surround sound speakers to fill my ears with mp3-laden audio, but it’s always been ridiculously expensive. Now, I have a cheap system that works remarkably well! More on this later, though; first we have to discuss how one goes about achieving the AirPlay feat.

    To begin, one has to have at least iOS 4.0 (4.1 preferred) that is jailbroken and a wireless network. Pretty simple, right? Well, I’m not going to teach you how to jailbreak your iDevice, so I will just link you to the iPhone Dev Team, http://blog.iphone-dev.org Once you have successfully jailbroken your iPod/iPhone, we can actually start.


    Step 1: Download and Open the AppleTV 2 OS


    To download the AppleTV Operating System, just click this link! Now that that’s done downloading, you need to unpack the software. On Mac OS X, just rename the filename to end in “.zip” and then double-click. In Windows, I believe you can open it in WinRAR, if you so choose. Now that it’s unpacked, just look for “018-8609-066.dmg” in the folder “AppleTV2,1_4.1_8M89_Restore.ipsw”

    Please Register or Log in to view images


    That wasn't too hard, right?

    If you try to open it, you’ll notice that it doesn’t exactly work, right? That’s because it’s encrypted with a certain key that only Apple knows. Well, sort of. Thanks to the amazing hackers of the Dev Team, the key to the disk has been uncovered; it’s 31c700a852f1877c88efc05bc5c63e8c7f081c4cb28d024ed7f9b0dbc98c7e1406e499c6 . To open the disk, one needs to find a copy of a tool named “vfdecrypt,” which is located here for Intel Macs and here for Windows. Alright, I’m going to be blunt here; I haven’t used vfdecrypt for Windows, but hopefully it works in cmd. Therefore, these instructions will be for Mac OS X only right now.
  2. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    Open up Terminal in the Applications/Utilities folder and then type the following:

    cd [Drag and Drop vfdecrypt folder you downloaded]
    --Hit the Return key
    ./vfdecrypt –I [Drag and Drop the 018-8609-066.dmg file] –o ./AppleTV.dmg –k 31c700a852f1877c88efc05bc5c63e8c7f081c4cb28d024ed7f9b0dbc98c7e1406e499c6
    --Hit the Return key
    [Wait till it does its job]
    open ./ AppleTV.dmg
    That’s it. Hopefully you should now be greeted with this screen:

    Please Register or Log in to view images



    Step 2: Transplanting the Needed Files


    Click thru the following folder hierarchy; /System/Library/LaunchDaemons and then find “com.apple.airtunesd.K66.plist” and drag it to the desktop. Now, go to /usr/libexec/ and grab “airtunesd” and drag it to your desktop. The first file is a file that tells the iDevice to keep AirPlay running whenever the iDevice restarts. The second file is the actual AirPlay service.
    Next, you have to open the first file in TextEdit or Plist Editor and change the “AppleTV2,1” to your iDevice codename. For me, it was iPhone2,1 for the 3GS, but for completion sake, here’s a list of the codenames:

    • iPhone 3G = iPhone1,2
    • iPhone 3GS = iPhone2,1
    • iPhone 4 = iPhone3,1
    • iPod Touch 2nd Gen = iPod2,1
    • iPod Touch 3rd Gen = iPod3,1
    • iPod Touch 4th Gen = iPod4,1

    Save and continue. Now, it couldn’t hurt to take the “K66” out of the file name, so do that now. From this point on, I’m going to expect that you are semi-proficient in what you’re doing. Sorry. SFTP the files to their corresponding place on your iDevice. To do this, I use Transmit for Mac OS X. Just connect the device (default name

    Please Register or Log in to view images

    assword is root:alpine) and then drag and drop the files from your desktop to the folders that you took them from (/System/Library/LaunchDaemons and /usr/libexec/). Make sure their permissions are 755 and then SSH into the device and type this:

    launchctl start com.apple.airtunesd
    [Return Key]​

    Once that’s done, you now have AirPlay! Now to the nitty-gritty.
  3. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    Step 3: Playing Files


    To stream audio to your device, just launch iTunes and select it on the AirPlay icon located on the bottom bar. (It’s two radar-like icons)

    Please Register or Log in to view images

    Hey, that's me!​


    Hopefully, if all went well, it should start playing! Wait a minute, it’s not playing you say? Ah, you’re obviously not on iOS 4.1! Fear not, there’s another, arguably better solution. Download AirFoil from Rogue Amoeba’s website and then install it. Once opened, you can select your device and it should work! Huzzah!

    Please Register or Log in to view images



    My Current Setup

    I currently have my laptop on my desk in one corner of the room and my Sony DreamMachine speaker-dock in the other corner. Clicking both volume buttons on the window above and selecting System Audio allows me to stream my computers audio to both sides of the room! (You’ll have to install an add-on for this to work, but it’s simple). I now have near-surround sound in my college bedroom, and for pretty cheap considering I already owned all of this equipment. Most people already have an iPod, laptop, and iHome-typed speaker. Anyways, everything works perfectly, well… sort of….

    Caveats and Wrap-Up

    There’s two downsides to this set up, but they’re not that bad.. One problem is that the audio gets choppy when the screen is turned off on the device. Remedy this by turning the auto-screen dim to “never.” See, not too bad? The second problem is that videos can’t be streamed because the audio is out of sync, but that could just be over my wireless connection, so mileage may vary.

    So, was it worth it? Hell yeah. A couple of hours ago, I was researching $700+ speakers that don’t come out for who knows how long. Now, I have spent 0$ and have converted my aging iPod dock into a wireless speaker that allows me to fill my room with lush-sounding indie music! Also, I have the satisfaction of hacking a device, and to be honest, isn’t that enough? To be frank, this set up rocks and I hope that this post can help someone out there have fun and save money, too! Post a comment if you have anything to add or if you’d like to critique/comment on this. Until next time, rock on!
  4. iBricked

    iBricked Well-Known Member

    Joined:
    Apr 16, 2010
    Messages:
    5,874
    Likes Received:
    39
    Device:
    iPhone 5S
    Works on windows xp confirmed. This is awesome thanks.
    No need for buying dock now...
  5. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    Woot!

    Also, you can control it with the Remote app!

    Please Register or Log in to view images



    Please Register or Log in to view images



    Woot!
  6. ayeitschris

    ayeitschris Member

    Joined:
    Jul 25, 2010
    Messages:
    300
    Likes Received:
    6
    Device:
    4G iPod touch
    wait what. whats airplay. does this make itunes stream music to your ipod?
  7. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    Yes, it allows iTunes to stream any song to your iPod/iPhone and play it at the same time. This allows me to stream to my TV OR it allows me to stream it to my speakers, making a surround sound system!

    Please Register or Log in to view images

  8. ayeitschris

    ayeitschris Member

    Joined:
    Jul 25, 2010
    Messages:
    300
    Likes Received:
    6
    Device:
    4G iPod touch
    oh snap, how do you stream it to your speakers and tv? do they have to be airplay compatible or something?
  9. Virtualball

    Virtualball Well-Known Member

    Joined:
    Nov 23, 2007
    Messages:
    1,118
    Likes Received:
    63
    Read the tutorial. It allows you to stream to your iPod which can then be plugged into your speakers/TV. No extra money necessary!
  10. gabixd122

    gabixd122 New Member

    Joined:
    Jun 14, 2009
    Messages:
    68
    Likes Received:
    0
    Device:
    4G iPod touch
    works for windows?

Share This Page