Page 1 of 1

Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 2:45 am
by phaze3131
Hey guys, I have a 12v cord I need to use to power a stepper motor driver that has male headers.

What is the best way I should do this? thanks for the help!

Here is the cord and motor driver with male pins: https://www.dropbox.com/s/8nb5sm9ofiodn ... 6.jpg?dl=0

Re: Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 4:52 am
by W. H. Heydt
Number one...do *not* connect it directly to the Pi. It will let all the magic smoke out.

Be sure you have good isolation between the 12v supply and the Pi. Read up on "optoisolators".

Re: Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 9:49 am
by davidcoton
Assuming you are obeying Rule 1 above, you then have a choice. :o

Either get the correct female part to fit the pins, and crimp or solder your cord to its contacts (follow manufacturer's instructions). 8-)
Or remove the header, solder wires directly to the board, or fit a connector of your choice (chosen with voltage and current in mind). :cry:

May I offer Rule 2: Observe the polarity of the supply to the board. Getting it wrong will let the magic smoke out of the stepper motor driver. Get that wrong and connect the driver board to your Pi: refer to Rule 1. :roll:

Re: Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 10:44 am
by Burngate
While observing Rules One & Two, Google crimp connectors. Farnell sell Molex 43030-0007 at 25p, though they may not be the correct size for you

Re: Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 4:37 pm
by phaze3131
wow thanks so much for all the replies.

Yes for sure the 12v power is going into my stepper motor driver (sainsmart tb6560) and not into my nema 12 stepper motor.

Turns out the connections are 5mm terminal blocks.

so I could do this with a solid core wire:
https://www.dropbox.com/s/oacovqnunxhtp ... 3.jpg?dl=0

or should I use 18 gauge stranded wire I have here and run that to the 5mm terminal blocks.

but then I'd need to convert the 18 gauge wire to the connection type of my motor, which is a female solid .1" connection type:
https://www.dropbox.com/s/6rkwcx0nwt0d1 ... 8.jpg?dl=0

what is the best way to go from 18 gauge stranded wire to the thin solid core wire for use on breadboards and such?

I read alot on crimping and what type of ends I can crimp onto an 18 gauge wire, but didn't see anything for a conversion to .1" bredboard wire.

Thanks so much!

Re: Connect Power Cord to Male Headers?

Posted: Thu Jan 21, 2016 9:11 pm
by davidcoton
If I've understood it correctly, and if the motor wires are long enough, I would cut the existing connector off the motor, and screw the motor wire into the terminal for the controller. Don't try just poking wired into the female terminals, except for testing.

Solid wire is good for short, fixed connections that do not move. If a wire is flexed regularly (or on a longer run) you should use stranded wire of an appropriate gauge, considering current and length. 18 gauge is a good general purpose size.