go_away

Author Topic: MOSFET Problems :(  (Read 2605 times)

0 Members and 1 Guest are viewing this topic.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
MOSFET Problems :(
« on: July 29, 2010, 05:56:38 AM »
Hey guys, this is my first ever post (and my first robot) and I'm hoping you can help me out a little:

Okay, the problem I'm having seems really simple to be but it's frustrating the hell out of me.  I've directly connected a MOSFET to the PIC.  The PIC connected to the middle leg.  I've then connected the positive side of the battery to one leg and the motor to the other.  I've then connected the other side of the motor to ground.

The problem is it doesn't work :(  BUT, the most infuriating thing is that when I connect the positive battery terminal to the middle leg of the MOSFET it works perfectly.  The battery supplies 6V and my PIC supplies 5V so I don't think that can be the problem, perhaps it is because the battery supplies more current?  To be honest I don't know.  I was thinking about using the PIC to connect the MOFET to the positive battery terminal via a transistor...  But I don't really know if that would work.

Thanks for reading and thanks to any responses. :)

EDIT: I'd also love to know what software you use to draw the circuit diagrams please. :)

Offline random robots

  • Full Member
  • ***
  • Posts: 108
  • Helpful? 3
  • he drives worse than my robot... thats sad
    • youtube channel
Re: MOSFET Problems :(
« Reply #1 on: July 29, 2010, 06:02:18 AM »
take voltage and current readings from the pic if you haven't already. The problem may be the pic supplies too little voltage/current to the mosfet.

Hope this helps,
Patrick
this is a signature.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #2 on: July 29, 2010, 06:30:18 AM »
Alas, I missed the obvious the first 100 times round.  My PIC supplies only 1.3V so that is undoubtedly why!  I'm going to attempt to fix that.  I'd still be interested in the software used to make the circuit diagrams.

Offline dunk

  • Expert Roboticist
  • Supreme Robot
  • *****
  • Posts: 1,086
  • Helpful? 21
    • dunk's robot
Re: MOSFET Problems :(
« Reply #3 on: July 29, 2010, 06:57:49 AM »
Alas, I missed the obvious the first 100 times round.  My PIC supplies only 1.3V so that is undoubtedly why!  I'm going to attempt to fix that.
if you are running your PIC at 5V and it is outputting only 1.3V for logic hight then there is something wrong.

first check the voltage on the VCC pin of the PIC when it is outputting 1.3V. if VCC is also low then you have a power supply problem.

does the PIC give only 1.3V when there is nothing connected to that pin?
if it gives 5V with nothing connected and only 1.3V when you connect your MOSFET then the MOSFET is drawing too much current.
compare the maximum current output figure on the PIC datasheet to the gate current draw on the MOSFET datasheet.


I'd still be interested in the software used to make the circuit diagrams.
most hobbiests use Eagle PCB from Cadsoft. http://www.cadsoftusa.com/
they do a free evaluation version.

the user interface is a little eccentric until you get used to it but it is good once you get the hang of it.


dunk.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #4 on: July 29, 2010, 07:44:01 AM »
Alas it appears my PIC is toast :( 

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: MOSFET Problems :(
« Reply #5 on: July 29, 2010, 07:48:28 AM »
Get the MOSFET/motor/battery working BEFORE connecting the PIC. The PIC will just add a complication while learning how to use a MOSFET and at the worse kill the PIC.

Which MOSFET are you using, link to data sheet please. The center pin of many MOSFETs is the Drain not the Gate so I believe you may not have the MOSFET connected properly but can only guess without seeing the data sheet.

Can you post a schematic of how you're connecting everything (does need to be pretty, a quick sketch in Paint will work).

Offline amando96

  • Robot Overlord
  • ****
  • Posts: 187
  • Helpful? 1
Re: MOSFET Problems :(
« Reply #6 on: July 29, 2010, 07:57:35 AM »
I thought MOSFETS where supposed to provide GND for the motor, and the other motor pin went to 6v, that's how I was switching 900v on and off with my coil gun, and also add a flyback diode when using inductive loads.
Rorcle, 60% complete
AATV, 5% complete

Offline Razor Concepts

  • Supreme Robot
  • *****
  • Posts: 1,856
  • Helpful? 53
    • RazorConcepts
Re: MOSFET Problems :(
« Reply #7 on: July 29, 2010, 07:59:50 AM »
I thought MOSFETS where supposed to provide GND for the motor, and the other motor pin went to 6v, that's how I was switching 900v on and off with my coil gun, and also add a flyback diode when using inductive loads.

It works either way, sinking or sourcing current

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: MOSFET Problems :(
« Reply #8 on: July 29, 2010, 08:42:12 AM »
Yep, a MOSFET can be wired either way.
But the OP never told us which MOSFET he is using so we don't know if its an N-ch a P-ch or the pin out.
Therefore I can't see how anyone can give advise on the PIC connections without this vital information.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #9 on: July 29, 2010, 09:09:27 AM »
Right back, sorry for the wait.  This is what I'm going for ATM.

The datasheet of the only mosfet I had wired up was this one:

http://www.fairchildsemi.com/ds/MJ%2FMJE200.pdf

It was simply wired to turn the motor forward.  I'll post what I was using next.

Image quality- Don't even ask. xD

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #10 on: July 29, 2010, 09:16:21 AM »
I can't find the symbol for a motor hence the gap left.  The motor in the one before go where expected in a H bridge. 

Thanks for all the comments so far.

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: MOSFET Problems :(
« Reply #11 on: July 29, 2010, 09:48:02 AM »
That data sheet is an NPN BiPolar transistor and not a MOSFET. Is that really the part you have?
They can be used in a similar manner but are wired very differently so I have no doubt that you killed the port pin of the PIC. Most likely only the one pin is dead so for experimentation you may be able to use a different pin but you do need to properly wire the transistor and get it working first.

The first schematic you posted is an H-bridge but the second is just a switch. I assume its the second schematic you tried to wire. The IRFD9210 is a P-ch MOSFET. The schematic is almost correct but probably won't work as drawn. Do more reading on using MOSFETs as switches. There are many threads here on this subject so SoR is a good place to start.

The NPN transistor can be made to switch the motor from the PIC. Also go read on doing this.

I also hope you have by-pass caps on the regulator output and on the PIC's Vdd to Vss pins. And 47 Ohms seems to be a good bit too lower a resistor value for the LED. If the LED is Red or Green then that would set the LED current to about 75mA. Is this correct?

Schematic hint: You could use a resistor symbol for a motor on the schematic and then just label it 'motor'. Or just put the word "MOTOR" between the wire ends to indicate these connect to a motor. A schematic is just a symbolic representation of a circuit.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #12 on: July 29, 2010, 09:56:13 AM »
Sorry, the labels on the schematics are incorrect.  They are just the symbols that stand.  The transistor show is the NPN BiPolar transistor.

Offline Terrible TomTopic starter

  • Jr. Member
  • **
  • Posts: 7
  • Helpful? 0
Re: MOSFET Problems :(
« Reply #13 on: July 29, 2010, 10:06:30 AM »
Thanks for all the replies, I think it's evident that I should go away and learn some more so as not to waste any more of your time.  Thanks VERY much.  I'll be back!

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: MOSFET Problems :(
« Reply #14 on: July 29, 2010, 10:30:48 AM »
Please just don't go away but do read more and ask clear questions.

I am still very confused as to what part you have an NPN or a MOSFET. Without knowing exactly what part you are using I, or any one else, can't really help. You linked to a DS for an NPN but have a P-ch MOSFET in your schematic. If you do have an NPN transistor then please put that in the schematic. Incorrect symbols don't help us help you get this circuit to work.

Here is a link on using an NPN as a switch:
http://www.kpsec.freeuk.com/trancirc.htm

That web site is has pretty good basics and should help get you going.
Then use a breadboard to wire and experiment with circuits until you understand them and they work.
Ask here if you don't understand something.

Cheers

Offline futmacl

  • Full Member
  • ***
  • Posts: 55
  • Helpful? 1
    • Guerrilla guide to CNC robotics
Re: MOSFET Problems :(
« Reply #15 on: July 29, 2010, 11:02:06 AM »
Okay, the problem I'm having seems really simple to be but it's frustrating the hell out of me.  I've directly connected a MOSFET to the PIC.  The PIC connected to the middle leg.  I've then connected the positive side of the battery to one leg and the motor to the other.  I've then connected the other side of the motor to ground.

The problem is it doesn't work :(

Uh, do you have a datasheet for this MOSFET? Many MOSFETs have gate connected to the first (leftmost) leg, like this:

http://transistor-man.com/images/mosfet1.gif

(Oh wait, never mind, just read the remainder of the thread)
« Last Edit: July 29, 2010, 11:03:24 AM by futmacl »

Offline galannthegreat

  • Supreme Robot
  • *****
  • Posts: 615
  • Helpful? 4
  • Blue-Lensed Blue LEDs?! What?! Impossible!!
Re: MOSFET Problems :(
« Reply #16 on: August 02, 2010, 08:20:04 PM »
Your FET can also be toast, they are extremely static sensitive. Make sure you handle them in a static safe environment, wear anti-static wrist strap if possible and make sure you've wired it correctly in that schematic, cause that can also destroy them.
Kurt

 


Get Your Ad Here