Searching \ for '[OT]: Robotics with Dan's PIC SBC' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/devices.htm?key=pic
Search entire site for: 'Robotics with Dan's PIC SBC'.

Exact match. Not showing close matches.
PICList Thread
'[OT]: Robotics with Dan's PIC SBC'
2000\12\14@231011 by Roman Black

flavicon
face
Dan Michaels wrote:

> >When will they be ready?? :o)
>
> Soon as I finish designing/prototyping the IR and ultrasonic
> transceiver ckts, and finish the pcb layout and get some
> protos :).
>
> Analog pickup amps --> LM324, 2 each 2-stage, single-supply,
> ac-coupled, inverter followed by non-inverter, gain selectable
> by R values, designed to handle any of phototransistor,
> electret mike, or ultrasonic rcvr. Pretty much std ckt.
> Any specific suggestions here?

I almost always use some type of RC filter etc before
any opamp, maybe a couple of stages. I suppose a few pads
there to patch in R,C,L etc without having to cut tracks??


>
> Separate IR LED / optologic detector [QSE156QT] channel.

Cool.

>
> External switch pickups - 4-6 stage R-ladder --> A/D channel [not
> real-time INTs like Tom's, but with programmable timer T0 or T1
> can perform A/D readings on fast basis].

Again cool.

>
> BTW, do you think having 2 ea L293's on board will satisfy your
> basic motor requirements? [I know you would really like 2-5Amps].
> There are some larger current pin-compat drivers, eg SN754410,
> that could be used with external clamp diodes.

For small stepper bots (ie micromouse competition) the
normal steppers are about 100mA to 400mA per motor, so that's
fine. Being able to drive a 1A motor (two 0.5A coils per motor
with small heatsinking will allow a pretty tough bot. My bot
pushes 1kg and uses 200mA total per motor. DC motors similar,
most micromouse dc motor/gearbox are under 500mA on average.

>
> Trying to keep small form-factor, so ....... [I think it will
> all fit].


Since the price of your SBC was quite reasonable, I am sure
you could sell half-kits (board, PIC, L293 etc) to schools
and colleges for micromouse competition. Having one board
that does the lot makes it more a programming exercise than
a major construction one.

Might I suggest the ability to measure battery voltage?
Two little resistors on-board would be nice! ;o)
-Roman

PS. Maybe you sponsoring a mouse competition might
be cool??

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics


2000\12\15@032332 by Dan Michaels

flavicon
face
Roman wrote:
>>
>> Analog pickup amps --> LM324, 2 each 2-stage, single-supply,
>> ac-coupled, inverter followed by non-inverter, gain selectable
>> by R values, designed to handle any of phototransistor,
>> electret mike, or ultrasonic rcvr. Pretty much std ckt.
>> Any specific suggestions here?
>
>I almost always use some type of RC filter etc before
>any opamp, maybe a couple of stages. I suppose a few pads
>there to patch in R,C,L etc without having to cut tracks??
>

There are currently caps across the opamp feedback resistors,
but I'll cook up the schematic for the opamp stages tomorrrow
and send a .GIF - there are several components on the front-end
for different arrangements/gains/etc. Be good to have some
feedback. Want to have it work for electret, phototransistor,
and ultrasonic receiver transducer, all three.
==============

>
>>
>> Separate IR LED / optologic detector [QSE156QT] channel.
>
>Cool.
>

I designed a really cool ckt today which I "think" can pulse
an LED at up to 40Khz and "also" control its intensity by varying
the width of the 40Khz pulses. 5 components, including 2 R's,
1 Cap, NPN, and LED. Requires only 1 PIC pin.

Think you can duplicate it? [just try :) - hint - the tricky part
is the cap - you have to be able to get a graded current in the
LED, but still interrupt the current at a 40khz rate - tricky
time constants]. I estimate I can get at least 6-8 intensity levels
running off a 4 mhz xtal - 1 usec cycle time.
===============

