AppleTV Notes

3 minute read

Hardware

  • trek voorzichtig de gummy onderkant van de ATV
  • schroef de vier hoevijzen los en neem de onderplaat voorzichtig uit de behuizing
  • de harde schijf zit vast tegen de onderplaat, schroef ook deze los
  • monteer de harde schrijf in een behuizing en sluit aan via Firewire of USB op een Mac(Book)

Software

sshd

Met een sshd kunnen we verder alles vanop afstand doen:

  • download OpenSSH-56.root.tar.gz
  • installeer sshd
 $ sudo cp OpenSSH-56.root/usr/sbin/sshd /Volumes/OSBoot/usr/sbin/
 $ cp /Volumes/OSBoot/System/Library/LaunchDaemons/ssh.plist .
 $ cp ssh.plist.txt /Volumes/OSBoot/System/Library/LaunchDaemons/ssh.plist 
  • kuis Spotlight stuff op
 $ sudo rm -rf /Volumes/OSBoot/.Spotlight-V100/
 $ sudo rm -rf /Volumes/Media/.Spotlight-V100/
  • om de automatische updates te hinderen …
 $ sudo echo "127.0.0.1 mesu.apple.com" >> /Volumes/OSBoot/etc/hosts
  • monteer harde schijf terug in ATV behuizing en boot …
  • maak ssh verbinding
 ssh -1 frontrow@AppleTV.local

DivX, Xvid, …

  • download Perian-1.0
  • haal de .componenten uit de dmg en copieer ze naar de ATV
 $ scp -1 -r A52Codec.component/ AC3MovieImport.component/ Perian.component/  frontrow@AppleTV.local:~
  • installeer ze op de ATV
 $ sudo mount -uw /
 $ sudo mv A52Codec.component/ /Library/Audio/Plug-Ins/Components/
 $ sudo mv Perian.component/ AC3MovieImport.component/ /Library/QuickTime/

ATVFiles

  • met ATVFiles kan je via bestanden uit ~frontrow/Movies benaderen vanuit de ATV interface
  • download ATVFiles-0.5.1.run en copieer de file naar de ATV
 $ scp -1 ATVFiles-0.5.1.run.sh frontrow@AppleTV.local:~
  • installeer ze
 $ sudo sh ATVFiles-0.5.1.run.sh

Mount remote share

Dit werkt alleen nog onder de 1.0 release van de ATV. Als je de 1.1 update al hebt … Factory reset (menu knop + volume down knop ingedrukt houden)

  • make een mountpoint aan, bvb onder Movies en mount een gesharede disk
 $ cd Movies
 $ mkdir Shared
 $ mount_afp afp://<user>:<passwd>@<server>/Shared/ Shared/
  • om de share elke keer te mounten als de ATV reboot
 $ sudo sh
 # echo "mount_afp afp://<user>:<passwd>@<server>/Shared ~frontrow/Movies/Shared" >> /etc/rc.local

Mount SMB share

Download

After downloading the Mac OS X 10.4.9 Combo, mount it and extract the actual Archive:

$ hdiutil mount MacOSXUpdCombo10.4.9Intel.dmg
$ mkdir tmp
$ cd tmp
$ pax -r -z <  /Volumes/Mac\ OS\ X\ 10.4.9\ Combined\ Update\ \(Intel\)/MacOSXUpdCombo10.4.9Intel.pkg/Contents/Archive.pax.gz

Next copy mount_smbfs and the smbfs.kext to the AppleTV

$ scp sbin/mount_smbfs AppleTV.local
$ scp -r System/Library/Extensions/smbfs.kext AppleTV.local:

On the AppleTV, move them in the correct location and make them more userfriendly:

$ sudo /bin/bash
...
$ cp mount_smbfs /sbin/
$ cp -r smbfs.kext /System/Library/Extensions/
$ chmod +s /sbin/mount_smbfs

Add turbo_atv_enabler.bin

To be able to load the kernel extensions, we need to use the turbo_atv_enabler.bin. First copy it to the AppleTV and move it into place:

$ scp turbo_atv_enabler.bin AppleTV.local
$ ssh -1 frontrow@AppleTV.local
...
$ sudo /bin/bash
...
$ cp turbo_atv_enabler.bin /sbin/turbo_kext_enabler.bin
$ chown root:wheel /sbin/turbo_kext_enabler.bin
$ chmod 555 /sbin/turbo_kext_enabler.bin

Set up a /etc/rc.local that works

$ cat /etc/rc.local
#!/bin/sh
ifconfig waitall
/sbin/turbo_kext_enabler.bin
kextload /System/Library/Extensions/smbfs.kext
mkdir -p ~frontrow/Movies/FatBoy
chown -R frontrow ~frontrow/Movies
ping -c2 fatboy.local # needed because we loose the first packet(s)
mount_smbfs "//atv:atv@fatboy.local/Media" ~frontrow/Movies/FatBoy

Veilig upgraden naar 1.1

 $ scp -1 ~/Downloads/2Z694-5248-45.dmg frontrow@AppleTV.local:~
  • backup 1.0 bestanden
 $ mkdir ~/1.0.backup
 $ cp -p -r "/System/Library/PrivateFrameworks/Backrow.Framework" ~/1.0.backup
 $ cp -p -r "/System/Library/CoreServices/Finder.app" ~/1.0.backup
  • extract 1.1 bestanden
 $ mkdir ~/1.1.files
 $ hdiutil mount 2Z694-5248-45.dmg
 $ cp -p -r "/Volumes/OSBoot 1/System/Library/PrivateFrameworks/BackRow.Framework" ~/1.1.files
 $ cp -p -r "/Volumes/OSBoot 1/System/Library/PrivateFrameworks/AppleTV.Framework" ~/1.1.files
 $ cp -p -r "/Volumes/OSBoot 1/System/Library/PrivateFrameworks/iPhotoAccess.Framework" ~/1.1.files
 $ cp -p -r "/Volumes/OSBoot 1/System/Library/CoreServices/Finder.app" ~/1.1.files
  • installeer 1.1 bestanden
 $ sudo rm -r /System/Library/PrivateFrameworks/BackRow.Framework
 $ sudo rm -r /System/Library/PrivateFrameworks/iPhotoAccess.Framework
 $ sudo rm -r /System/Library/CoreServices/Finder.app
 $ sudo cp -p -r ~/1.1.files/Backrow.Framework /System/Library/PrivateFrameworks
 $ sudo cp -p -r ~/1.1.files/AppleTV.Framework /System/Library/PrivateFrameworks
 $ sudo cp -p -r ~/1.1.files/iPhotoAccess.Framework /System/Library/PrivateFrameworks
 $ sudo cp -p -r ~/1.1.files/Finder.app /System/Library/CoreServices
* reapply ATVfiles pathc op Finder.app
 $ sudo sh ATVFiles-0.5.1.run.sh
* fix sleep probleem
 $ sudo chmod u+s /System/Library/PrivateFrameworks/AppleTV.framework/Resources/SettingsHelper
 $ sudo chown root:wheel /System/Library/PrivateFrameworks/AppleTV.framework/Resources/SettingsHelper
* reboot
 $ sudo reboot

Categories: