If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content
Current time:0:00Total duration:6:14

Video transcript

in this video we're going to connect the power switch and run the power wires to the L 298 motor controller so we've got our power switch that we made in a previous video and you can see how we have a long wire and a short wire so the wires from the battery we're going to twist together so we have two red wires we're going to twist those together we're wiring the batteries in parallel because we want to keep the voltage the same but increase the amount of time we can run the batteries so we're going to twist those wires together with the short battery wire or the short wire from our from our switch and so we're just twisting those together and once we have them twisted together very tightly we'll take our soldering iron which is already hot and we'll warm the wires up and then put a little bit of solder on them and that will help to make sure that they stay completely together while we're that'll just keep the wires held together ok so then we're going to trim off the the excess there and we're going to use some shrink wrap tubing on this now you may not have a shrink wrap gun in or the shrink wrap tubing so if you don't you can also just use electrical tape and tape it around it the shrink wrap tends to hold a little bit better but it means that you have to have the shrink wrap gun and so it's a little bit more more cumbersome but in any case you can take just black electrical tape and wrap it around and it'll do the same thing so we've got our heat shrink gun and we're shrinking that heat shrink tubing over that and again that's just to basically prevent the bare metal from touching anything else and potentially causing a short or a problem so we want to make sure that all of the exposed wires are covered or connect our connect insulated alright so now we've got our our switch and where we're going to take some hot glue and we're going to put it over all of the contacts on the back of our switch and the main reason for this is that usually the switches on the bottom of the tap light so there's no chance for anything to touch those electrical contacts but because it's not on the bottom of the tap light anymore it can bump up against something that's metallic and that means that the switch could potentially short out and or the electricity could be conducted through a different part of a circuit in a way we don't want and that could cause problems for us so now that that hot glue is dry we have that the back of the switch is protected and insulated by that hot glue so now we can take our long wire from our switch and connect it to our to the port on our terminal block I should say on our motor controller that is meant for the positive wire so what we're going to do is we're going to take the long wire and we're going to put it in on the terminal block that is on the far left hand side so it's really important that it goes on that one now it's also very important this is a little too long so we're just going to trim it down just a little bit there and again it's important that we have just enough wire to make the connection but no extra wire exposed there because we don't want it to again touch another metal piece now it's important that that red wire the long red wire goes to the far left terminal block when it's set up in this orientation it's that's that's where the positive nine volts comes in from the battery okay so now we're gonna make another we're going to take two more wires we got one wire that's about two-and-a-half inches long 3 inches long and one wire that is about five inches long so we're just stripping the ends off of those and again we're trimming our battery wires now and getting those ready to connect together so these are the negative or the ground wires from our battery we want to make sure we pull off the insulation sometimes it can be tricky to get off there these wire strippers work really good for solid core wire but this is a stranded wire from our battery so sometimes it causes the wire to break so you have to be kind of careful there in any case we've got our you know we're gonna take a little bit more expose a little bit more of the wire so it's closer to 3/8 of an inch we're gonna twist those two wires together the the two black wires and those are going to be our negative wires and then we're going to twist those with the two black wires from our battery all right so we have a nice solid connection there and again it's just kind of like what we did with our switch wire and once we have those wires solidly connected together we're going to take our soldering and again we're gonna try and get the the solder to wick through the recently twisted together wires and once the solder flows down all the twisted together wires will have a nice solid connection so we're gonna trim off the edge of that wire okay so once we've got the wire trimmed off we're gonna take our pliers and squeeze the solder and just make sure that it's nice and smooth so that we can get it to fit in the center pin of our terminal block there that's our three pin terminal block in the front and we can get it to fit snugly then we're going to take our screwdriver we're just going to tighten the screwdriver down or tighten that pin down and we'll take the long negative wire and bend it to the back and the short one we're gonna strip off about a quarter of an inch and we can sort of keep that exposed for the front so now what we need is we're going to take our five we're going to take it I'm sorry another wire that's about three inches long this is a red wire and strip off about a quarter of an inch of insulation and we're going to connect it to the terminal block pin on the far right the the three pin terminal block on the far right and that that's going to provide us five volt power for our Arduino so we'll connect that in a second but for now let's connect our we need to connect our header pin jumper wires and so we have four female-to-female header pin jumper wires there's one two three four and we're going to connect those to our header pins on our l2 ninety eight board so I'm just going to slide those down on all four of those header pin ones it doesn't matter which one goes where and once all of those are connected to our four header pins we are going to be ready to connect our Arduino