>
>For small stepper bots (ie micromouse competition) the
>normal steppers are about 100mA to 400mA per motor, so that's
>fine. Being able to drive a 1A motor (two 0.5A coils per motor
>with small heatsinking will allow a pretty tough bot. My bot
>pushes 1kg and uses 200mA total per motor. DC motors similar,
>most micromouse dc motor/gearbox are under 500mA on average.
>

Luckily, the L293 chips can handle motors that use large
voltages [and lower currents] - unluckily, the Tamiya is
low-volts and hi-mA.

I jigged up the L293 to drive the Tamiya twin-motor tonite.
Oh boy, did I learn a lot. I PWM'ed the enable inputs to
control motor speed, and purposely didn't use any bypass caps,
just to see how it ran, and also whether the PIC would burp
or not. No burps.

At full tilt boogie, the Tamiya was pulling >1.2A with both
motors grinding hard. No heat sinking on the L293 at present,
except for the pinchers on the ZIF socket.

You lose 2+ volts in the chip, so it was dissipating >2W,
and running pretty hot [I made popcorn]. I figure with 2 L293s
on the board, and long motor run times, it's probably best to
wire each motor to a different chip to spread the load.
The final SBC will have copper trace heatsinking, of course.

[note I typically like to also stress and qual test during my
"initial" design/proto phase - I managed to smoke the SBC
main v.reg - I smelled it in the other room!!].

Question --> ever try using PWM for controlling speed with
this kind of chip? I noticed you get really nice 40+ volt
spikes on the motor supply bus at the points where the
PWM turns on. Note this is with the catching diodes present
in the chip - but no caps present anywhere. Adding a bypass
cap does reduce the spikes to just a few volts, however.
And interestingly, the spikes don't mess the PIC.

BTW, big spikes not present with PWM = 0FFh. 100% duty cycle.

At any rate, I think it will work better if I filter the
PWM before applying it to the enable input, and was wondering
if you have done this with your chips too? [as it is, you really
get some retched looking waveforms on the motor windings].
=================

>
>Since the price of your SBC was quite reasonable, I am sure
>you could sell half-kits (board, PIC, L293 etc) to schools
>and colleges for micromouse competition. Having one board
>that does the lot makes it more a programming exercise than
>a major construction one.
>

Yeah, I always take the easy way out. Do it all in one
place and all at the same time. Still need to proto the IR
driver and design the ultrasonic transceiver.
==============


>Might I suggest the ability to measure battery voltage?
>Two little resistors on-board would be nice! ;o)

Aww, come on - those are already on there. Whatyaexpect?
But none of those fancy dodads people were designing last
week. Just 2 resistors.
==============

>
>PS. Maybe you sponsoring a mouse competition might
>be cool??
>

First prize, a burned up L293.

best regards,
- Dan Michaels
Oricom Technologies
http://www.oricomtech.com
=========================

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


2000\12\15@042703 by Roman Black

flavicon
face
Dan Michaels wrote:

> I designed a really cool ckt today which I "think" can pulse
> an LED at up to 40Khz and "also" control its intensity by varying
> the width of the 40Khz pulses. 5 components, including 2 R's,
> 1 Cap, NPN, and LED. Requires only 1 PIC pin.
>
> Think you can duplicate it? [just try :) - hint - the tricky part
> is the cap - you have to be able to get a graded current in the
> LED, but still interrupt the current at a 40khz rate - tricky
> time constants]. I estimate I can get at least 6-8 intensity levels
> running off a 4 mhz xtal - 1 usec cycle time.

That's clever, by using a cap and 2 resistors you can vary the
LED voltage/current by pwm relatively independent of the
frequency! Very cool. That didn't occur to me.


{Quote hidden}

Ok, assuming the tamiya motors are low V, high I, you should
be able to switch the h-bridge like a simple switching
supply and convert V to I. Should be! In reality I have not
done this with a h-bridge, I have done it a lot with a NPN
"buck" style transistor circuit with relay direction switching
for the motor. Normally I drive bigger DC motors, and
the relay contacts provide better on-resistance than
any NPN/FET!

I really don't know what to suggest. Maybe driving the
L293 at a different speed?? Make use of the motor inductance?
If you could use a buck inductor with flyback diode it gets
more efficient, but hard to do with a h-bridge?? Maybe
use one driver for PWM, with buck+diode, then another full
h-bridge to control motor direction? Sounds sloppy to me.
Maybe your board doesn't allow different supplies?? :o)

