Difference between revisions of "Composite"

From AwkwardTV
Jump to: navigation, search
m (Activating color composite output by software)
(Autostart using an Application Menu Plugin: reworded the create color.sh section to make more sense..)
Line 36: Line 36:
  
 
NOTE: Enabling TVComposite.kext via rc.local does not seem to work. Here is '''d_ced''''s solution using [[Applications Menu]] Plugin:
 
NOTE: Enabling TVComposite.kext via rc.local does not seem to work. Here is '''d_ced''''s solution using [[Applications Menu]] Plugin:
Create the following color.sh, and save it as /Users/frontrow/Documents/color.sh
+
Create a file called color.sh and put the 2 lines of code below in it, and save it as /Users/frontrow/Documents/color.sh
  
 
  #!/bin/sh
 
  #!/bin/sh
Line 67: Line 67:
 
  </dict>
 
  </dict>
 
  </plist>
 
  </plist>
 
  
 
== Alternatively using a StartupItem ==
 
== Alternatively using a StartupItem ==

Revision as of 17:49, 9 April 2008

If you have a standard definition TV with a composite input, you CAN use the Apple TV, but only in black and white. Just simply connect a cable from the green (luma) component output to your yellow composite input and select 480i as the resolution for NTSC or 576i for PAL (or else it will flicker).

I mention this only for those folks (like me) who are waiting to receive their big beautiful flat-screen TV, but can't wait to try out their new Apple TV. Just recognize that this is not a long term solution - who wants to see their iPhoto collection in black and white? --A colorblind person you insensitive clod!  ;-)

It's also worth to note that there's another option to enable full color output from composite that doesn't require code, just some basic adapters (from Mauricio Pastrana, found by mistake but it works), here's the youtube video outlining the procedure: http://www.youtube.com/watch?v=eQNFCjKrVlc, and here's the TUAW entry, check the comments for photos and whatnot.

Sources: http://www.beutelevision.com/blog/apple-tv-on-sdtv-in.html, http://www.appletvhacks.net/?p=125


Activating color composite output by software

This method was orginally posted by loop in Awkwardtv Forum


1. Download tvcomposite_pal.tar .

2. Extract TVComposite.kext to your Apple TV (inside /Users/frontrow/)

sudo mount -uw /
sudo chmod -R 755 TVComposite.kext
sudo chown -R root:wheel TVComposite.kext
sudo mv TVComposite.kext /System/Library/Extensions/TVComposite.kext

3. If your TV is NTSC (US, 480i) download tvcomposite_ntsc.tar extract it and copy the TVComposite file over the one included in the pal version (under TVComposite.kext/Contents/MacOS)

4. Follow turbo kext enabler instructions (http://0xfeedbeef.com/appletv/), OR (easier) use NitoTV to enable kext loading

5. Set ATV to 480i (NTSC) or 576i (PAL)

6. Reboot ATV

sudo reboot

Autostart using an Application Menu Plugin

NOTE: Enabling TVComposite.kext via rc.local does not seem to work. Here is d_ced's solution using Applications Menu Plugin: Create a file called color.sh and put the 2 lines of code below in it, and save it as /Users/frontrow/Documents/color.sh

#!/bin/sh
echo "frontrow" | sudo /sbin/kextload -v /System/Library/Extensions/TVComposite.kext

Add an Application Menu Plugin item to /Users/frontrow/Documents/Applist.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Applications</key>
  <dict>
    <key>0</key>
    <dict>
      <key>args</key>
      <string></string>
      <key>remotewatcher</key>
      <true/>
      <key>fireandforget</key>
      <false/>
      <key>menu</key>
      <string>Color</string>
      <key>killfinder</key>
      <false/>
      <key>path</key>
      <string>/Users/frontrow/Documents/color.sh</string>
    </dict>
  </dict>
</dict>
</plist>

Alternatively using a StartupItem

(sudo password is "frontrow"):

sudo mkdir /System/Library/StartupItems/ATV_Color

Create a file called ATV_Color in /System/Library/StartupItems/ATV_Color:

sudo nano -w /System/Library/StartupItems/ATV_Color/ATV_Color

Enter the following lines:

#!/bin/sh
. /etc/rc.common
/Users/frontrow/turbo_kext_enabler.bin
kextload /System/Library/Extensions/TVComposite.kext

Make it executable:

sudo chmod +x /System/Library/StartupItems/ATV_Color/ATV_Color

Create a StartupParameters.plist:

sudo nano -w /System/Library/StartupItems/ATV_Color/StartupParameters.plist

Enter the following contents:

{
  Description     = "Load Composite Kext";
  Provides        = ("Composite");
  OrderPreference = "First";
}

That's it.

Adjusting to SDTV 4:3 Aspect Ratio

You can adjust the Apple TV to your screen's aspect ratio using displayutil by Jonathan Bringhurst. You can download displayutil from http://www.codecrazy.net/topic/software.

The following command will set up 640×480 SDTV resolution (NTSC). You can replace "640x480" with your screen's resolution (e.g. 800x600 which is close to PAL, 768x576 would be the correct PAL values, but don't work for everybody).

kill `ps awx | grep [F]inder | awk '{print $1}'`; sleep 1; ./displayutil -r640x480 -b32
Note: If you get a syntax error form aux you probably typed a
 ' 
instead of

Note: If you used displayutil (and restarted Finder), your color will be black/white again. You can reload the TVComposite.kext in this case:

sudo kextunload /System/Library/Extensions/TVComposite.kext
sudo kextload /System/Library/Extensions/TVComposite.kext

This solution was originally posted at AppleTVhacks.net

Startup Screen Resolution Changer

The above screen changing script will not work on its own from init scripts.

Here is rst's solution for a StartupItem (install to /System/Library/StartupItems) using a perl based screen resolution changer which uses displayutil. Download it from screenrestar.gz

There are three things to notice:

1) It's a .tar.gz file, not a .gz file, so extract it with the following command

tar -xzf screenrestar.gz

If you want to do that on Apple TV, you have to copy gzip to it.

2) You have to setup correct permissions on files and folder using sudo chown root:wheel

3) Appletv has a watchdog, which restarts Finder when Finder crashes. But if finder crashes TOO quickly (faster than 1 second), it won't start it again. So, if you don't see any UI but apple on the screen, after applying this patch, change delay to something like a 1-2 seconds between calls of killfinder in the ResolutionChanger script.

Note: Not sure if you need such a startup script at all, because Apple TV remembers your resolution set by displayutil after a reboot. See Talk:Composite for a discussion.

You may also want to disable watchdog