Arduino DIY Composite TV output Shield

Shields are boards that can be plugged on top of the Arduino PCB extending its capabilities. The Arduino is also capable of sending out a video stream to your TV over a yellow component cable. So here is how i made my own Composite video-out for Arduino under 15 minutes.

Requirements
HARDWARE
– a PCB or Prototype Board
– Resistors (470- and 1K-ohm)
– 8-Pin headers (or at least 3-Pin headers)
– a Spare RCA cord (any RCA is ok, you can use the red/white audio cables aswell)
– a Soldering Iron + Tin
– Box cutter and a small saw

SOFTWARE
– Arduino Software ( http://arduino.cc/en/Main/Software )
– The TVout library ( http://code.google.com/p/arduino-tvout/ )

OPTIONAL:
– Glue Gun

Creating the shield
First cut a piece of prototype board to the size we need.(at least) (8 x 9 holes)

arduinodiyprototypeboard

Now get your 8-Pin headers, we will only use 3 for output but i’m using 8 for extra stability.

arduinodiylegs

Get your resistors and wire them in the prototype board:

arduinodiyresistors

Cut off a piece of composite video cable and gently strip it and twist the “shielding” wire. Now strip a shorter part of the center of the cable but make sure it will never touch the outer shielding wire!

arduinodiycompositecable

Your almost done, plug in your soldering iron and start making the connections Like the picture below :
arduinodiycompositecabletop

arduinodiycompositecableback

TVout Library

– Arduino Software ( http://arduino.cc/en/Main/Software )
– The TVout library ( http://code.google.com/p/arduino-tvout/ )

Download and Install the Arduino software. The setup will ask you (too) many times if you really want to install a driver,  keep clicking “install this driver anyway.

arduino_setup

Then download the latest version of the TVout library(Beta1 at the time or writing). The zip will contain 3 folders. these folders go in the “libraries” folder in your Arduino installation folder (default : c:\Program Files (x86)\Arduino\libraries)

arduino_libraries

Example Code

Here is basic code that puts out “stevenbreuls.com!!!” to your TV. If your TV is PAL, uncomment the “PAL” line and comment the NTSC line.

#include 
TVout TV;
unsigned char x,y;

void setup()  {
  //TV.start_render(_PAL);
  TV.start_render(_NTSC);
}

void loop() {
  TV.clear_screen();
  TV.print_str(10,40,"Stevenbreuls.com!!!");
  TV.delay(60);
}

Currently the output is NTSC or PAL at a resolution of 128×96 by default. The library currently works on ATmega168,328,1280,2560,644p,1284p,AT90USB1286 and more can be added by editing one file.

IMG_1008

Leave a Reply