Seriously, if you are switching a 12v supply into a 3v
motor, you need duty of 25% or less. This should keep your
chip cooler anyway. I think maybe I would try increasing
switching freq much higher to use the motor as inductor.

A small RC snubber across the motor terminals will kill
most of the spikes and not affect your SBC. And maybe
a 0.22 ohm or similar resistor in series with the motor
is always a good idea.
:o)
-Roman

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


2000\12\15@135455 by Dwayne Reid

flavicon
face
>I designed a really cool ckt today which I "think" can pulse
>an LED at up to 40Khz and "also" control its intensity by varying
>the width of the 40Khz pulses. 5 components, including 2 R's,
>1 Cap, NPN, and LED. Requires only 1 PIC pin.
>
>Think you can duplicate it? [just try :) - hint - the tricky part
>is the cap - you have to be able to get a graded current in the
>LED, but still interrupt the current at a 40khz rate - tricky
>time constants]. I estimate I can get at least 6-8 intensity levels
>running off a 4 mhz xtal - 1 usec cycle time.

Probably similar to what I use to drive triacs: capacitive discharge.  A
resistor charges the cap, another resistor limits the peak current when the
transistor connects the cap to the LED.  The longer you keep the transistor
turned on, the less charge on the cap and the lower the peak current.

Close?

The triac drive circuit I am using right now (I've done *many* such
circuits over the years) is also weird - I use a -20V supply which charges
a 100n mono cap thru a 1K resistor; discharging with a 2n4403 transistor
and a 22R series resistor.  Those 600 - 800 mA pulses really make a triac
sit up and take notice - even when they are sitting at -55C.  I repeat the
pulses every 256 usec - its neat seeing 40A triacs able to drive a single
5W light bulb without flickering!  In my case, the transistor is turned off
for 250 us and on for 6 us.  I'll get around to publishing it eventually.

dwayne


dwayne



Dwayne Reid   <spam_OUTdwaynerTakeThisOuTspamplanet.eon.net>
Trinity Electronics Systems Ltd    Edmonton, AB, CANADA
(780) 489-3199 voice          (780) 487-6397 fax

Celebrating 16 years of Engineering Innovation (1984 - 2000)

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Do NOT send unsolicited commercial email to this email address.
This message neither grants consent to receive unsolicited
commercial email nor is intended to solicit commercial email.

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


2000\12\19@084641 by Andy Shaw

flavicon
face
Hi Dan,
Does the LM324 go rail to rail on output? If not are you using a ref voltage
other than the supply for the A/D input, or maybe a higher voltage for the
LM324 so you get full 0-5v input to the A/D. A year or so ago I put together
a "general purpose" board with analogue inputs to PIC. The one thing I wish
that I had done differently was to provide full 0-5v for the input to the
A/D the op amp I used didn't and I couldn't fine a pin for pin replacement
that did. Might not be a big deal for your purposes but it was certainly a
pain to me.

Andy

{Original Message removed}

2000\12\19@130053 by Dan Michaels

flavicon
face
Andy Shaw wrote:
>Hi Dan,
>Does the LM324 go rail to rail on output? If not are you using a ref voltage
>other than the supply for the A/D input, or maybe a higher voltage for the
>LM324 so you get full 0-5v input to the A/D. A year or so ago I put together
>a "general purpose" board with analogue inputs to PIC. The one thing I wish
>that I had done differently was to provide full 0-5v for the input to the
>A/D the op amp I used didn't and I couldn't fine a pin for pin replacement
>that did. Might not be a big deal for your purposes but it was certainly a
>pain to me.


Hi Andy, thanks for the comments.

My SBC40-BOT board is a little behind schedule [!!!], haven't gotten
around to breadboarding all the different ckts yet. However, regarding
opamps, I wonder what you actually used that caused a problem.

There are std pinouts for dual- and quad-opamps that are most
commonly used, so you can normally swap chips with no problems. The
CMOS devices almost all give you rail-to-rail inputs and outputs
when you need it - although they are a little more expensive:

dual:
bjt:  LM358
jfet: TL082, LF353 [my favorite], LF412
cmos: LMC6032, LMC6132

quad:
bjt:  LM324
jfet: TL084
cmos: LMC6034

The LM358 and LM324 are the same amps internally, and work
good with single-ended supplies where you need to get 0v
[ie, lower rail] on the input. Outputs do not go to the rails.

