Subject:
|
Re : stuff (Big motor control)
|
Newsgroups:
|
lugnet.robotics
|
Date:
|
Sat, 16 Oct 1999 21:59:24 GMT
|
Original-From:
|
Stephen Unwin <stephen@elmsfarm.demon.coSPAMLESS.uk>
|
Viewed:
|
583 times
|
| |
| |
The following circuit should provide directional control
of a DC motor using two SPDT (Single Pole Double Throw) relays
and four diodes, but may not act quick enough for a PWM drive.
.--------O---------------------------.
| | |
| | O-------------.
| | | |
| \----/ \----/ .-------.
| \ / \ / |Relay 1|
| __\/__ __\/__ '-------'
O | | |
| O-------------'
RCX | |
Output | |
O-------------. |
O | | |
| --/\-- .-------. --/\--
| / \ |Relay 2| / \
| /----\ '-------' /----\
| | | |
| O-------------' |
| | |
'--------O---------------------------'
V+
|
O-----------------.
| |
O| O|
nc 1 | | nc 2
O| O|
| ___ |
| .-/ \-. |
O----| | M | |----O
| '-\___/-' |
| |
O | O |
no 1 | | no 2
O | O |
| |
O-----------------'
|
GND
I have just come back from the pub where I've been thinking about this.
I haven't looked at the output signals on an oscilloscope yet, but I think
the following may work.
Assuming you are driving a more substantial motor than a LEGO one, you will
have a separate power source with which to power any circuitry.
You can have two op-amps set up as comparator circuits with a small (+0.5v)
bias on the positive inputs. On one op-amp the +input gets one side of the
RCX output and the -input gets the other side. This is reversed on the
second op-amp. The output of one these comparators goes to SET of an S/R
flip/flop and the other to the RESET. This will give a logic signal for the
direction on Q of the flip/flop and an inverse signal on Qbar.
Both signals from the comparators can also be NANDed to give a logic pulse
for PWM. These three signals can go into half of a L293D driver chip or
a stepper motor driver chip.
in1 = Q
in2 =Qbar
enable = NAND output.
/////
< .. >
>
- stephen@elmsfarm.demon.co.uk
|
|
Message has 1 Reply:
2 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|