 Today we're going to look at the basic setup of getting composite video out from an Arduino with just a couple of resistors and wires. Here you can see I have a very rough setup just using some alligator clips, a wire to ground, and then we have two resistors here, one in pin 9 and one in pin 7. Now the resistors you'll need, you'll need a 1K ohm and a 470 ohm resistor. The 1K ohm goes in pin 9 and the 470 goes in pin 7. You also need yourself a little composite connector also known as RCA connectors. Now you look at mine here and it's white. Now standard yellow is for video and red and white are for the audio channels left and right. But the wires are all the same, the color coding is just for you. I just grabbed one out of a box and it just happened to be white. I snipped off the end here and inside there are two wires. One that is insulated and one that is not. The one that is not is your ground wire, the other one sends the signal. Now this is just the short end because I want a long wire to hook to my Arduino here. Now as I've already stated your 1K resistor goes in pin 9 while your 470 goes inside pin 7. Now make sure they aren't touching on the bottom but after the resistor part twist the wires together and clip an alligator clip to it. Now you also have another jumper wire coming from ground on your Arduino. Now again when you cut open your composite cable you're going to have one that is insulated here. Go ahead and strip that and that's the one you're going to connect to your resistor. So you can see my white line here that went to the resistors and then the other wire is just ground. So just connect those up but make sure that the metal isn't touching here because if you do it's, I did it just to test out, didn't hurt anything but I guess directly it could. It just kind of messes up the picture on the TV. After that that wire runs and plugs into the composite plug on your TV which again will be the yellow plug for video. Now let's look at the software side of things. Okay so the original library from this came from elsewhere. There's many forks of it out there and of course I made my own basically just because I've written some other scripts and examples to go with it and I want to make this setup easy for you guys. So go to github.com forward slash mellx1000 and go to my repositories and look for what it says Arduino TV out and there you can choose to clone it or download the zip file. So I'm going to choose download the zip file here just to make it easy for you people who aren't familiar with it. If you're familiar with it you can just use git. So now I'm just going to download that zip file and then I'm going to unzip it and move into the directory that it was in. So there you have my examples, the library as well as the library for fonts and scripts which we'll talk about more in a future video. Scripts is a script that I wrote that will help generate images for the output so you can take a PNG and turn it into binary basically for this project. So now let me go ahead and start up Arduino interface, the Arduino IDE. I have a fresh install here so you can see it's a fresh install and if we go here to examples we're not going to have the IMG to TV that I created because we haven't installed it yet. Go ahead and close Arduino interface and basically there's an install script and if you look in here it's very basic straight forward it just copies libraries to your home folder under Arduino. So all I have to do is do dot slash install from the repository we just downloaded that I created and that's it. Now when we start up Arduino and we go file examples there is going to be a IMG to TV with some examples here. So the demos and the serial term are ones from the original library that I pulled from and then the NTSC, IMG and the IT, NTSC, NTSC, Punisher, Skull one are examples that I made. So let's go ahead first things first since this is a fresh install I want to make sure I check the right board. I have an older board so pick whatever board is yours. Make sure that I have the proper port checked and then at this point I can go examples and I can open up for example the NTSC IMG which by default is an image of Tux to Pay one that I've created or I didn't create the original IMG but I converted it over to binary using my script. So my Arduino is hooked up I'm going to go ahead and click to compile that and upload it. Now let's go ahead and see what that looks like on the TV. So there we go once it's done uploading and the Arduino starts up it displays the image of Tux then it animates it in it will display some text saying Tux the Penguin exclamation mark, exclamation mark show the picture of Tux again and then we'll end with a basic side scrolling of the image here after a couple of seconds. There we go. There is other example code in there as I stated one that shows a little more of what this can do that I didn't create that's from the original library I pulled from. So the other code if I go to file examples down to IMG2TV and I choose the demo here it shows a bit more. So it's got a couple of files here it's got two images that have been converted into a hex code in this particular example their logo and the schematics for setting this up and also give some other examples as far as drawing lines circles other shapes as well as a 3D cube so let's go ahead compile and upload that I got an error here oh that's because I need to fix this hopefully I need to fix that hopefully you need to do that when you download the code that's a little bug that I meant to push so go ahead and run that you do get a couple of warnings here but it continues compiling no problem so let's go ahead and have a look at that. So it's an uploading and the Arduino starts up it gives their logo that scrolls down and it's just gonna go through some of the things it can do it can do a text obviously and then here's the schematic of how you set it up which I already explained earlier in this video with the two resistors and the ground wire now I think they're going to go into some basic shape or the thing they're gonna show some text yeah so you can different size text different fonts and drawn basic shapes like circles and squares rectangles drawing lines and then it's going to go into a loop of a 3D cube which is pretty cool so that that's a lot of stuff it can do right there with two wires a ground wire and a signal wire now you might ask what are the two resistors doing I really don't know obviously they're sending a signal out what I think is happening I think that pin 7 is sending the image while pin 9 is sending how to sync it up to the screen because if you unplug pin 9 and leave pin 7 in you can see the image but it's not aligned properly for people who are older like me might remember having TVs where they had the knobs in the back to adjust the image and if not it kind of went side to side I think that this is the automatic part of that so I'm going to pull out pin 9 and you'll see what happens here on the screen so here we go we have a demo going and I'm going to unplug pin 9 oops I unplugged both of them let me get the other one back in there real quick so pin 7 so you can see it's the calibration for aligning the image and if I plug pin 9 back in the resistor back in it lines things up and if I unplug 7 and leave 9 plugged in we don't get any image and if I plug both back in and I unplug the ground we can kind of see the image that may not be good to do so I'm gonna plug that back in so definitely it seems like pin 7 is the image pin 9 is for aligning the image and just in case you're curious I'm just guessing by testing it out like that so at the time of recording this there are three demos from the original library pulled really two because two of them are the same just ones for NTSC and ones for PAL and right now my example codes are for NTSC since I'm in the U.S. and there's two that I have created but I'm going to be putting more in there and in coming videos I'm going to show you about how my scripts works and how to customize images using my script and again well I'll get more at that in the next videos but let's look at the one other example I created I'm a big Punisher fan from the comic books Marvel Comics so I did a little demo with the Punisher Skull logo now I also want to mention and I'll talk about this more in the future videos is right now the current resolution of this is 124 pixels by 96 pixels so very low resolution stuff but you can still do some neat stuff so but let's look at that or the demo I made right now so there we go we have got the traditional Punisher Skull and then we also have the more modern Punisher Skull that will be scrolling across the screen here in a moment so yeah that's one of the demos I made so that's just a quick look at that very easy very basic setup again my code is up on github hopefully I remember to link it in the description if not let me know when I'll put a link there if not you know it's github.com you can find that link on my website filmsbychrist.com that's Chris the K I'm going to do a few more videos on this particular topic again showing a script I made that will convert images to the necessary binary format needed for this so you can take very simple black and white like not grayscale but black and white a one-bit images that are low resolution and convert them into the format needed for this project that's about it I hope that you enjoyed this tutorial if you liked it be sure to like subscribe comment share all that good stuff if you like my videos in general think about becoming a supporter over at patreon.com forward slash metal x1000 there should be a link in the description as always I I thank you for any support I thank you for watching and I hope that you have a great day