Go to Post The teams who have the best chance at success are the ones who know where they can save time and money on machining by using or using part of some premade equivalent. - Bill Gold [more]
Home
Go Back   Chief Delphi > Technical > Electrical
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 14-07-2007, 21:45
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
LMD18201

Here is the datasheet on this H-Bridge controller.

http://www.national.com/ds/LM/LMD18201.pdf

According the the logic truth table and the test circuit diagram. Does "sink" mean that it is connected to +v and "source" mean that it is connected to Ground?
  #2   Spotlight this post!  
Unread 14-07-2007, 22:15
ebarker's Avatar
ebarker ebarker is offline
Registered User
AKA: Ed Barker
FRC #1311 (Kell Robotics)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Kennesaw GA
Posts: 1,437
ebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond repute
Re: LMD18201

Look at figure 8. That is basically the way you hook it up.

source, sink notation - Source is where the current comes from, like the source of a river. Sink is where the "used up" current goes after it passed through the load.

But an H-Bridge can swap source and sink around, hence the notation in figures 7 and 8 as out1 and out2.

If you were playing with a battery with a light bulb across it, in EE network theory if you were to say the current is +3 amps, the current flow is from plus to negative. If you were to say it is -3 amps, the current flow is from negative to plus.

Back in the days of Benjamin Franklin when they were coming up with the ideas about current flow, it was theorized that current went from plus to minus (anode to cathod). He had a 50/50 guess, and guessed wrong.

Physically, the electron flow really goes from negative to positive. Backwards from the way a network theorist represents it.

But all that is getting a little off topic but I though it would be neat to have the history lesson.

Just view it as a network theorist. Source provides current, sink sends it away, and an H-Bridge can swap source and sink around. See figure 7, 8.

Ed
  #3   Spotlight this post!  
Unread 15-07-2007, 02:25
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Re: LMD18201

Thanks, that helped alot =D

Now, according to the datasheet, pin 8(signal ground) is connected to ground? If I were to use the Robot controller as my PWM generator. the Signal Ground pin needs to be grounded to the MCU?

I wonder if the outputs(source & sink) pulses.... or is it continous current flow.
  #4   Spotlight this post!  
Unread 15-07-2007, 10:25
ebarker's Avatar
ebarker ebarker is offline
Registered User
AKA: Ed Barker
FRC #1311 (Kell Robotics)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Kennesaw GA
Posts: 1,437
ebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond repute
Re: LMD18201

Pins 7 and 8 you should ground. If you had a long cable run from controller to the motor then you could use the current sense but you should be able to safely ignore that for now. Just ground 7 and 8.

Yes I think that the outputs will be pulsing. They will pulse alternating between the configuration needed and open circuit.


But here is where it gets wierd. 'Classical' PWM in the rest of the EE world generally means a signal with some duty cycle, between 0 and 100%.

RC PWM is a little different. It is a 2ms period wave that has an on time of 1 to 2 ms. 1.5ms is neutral or centered and correlates to digital PWM value of 127 in an Robot Controller.

I googled around and found this. You may find it interesting.

http://homepages.which.net/~paul.hil...eedAndDir.html

http://homepages.which.net/~paul.hills/

I need to put this on a scope sometime and play with it. Playing with signals really helps reinforce these concepts. Offhand it looks like that there may need to be a translation between RC PWM and what you need. I may get a chance to do that this week. We have had 2 robots out for weeks on display and teaching and are just getting them back.

BTW, A Victor has circuits added to greatly beef up the current handling capability.

This is a great exercise for students to go through. It really gives you an appreciation for why commercial items cost what they do.

Ed

Last edited by ebarker : 15-07-2007 at 10:30.
  #5   Spotlight this post!  
Unread 15-07-2007, 10:44
Gdeaver Gdeaver is offline
Registered User
FRC #1640
Team Role: Mentor
 
Join Date: Mar 2004
Rookie Year: 2001
Location: West Chester, Pa.
Posts: 1,365
Gdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond repute
Re: LMD18201

When connecting the motor controler to a the micro outputs it can be a good idea to put some 10k resistors in line to protect against several failure modes. You'll have to set up the hardware regesters on the robot controler to generate a duty cycle PWM output.
  #6   Spotlight this post!  
Unread 15-07-2007, 16:57
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Re: LMD18201

Quote:
Originally Posted by Gdeaver View Post
When connecting the motor controler to a the micro outputs it can be a good idea to put some 10k resistors in line to protect against several failure modes. You'll have to set up the hardware regesters on the robot controler to generate a duty cycle PWM output.
10k to shut off the motor controller?
  #7   Spotlight this post!  
Unread 15-07-2007, 17:17
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Re: LMD18201

I just noticed something.....

If I had the Direction Pin(3) hooked up the the PWM signal, and have the PWM Pin(5) hooked onto logic high, this way I use only PWM for direction and magnitude control. according to the Logic chart, I would be switching from (Source 1, Sink 2) to (Sink1 , Source 2) back and forth. Isn't that bad for the motor controller? I would be switching high currents at high frequencies....
  #8   Spotlight this post!  
Unread 15-07-2007, 19:09
ebarker's Avatar
ebarker ebarker is offline
Registered User
AKA: Ed Barker
FRC #1311 (Kell Robotics)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Kennesaw GA
Posts: 1,437
ebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond reputeebarker has a reputation beyond repute
Re: LMD18201

The 10k resistors between the micro and the controller is not a problem. The input impedance of the controller is very high, therefore the nominal current through the resistor is negligible, therefore the nominal voltage drop across the resistor is negligible.

Any spikes/transients are essentially isolated by the 10k resistor. The is very much desired in order to protect the micro.

High frequencies and high currents are basically relative matters.