I have one ckt that uses a PIC73 with A/D ref = 5v buss, with
A/D driven by an LMC6032 which pretty much gets the rails.

best regards,
- Dan Michaels
Oricom Technologies
http://www.oricomtech.com
=========================

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics


2000\12\19@171634 by Dwayne Reid

flavicon
face
At 01:39 PM 12/19/00 +0000, Andy Shaw wrote:
>Hi Dan,
>Does the LM324 go rail to rail on output? If not are you using a ref voltage
>other than the supply for the A/D input, or maybe a higher voltage for the
>LM324 so you get full 0-5v input to the A/D. A year or so ago I put together
>a "general purpose" board with analogue inputs to PIC. The one thing I wish
>that I had done differently was to provide full 0-5v for the input to the
>A/D the op amp I used didn't and I couldn't fine a pin for pin replacement
>that did. Might not be a big deal for your purposes but it was certainly a
>pain to me.
>
>Andy

I regularly use LM324 to feed non-critical a/d inputs on PIC - but I power
the 324 from the unregulated supply on the board (aprox 15 Vdc on most of
my stuff).  That leads to another problem, but one that is fairly easy to
work with: a/d voltages that exceed the PIC VDD 'leak' into other channels
and cause false readings on those other channels.  Not a problem once you
know about it.

I can do this because I include the supply regulator on most of my boards
and the unregulated supply is readily available.

dwayne



Dwayne Reid   <.....dwaynerKILLspamspam@spam@planet.eon.net>
Trinity Electronics Systems Ltd    Edmonton, AB, CANADA
(780) 489-3199 voice          (780) 487-6397 fax

Celebrating 16 years of Engineering Innovation (1984 - 2000)

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Do NOT send unsolicited commercial email to this email address.
This message neither grants consent to receive unsolicited
commercial email nor is intended to solicit commercial email.

--
http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics


2000\12\22@133335 by Dan Michaels

flavicon
face
At 11:54 AM 12/15/00 -0700, Dwayne Reid wrote:
>>I designed a really cool ckt today which I "think" can pulse
>>an LED at up to 40Khz and "also" control its intensity by varying
>>the width of the 40Khz pulses. 5 components, including 2 R's,
>>1 Cap, NPN, and LED. Requires only 1 PIC pin.
>>
>>Think you can duplicate it? [just try :) - hint - the tricky part
>>is the cap - you have to be able to get a graded current in the
>>LED, but still interrupt the current at a 40khz rate - tricky
>>time constants]. I estimate I can get at least 6-8 intensity levels
>>running off a 4 mhz xtal - 1 usec cycle time.
>
>Probably similar to what I use to drive triacs: capacitive discharge.  A
>resistor charges the cap, another resistor limits the peak current when the
>transistor connects the cap to the LED.  The longer you keep the transistor
>turned on, the less charge on the cap and the lower the peak current.
>
>Close?
>

Dwayne, sorry for the long delay in reply, I'm just catching up on
missed emails.

Close? yes, a little different arrangement.

                    +5V
                     |
         D1         LED
    +---|<|---+      |
    |         |      C
PWM--+----Rb---+----B    NPN
20Khz    200   |      E
         .1uF C      |
              |      Re  50
             gnd     |
                    gnd

Original ckt didn't work as well as I would have liked --> so
added more components. Still pretty simple for controllable
intensity at variable frequencies using 1 pin.

Time constant Rb*C sets the cap charge time so that increasing
PWM pulsewidths give higher Vb within the time PWM is high, for
--> intensity control. Once Rb & C are chosen, you are somewhat
limited in the selection of PWM frequency.

D1 discharges the cap fast, so get fast turnoff. Re more or
less independently sets the max LED current. Did have a little
problem with stability/oscillations [emitter followers tend to
do that], so also put a 1000pF across Re. Also tried the LED
in the emitter leg, but didn't work as well.

best regards,
- Dan Michaels
Oricom Technologies
http://www.oricomtech.com
=========================

--
http://www.piclist.com hint: To leave the PICList
piclist-unsubscribe-requestspamKILLspammitvma.mit.edu


More... (looser matching)
- Last day of these posts
- In 2000 , 2001 only
- Today
- New search...