Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > Electronic Projects Design/Ideas/Reviews


Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution.

Reply
 
LinkBack Thread Tools Display Modes
Old 14th February 2008, 01:48 PM   (permalink)
Default Dual PWM circuit for reversible motor

Alright, so I'm designing my own remote-controlled motorized cable cam (I'm going into videography, but that's a different story...). I need to be able to control the speed AND DIRECTION of two motors (for traveling along the cable and for panning the camera). A circuit like this should suffice, I think. I will split it at the MOSFET. So, the output of U1b would feed to my RF encoder on my "remote control", and the MOSFET would be attached to the output of the decoder on the receiving end. The pulse should actually just transfer right over via RF, (right?) then the MOSFET should amplify it, and drive the motor. I planned on using these ICs for the encoding/decoding.

I don't yet know enough to understand the full theory of this circuit, though I'm sure it's very simple for most of you. So, here's the real question. This circuit uses a variable voltage divider (VR1) to adjust the pulse rates. I basically need TWO copies of this circuit, but controlled by one potentiometer, with a middle deadzone. (I need to be able to reverse the direction of the motor, and I was going to use two separate channels on my RF encoder to specify which direction the motor was actually supposed to run in.) I need to basically "split" the potentiometer. When it's at its mid-point, I want the circuit to be off, and it needs a small deadzone in that area so it doesn't have to be at an EXACT position to be off. When it's turned one way, it should control one of the circuits, varying it from 0% to 100%. When it's turned the OTHER way, it should do the same for the other circuit with the midpoint being 0% for both circuits, and the two endpoints (full resistance and no resistance) being 100%.

So, to clarify, imagine this: The pot starts out in the middle, and the unit is off. I turn the pot clockwise, and the cable cam begins traveling down the cable one way. The more I turn the pot, the faster it travels down the cable. Once the pot is turned to its clockwise limit, the cable cam will be traveling at its max speed. When I turn the pot back counter-clockwise, the cable cam will start to decrease in speed. Once I reach the middle again (remember I need a small "deadzone here), the unit will be off. As I continue rotating counter-clockwise, the other circuit will kick in, sending the pulse to a different input of the RF encoder chip, telling the motor to run in the reverse direction. The more I turn it counter-clockwise, the faster the unit will travel in the opposite direction. At the pot's counter-clockwise limit, the unit will be traveling in the opposite direction as the first time, and at max speed, just like if worked in the other half of the pot.

I REALLY over explained that, I think. I'm sure you guys understood what I needed without that entire previous paragraph, but I just wanted to make sure I was clear. It wouldn't be the first time I tried to explain something to someone that they couldn't understand, but that was obvious in my mind. It's usually due to the way I explain things... I guess.

I'm a programmer before I am an electronic engineer, so it might seem like a simple IF THEN math operation to me at first, but I know it's more complicated with analog hardware. I think the solution is basically just going to end up as a slightly more complicated version of a voltage divider, but I still don't know how to do it. After all, I'm only 17. I haven't gone to college yet, so I haven't properly "learned" how to do any of this stuff. All I know is what I've taught myself, and that hasn't been much since I usually don't have any money to build anything to experiment with. I just know what I've read online.

So, how about it... can someone help me out?
__________________
When life gives you lemons... make a battery.
Electric Rain is offline  
Old 15th February 2008, 11:51 AM   (permalink)
Default

Please...?
__________________
When life gives you lemons... make a battery.
Electric Rain is offline  
Old 15th February 2008, 12:40 PM   (permalink)
Default

Quote:
I'm a programmer before I am an electronic engineer,
I have to admit that I did not read all of your post.

But since you are a programmer use a PIC to drive a dual H-Bridge on a chip. Send commands to the PIC via RF.
3v0 is online now  
Old 15th February 2008, 01:30 PM   (permalink)
Default

I knew I should have specified what I meant by "programmer". I probably should have said I'm a "webmaster" or something like that.

I know Javascript, PHP, MySQL... you know... THAT kind of programming.
__________________
When life gives you lemons... make a battery.
Electric Rain is offline  
Old 15th February 2008, 03:19 PM   (permalink)
Default

Hey Electric Rain, remember me? Its probably been about 3 years.

Do you have any specs on the motor that you are using? (voltage rating/current draw). You could use one of these: http://www.haystack.mit.edu/edu/unde...r/LMD18200.pdf if its 3 amp continuous. If you run it in locked anti-phase PWM mode,(See bottom of page 6) you can just use 1 pwm signal to drive both direction and speed:
A 50% duty cycle will hold the motor still, because it drives the motor both forward and backwards an equal amount of time. If the duty cycle is set at 30%, it will drive it forward 30% of the time and drive it in reverse 70% of the time, so the motor will move backwards.

Another advantage to the LMD18200 is that you can get free samples of them from national semiconductor. http://www.national.com/pf/LM/LMD182...l#Availability

I'm not sure how you would use IR to control it without using a PIC or something. I'd start off by just getting it controlable using wires, then work on getting some sort of remote in the loop.

Hope that helps.
__________________
Jeff
To the optimist, the glass is half full.
To the pessimist, the glass is half empty.
To the engineer, the glass is twice as big as it needs to be.
jrz126 is offline  
Old 15th February 2008, 03:59 PM   (permalink)
Default

Quote:
Originally Posted by Electric Rain
I knew I should have specified what I meant by "programmer". I probably should have said I'm a "webmaster" or something like that.

I know Javascript, PHP, MySQL... you know... THAT kind of programming.
If you can program the script languages it is not a huge step to learn to program a micro controller in C. Think of the things you can do and the fun you can have

Have you ever used the Zend debugger for PHP programming? If you are into serious php work it is great but you need to set it up on your testing server.

jrz126: I am not a great fan of anti-phase PWM especially on battery driven equipment. Regular PWM works and draws no motor current when not moving.
3v0 is online now  
Old 16th February 2008, 12:33 AM   (permalink)
Default

Quote:
Originally Posted by jrz126
Hey Electric Rain, remember me? Its probably been about 3 years.
Yeah, of course I remember you! Sorry, but I haven't had time to frequent these forums anymore... so I obviuosly haven't seen much of you... So... how've you been, anyway?

Quote:
Originally Posted by jrz126
Do you have any specs on the motor that you are using? (voltage rating/current draw).
I don't, as I haven't decided on what motor I'm going to use yet. I have no idea how heavy this is going to be or how much torque will be required to move it up to 20 MPH, which is about what I need, so I have to build the frame and pulley section before I can worry too much about the mechanics. In the mean time, I'm planning out the electronics section.

Quote:
Originally Posted by jrz126
You could use one of these: http://www.haystack.mit.edu/edu/unde...r/LMD18200.pdf if its 3 amp continuous. If you run it in locked anti-phase PWM mode,(See bottom of page 6) you can just use 1 pwm signal to drive both direction and speed:
A 50% duty cycle will hold the motor still, because it drives the motor both forward and backwards an equal amount of time. If the duty cycle is set at 30%, it will drive it forward 30% of the time and drive it in reverse 70% of the time, so the motor will move backwards.

Another advantage to the LMD18200 is that you can get free samples of them from national semiconductor. http://www.national.com/pf/LM/LMD182...l#Availability
Thanks, I'll look into that. I am worried about what 3vo said about battery driven equipment, though. It will be battery driven, so...

Quote:
Originally Posted by jrz126
I'm not sure how you would use IR to control it without using a PIC or something. I'd start off by just getting it controlable using wires, then work on getting some sort of remote in the loop.
Well, like I said, step one is the frame and basic mechanics (the pulleys, basically). Step two is the motor (extended mechanics), and the electronics will come last, but I'm trying to get all the kinks worked out before I start designing it anyway. But, my point is that yes, I will be getting it running without RF controls first. Oh, and remember those encoder/decoder IC's I linked to? That's what I'll be using to get around having to use a PIC.
__________________
When life gives you lemons... make a battery.
Electric Rain is offline  
Old 19th February 2008, 08:55 PM   (permalink)
Default

Quote:
Originally Posted by Electric Rain
Yeah, of course I remember you! Sorry, but I haven't had time to frequent these forums anymore... so I obviuosly haven't seen much of you... So... how've you been, anyway?

I don't, as I haven't decided on what motor I'm going to use yet. I have no idea how heavy this is going to be or how much torque will be required to move it up to 20 MPH, which is about what I need, so I have to build the frame and pulley section before I can worry too much about the mechanics. In the mean time, I'm planning out the electronics section.

Thanks, I'll look into that. I am worried about what 3vo said about battery driven equipment, though. It will be battery driven, so...

Well, like I said, step one is the frame and basic mechanics (the pulleys, basically). Step two is the motor (extended mechanics), and the electronics will come last, but I'm trying to get all the kinks worked out before I start designing it anyway. But, my point is that yes, I will be getting it running without RF controls first. Oh, and remember those encoder/decoder IC's I linked to? That's what I'll be using to get around having to use a PIC.
I'm pretty good. Finished up with college now and working full time. I also got married back in July. (So I have very little free time for electronics )

20MPH is 30 feet/second, which seems to be pretty fast. How long is this track going to be? You'll probably need a pretty big motor to run that, so I dont think those motor drivers that I mentioned will work. You're going to need some pretty big batteries as well. What exactly are you trying to do with it?

You may want to try using a motor and controller from a treadmill. Most of the motor driving circuitry is already built, but it might not have reverse now that i think about it. A pre-built H-bridge is definitly the way to go though. I spent about a week and a half working out the bugs in a H-bridge that I built to drive a motor for an inverted pendulum for a school project. Here's the breadboard when I was finished: http://www.personal.psu.edu/jrz126/i...al_circuit.JPG
Here's a pic after i had a few mosfets fail and short-circuit the supply: http://www.personal.psu.edu/jrz126/i...ead_board.JPGI added a current-limiting circuit right after that.
(here's a video of it in action: http://www.personal.psu.edu/jrz126/i...king%20006.mpg)
__________________
Jeff
To the optimist, the glass is half full.
To the pessimist, the glass is half empty.
To the engineer, the glass is twice as big as it needs to be.
jrz126 is offline  
Reply

Bookmarks

Thread Tools
Display Modes



Similar Threads
Title Starter Forum Replies Latest
Intermediate DC Motor Control Circuit ElectroMaster Electronic Projects 27 20th December 2008 10:47 AM
Dc Motor speed control By PWM (( AVR)) kemo0o Micro Controllers 3 9th February 2008 06:12 AM
BASIC PIC command for dual PWM motor control? blueroomelectronics Robotics Chat 11 30th December 2007 06:21 PM
Motor Controllers and serial comm? RedCore Micro Controllers 18 3rd July 2007 02:27 AM
Motor Driver Relay Circuit acer_7 Robotics Chat 4 17th March 2006 10:55 PM



All times are GMT. The time now is 07:16 AM.


Electronic Circuits  |  Learning Electronics
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

eXTReMe Tracker