As for the switching waveforms I think (I'll investigate more) that is essentially correct.

Ed
  #9   Spotlight this post!  
Unread 16-07-2007, 02:31
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Re: LMD18201

http://www.centralsemi.com/pdf/cclm0035-5750.pdf

Above is the link to the datasheet of a CLD (Current limiting diode)

Does the REGULATOR(1) DYNAMIC KNEE LIMITING TEMPERATURE
CURRENT represent the output current? what about the input current? or ddoes that matter? Is there no restriction on the Input current? The data sheet doesnt say much about it.
  #10   Spotlight this post!  
Unread 16-07-2007, 13:34
Unsung FIRST Hero
Al Skierkiewicz Al Skierkiewicz is offline
Broadcast Eng/Chief Robot Inspector
AKA: Big Al WFFA 2005
FRC #0111 (WildStang)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1996
Location: Wheeling, IL
Posts: 10,785
Al Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond repute
Re: LMD18201

OK,
Reading the datasheet, there are two ways to control this device depending on the input PWM signal. If the PWM is direction encoded where a 50% duty cycle represents zero speed then you tie the speed PWM pin to logic high and use the direction PWM for your input. (see the applications section of the data sheet.) The Source 1 & 2 and Sink 1 & 2 refer to the output pairs. Note in the block diagram that the left output pair is labeled Out 1 and the right is labeled Out 2. Now if you look at the truth table, the "Active Output Drivers" refer to which FET in which output is conducting. "Source 1" referes to the upper transistor in the left side of the block diagram and "Sink 2" refers to the lower transistor in the right side of the block. "Source" generally means a connection to the positive power while "sink" refers to a connection to ground. Again in the applications section, the manufacturer refers to Pin 7 and "ground/sense" so that a user may insert a 0.1 ohm resistor at this pin and measure a voltage that is ground referenced and proportional to the current flowing through this resistor. In addition to normal speed control, this device also allows braking but in addition to turning on both "sink" transistors ( a normal way to brake), it allows a state where both "source" transistors can be turned on instead. This would allow some applications that may not be motor control. Since a motor is connected across the two outputs, the motor will turn in one direction when sink 1 and source 2 are turned on. It will reverse direction when the sink 2 and source 1 are turned on and it will brake when either the two source or two sink transistors are turned on. You need to look closely at the PWM data in this sheet to determine whether it meets your ability to generate a readable encoded PWM signal. Please note that even small motors have a very large start current. A motor that is not moving is by definition in stall and will draw stall current when starting. Even the little Johnson motors can draw 20-30 amps when starting, albeit for a very short time.
__________________
Good Luck All. Learn something new, everyday!
Al
WB9UVJ
www.wildstang.org
________________________
Storming the Tower since 1996.
  #11   Spotlight this post!  
Unread 18-07-2007, 00:25
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Question Re: LMD18201

cool, So far I've designed everything onto the ExpressPCB program. Now comes the issue with current regulation on the LMD18201. I looked into Current Limiting Diodes for current regulation of about 13mA for the LMD18201, but the data sheets on the CLDs don't say what the limit input current is. That worries me because I don't know if thats even relevant. Are there other ways to supply low currents? I can't exceed 15mA because that could cause damage to the Chip.
  #12   Spotlight this post!  
Unread 18-07-2007, 07:38
Unsung FIRST Hero
Al Skierkiewicz Al Skierkiewicz is offline
Broadcast Eng/Chief Robot Inspector
AKA: Big Al WFFA 2005
FRC #0111 (WildStang)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1996
Location: Wheeling, IL
Posts: 10,785
Al Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond repute
Re: LMD18201

Quote:
Originally Posted by Generalx5 View Post
I can't exceed 15mA because that could cause damage to the Chip.
?????
The chip is rated for an output of 3 amps continuous and 6 amps peak. You should only have to fuse/breaker this for 6 amps to protect the circuitry.
__________________
Good Luck All. Learn something new, everyday!
Al
WB9UVJ
www.wildstang.org
________________________
Storming the Tower since 1996.
  #13   Spotlight this post!  
Unread 18-07-2007, 08:13
Gdeaver Gdeaver is offline
Registered User
FRC #1640
Team Role: Mentor
 
Join Date: Mar 2004
Rookie Year: 2001
Location: West Chester, Pa.
Posts: 1,365
Gdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond reputeGdeaver has a reputation beyond repute
Re: LMD18201

There is another chip that is popular for small brushed DC motors, the TI SN754410. Here is an app note that may help.http://kronosrobotics.com/an101/DAN101.shtml
And
http://kronosrobotics.com/an101/AAN101.shtml
The big mother of integrated motor controlers is the ST MIcro VNH2SP30-E. Here is the data sheet.
http://www.st.com/stonline/products/...2/vnh2sp30.pdf
This company sells some motor controller board products.
http://www.pololu.com/products/elec.html#motocon
Might help.
  #14   Spotlight this post!  
Unread 18-07-2007, 17:46
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,003
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: LMD18201

Quote:
Originally Posted by Generalx5 View Post
I would be switching from (Source 1, Sink 2) to (Sink1 , Source 2) back and forth. Isn't that bad for the motor controller? I would be switching high currents at high frequencies....
Nope, no problem at all.

At high frequencies (over a few hundred Hz - the 18201 is rated up to a few tens of kHz) the motor sees this as an average voltage, thus effecting motor speed control.

In other words, if you have full forward 75% of the time, and full reverse 25% of the time, the motor is seeing (75 - 25 =) 50% forward. No harm to the motor or the chip.

However, converting R/C PWM to the EE's PWM (which this chip needs), is easy but needs to be done. See Here for one example, or get an NE544N or some other servo amplifier.

Don
__________________

I am N2IRZ - What's your callsign?
  #15   Spotlight this post!  
Unread 19-07-2007, 02:07
Generalx5's Avatar
Generalx5 Generalx5 is offline
Hard Core Inventor
AKA: Jun(John) Zheng
FRC #1346 (Trobotics)
Team Role: Student
 
Join Date: Nov 2005
Rookie Year: 2004
Location: CANADA
Posts: 94
Generalx5 will become famous soon enough
Re: LMD18201

No way! You mean the PWM signals from our robot controllers cant work directly with the LMD18201 chip? The spec sheet on page 6 right under the Logic Truth Table states the types of PWM signals. I am thinking that our robot controller is the Simple, locked anti-Phase PWM type. As apposed to the Sign/magnitude PWM type.

it says that I can attache the PWM pin to logic High, and put in my PWM signal into the Direction pin. this way I only need a single PWM signal to indicate direction and magnitude.

Last edited by Generalx5 : 19-07-2007 at 02:15. Reason: added last line there.
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 06:44.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi