a hobby class on microcontrollers

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
I need to think about a class that will include both young
and old, all of whom have very little experience but at least
the hope of trying to enjoy such a class on microcontrollers
without knowing anything much about what they may be getting
themselves into.  (And I mean for people who might be 15
years old or even 75 years old!  No college credit.  Just a
community education class with the purpose of some exposure
to the world of microcontrollers and how they can be fun to
learn about.)

Imagine it as taking a "pottery class" might look like for
those not knowing anything about various temperatures and
glazes and how they interact or the kinds of clay or any of
the methods of making pottery; nothing about "throwing" a pot
and almost nothing about pinching one up.  Students who have
NO IDEA at all what they are walking into, but feel it "might
be interesting" and willing to have a go at it.

A task here is to help them find their own motivations and
enable them to succeed with at least one project idea.  I may
start out with a survey of the class and skills and interests
and then provide a spectrum of options to pursue, let them
choose their poison so to speak, then give them the tools
they will need, some basic education and support, and then
'run the class' in a way that has me alternating between
short lectures and going around the room and helping them
move forward when facing a barrier.  The project itself will
need to come from their interests, though.

Some may do almost the same thing as others, but in their own
unique way.  Some may attempt something entirely different.
And some may have taken the class before, maybe 3 or 4 times
before in fact, and may be "advanced students" who will not
need so much teaching time themselves but just a little
support and might even be able to act as help for other
students who are new, with advice and maybe a little hands-on
help, too.

An idea I have is to purchase existing kits (which I can get
for less than US$1, in ones, cheaper still in larger qtys.)
These:

 
http://www.infinitefactors.org/misc/images/sciencetime.png

Many of them include a small DC motor, bright red LED, 40kHz
emitter and receiver for motion detection, and so on.
Actually, quite a few interesting parts.  (At less than $1,
these even include the boxes and shipping!)

One thought I'm considering is to use these as a base concept
that the less knowledgeable students can select from.  Then
to go through an idea stage where we talk about possible
modifications using a microcontroller and I work to "limit"
their imagination to something they can likely achieve using
a microcontroller.

The "microcontroller" they choose needs to be something
cheap, available in DIP form, has an inexpensive development
environment that isn't hard to use, and will probably have to
come in BASIC, c, c++, and assembly incarnations.  Maybe
Forth, too.  (Yes, I'm thinking about it.)  Or some other
'turtle graphics' environment.  I don't mind having to solve
a lot of issues before starting, just to make sure there is a
spectrum of options here.  But the financial "hill" cannot be
high.  A $30 processor (Parallax) is NOT in the cards.  $10
for everything is reasonable.  (This must include USB cable,
board, a cpu or two, IDE and software tools, and various
parts they will combine in some simple way.)  $20 is pushing
it and will probably put too high a barrier on the less
advanced students.  The more advanced students will probably
be willing to spend more.

Examples might be to take the "Robotic Beeper," which
includes a DC motor, fairly-decent-for-the-price gear box,
wheels (and two o-rings for the drive wheels), battery case
for 2 AA batteries, and some wire and other stuff, and
consider adding a small micro with dc motor drive circuit
(using a cheap, discrete PNP and NPN h-bridge -- the NPNs I
get for 0.3 cents each and the PNPs are more like 1 cent each
and the resistors are dirt cheap) and letting them think
about some interesting thing to do with that.  It might be
possible to merge this with another kit (the "Electronic
Motion Sensor") to do something interesting.  Ideas like
that, anyway.

Out of pocket cost is important.  Might be local high schools
and after-class time with students drawn from there.  Might
be as a community outreach class with a community college and
a wider range.  Might even be held at an old folks' home or
residence center as a social activity (or physical therapy)
and a chance to bring in others and expand their horizons
just a little.

It can have a more artsy focus for some, a more practical for
others.  In pottery, you will see some students go for cups,
plates, and bowls -- practical stuff -- while others go for a
more Picasso or frilly look and zero practicality.  Some will
have no imagination at all and will need me to suggest some
ideas to build on.  But I think students should be able to go
in a variety of directions that _they_ choose for themselves.

I'd also like to figure out the "sizzle" that will sell the
class.  There will be meat there, but I need to get them in
the door in the first place.  Might be sold to parents to
provide after hours with students learning but to the parents
it lets them not have to worry quite as much about their kids
while they are themselves busy at work, etc.  Might be sold
directly to those in the class by helping provide them with
something they can take home and keep and feel proud about.
Might be sold to others wanting to go home and try and pass
along some interest of theirs to family members.  I don't
know.

I don't have make-or-break expectations about its longer term
success.  And I don't want to worry about it.  I would simply
like to consider the idea, flesh it out a bit to see how it
'flies,' and maybe take a chance and see what happens.  The
worst is nothing at all.  And even then, I've tried and
learned something from the effort.  Anything more than that
is probably a good success and I will let the students and
potential students help show me the way.  It may never amount
to much, but simply doing it helps to develop community and
that alone is a "good."

If there are some constructive thoughts, I'd love to hear
them.  If you know of a terribly serious flaw (outside of
mere ad hominem) that I've completely missed, that's
constructive too.

Jon

Re: a hobby class on microcontrollers

Quoted text here. Click to load it

We are suppling these $10 boards to a local college.  It might work
for you as well.

http://linnix.com/udip

Atmega32u2
C/C++ (WinAVR)
USB boot loader (Atmel Flip)
32K flash
512 eeprom
Reset and hwb switches
Bi-color LEDs (Red and Green)

Re: a hobby class on microcontrollers
On Mon, 28 Jun 2010 09:55:20 -0700 (PDT), linnix

Quoted text here. Click to load it

Thanks, Linnix, for pointing this up.  I'll have to check to
see how much ram is present.  32k flash is more than I hoped
for, though, and the bicolor LEDs are nice to have.  The
existence of the port pin through-holes would qualify this
for use by beginner students so that satisfies my 'dip'
requirement, I think.  It doesn't come with a usb cable, I
gather.  So I'd have to factor that additional cost into the
other criteria -- total investment by the students probably
should be closer to $10 and not more than $20 total,
including other parts like DC motors and BJTs and so on.

Jon

Re: a hobby class on microcontrollers

Quoted text here. Click to load it

I should add another problem, though -- shipping and more on
the issue of DIPs.  I wanted DIP because I want the _actual_
micro piece used in the final project to cost very little, so
that students could consider owning several for their
projects or buying more on their own.  TI's $4.30, with
shipping included (which I don't know about in the case you
mentioned), also includes two processor DIP chips.  And the
price point for more is 'very low.'  So they get a complete
JTAG programmer _and_ a socket that allows them to use low
cost parts in anything they decide to do.  Your suggestion is
very nice, all in all, but the 'each' price is $10 (if they
would like to have three or four different versions or three
or four different projects.  In the TI case, the extra cost
for each additional project is less.

Since I don't know whether or not students will care to do
more than one, it might not be a problem.  I'll have to wait
and see, I think.

Jon

Re: a hobby class on microcontrollers
Am 28.06.2010 20:44, schrieb Jon Kirwan:

Quoted text here. Click to load it

I don't think that's a valid line of reasoning.  I seriously doubt that
the part being DIP has a guaranteed positived correlation to its
cheapness.  Not these days, any more.

I imagine the overhead in bond wire length, plastic material and pins
must be a major factor in the total price for microcontrollers by now
--- those with few enough pins to be eligible for putting in DIPs in the
first place, anyway.  Not to mention economy of scale.  I.e. even the
same chip in a different housing should generally be cheaper than the
DIP version.

Let's face it, guys: cheaply socketable DIP is a dead parrot.  The only
reason it's still sitting upright on its perch is that its feet have
been nailed to it.

Re: a hobby class on microcontrollers
Quoted text here. Click to load it

...


I agree.  Another way to put it is the demand for DIPs is probably due to:

- Legacy (a diminishing market driver)
- Educational and hobbyist (not much money there)
- Old farts like me who like to work with DIPs in our labs (also
diminishing)

Supply will answer demand but for a price.  In low quantities, price is
usually not the highest priority in a purchase decision so you'll pay extra
for the convenience of a DIP.

JJS




Re: a hobby class on microcontrollers
Quoted text here. Click to load it

I'm not sure what "dead parrot" means, but for a hobby board (or any
board that someone will be "experimenting" with) having the chips in
sockets is an advantage come repair time.


Re: a hobby class on microcontrollers
Quoted text here. Click to load it

<http://en.wikipedia.org/wiki/Dead_Parrot
<


http://www.youtube.com/results?search_query=dead+parrot&aq=f


If you are not a Monty Python fan, it might be hard to appreciate the
humour in it, but basically a "dead parrot" is something that is dead,
but some people claim it is actually still alive.


Quoted text here. Click to load it

Unless you have nothing much on the board, or everything else is
socketed, then there are few advantages in having the microcontroller
socketed.  It is helpful to have reasonably large pitch, so that you can
solder the chip, but I don't understand the big desire for DIPs for a
microcontroller.



Re: a hobby class on microcontrollers
Quoted text here. Click to load it

I get it now. I should have looked it up!

Quoted text here. Click to load it

In Jon's case I would think it to be an advantage, because it
sounds like he wants a board so simple that it may have only the
microcontroller on it.


Re: a hobby class on microcontrollers
Am 29.06.2010 01:43, schrieb Gary Peek:

Quoted text here. Click to load it

It's an advantage only if you can get the chips you need in that format.
  Which basically you can't anymore, for just about any of the
interesting chips, because nobody is making them any more.  And if they
do, they cost extra just for being in that form factor.

I'd even point out that making the CPU too easy to exchange is a
pedagocically bad idea.  The extra work to exchange a soldered-in CPU
(fingers occasionally burned on the soldering iron included) motivates
students to _think_ --- and do to it _before_ they connect stuff to a
part that'll take an hour to replace before they can go on.

Socketed parts are necessary only if they have to be dismounted as part
of regular operation (e.g. to burn code into them off-board).  In most
other situations, they indirectly teach carelessness.

Re: a hobby class on microcontrollers
On Tue, 29 Jun 2010 00:01:03 +0200, Hans-Bernhard Bröker

Quoted text here. Click to load it

Despite your assurances contrary-wise, it is.

Quoted text here. Click to load it

No.. no.. that's not what I meant.  I completely agree with
you that DIP is __more__ expensive.  They are more expensive
to make.  I've no doubt of that.  Plus, if making in quantity
helps cut costs further, then DIP will be more expensive for
that reason, too.

The issue isn't the difference between say $1.20 for DIP and
$1.00 for SMT.  The issue is being able to use cheap, easy to
understand tools in wiring up.  A DIP socket is very cheap.
Even a ZIF socket for DIP is way cheaper than a ZIF socket
for some other beast.  And very inexpensive soldering irons
and ham-fisted neophytes using them can be successful (enough
times to not be completely frustrated, anyway) soldering to
them.  The 0.1" spacing is a minimum.  I'd rather the parts
used 1/4" spacing between pins.  But that's not in the cards.

The main thing is being able to hold something in one's hand,
not lose it when you sneeze, and basically imagine these are
75 year olds or 15 year olds doing this.  That is, if I allow
them to use a soldering iron at all.  Which I probably won't.
Chances are, some of this will be done with Global
Specialties prototyping boards and they will need to insert
DIP parts into it and use jumper wires to connect things up.
I _may_ introduce some of them to wire-wrap.

Also, Linnix's board is all SMT and it costs (let's say) $10
each.  If a student needs two of them, they pay $20.  But in
the case where a processor is available separately, then it
might only be $1 or $2 or $3, instead, since a whole board
doesn't have to come with it.  And Linnix's board doesn't
have a socket on it so that's a problem.  The TI board comes
with a socket.

So there are a number of considerations included when I say
"cheaper than."

Quoted text here. Click to load it

Just you aren't getting what I was talking about, that's all.
I probably wrote more poorly than I should have.

Jon

Re: a hobby class on microcontrollers
Am 29.06.2010 02:12, schrieb Jon Kirwan:
Quoted text here. Click to load it





It is what you wrote, though.  You'll have to forgive me for believing
you meant what you wrote.

Quoted text here. Click to load it

As I just pointed out in another reply, a socket may not be as good an
idea as it appears at first sight.  It encourages sloppiness.

Quoted text here. Click to load it

And it AFAIK it never was.  DIL/DIP ICs never had bigger spacing than 0.1".

Re: a hobby class on microcontrollers
On Tue, 29 Jun 2010 12:25:15 +0200, Hans-Bernhard Bröker

Quoted text here. Click to load it

Yes, I'm aware.

Jon

Re: a hobby class on microcontrollers
On Tue, 29 Jun 2010 12:25:15 +0200, Hans-Bernhard Bröker

Quoted text here. Click to load it

Some (most, I think) probably will need to work on
breadboards and use stripped jumpers to make connections.
These use .1" spacings.

And I'm not sure neatness is my proper primary goal, anyway.

Jon

Re: a hobby class on microcontrollers
Quoted text here. Click to load it

Hobbyist here. (At least when it comes to embedded work.)

I regard DIP as been cheap, but not because of the price of the component
(which is usually a bit more expensive than it's alternatives in other
form factors).

No, I regard DIP as been cheap because I can take the component and just
place it in a breadboard and start experimenting with it. I don't have to
make up a full PCB or adapter board before I can start using it.

If I had to make up a adapter board/PCB, I would have to either have the
materials to hand or have it made up and wait for it to be delivered.
Either way, I have to spend additional time and money before I could use
the non-DIP component.

To Jon: Are you distinguishing between your students hardware and software
capabilities ?

They may be less developed on the hardware side of things than they are on
the software side of things or vice versa. It's certainly true for me; I
still use DIP components on Veroboard, but can read (and understand) a
datasheet and write drivers for devices without any problems at all. I've
also, as a hobbyist, created a RTEMS BSP for a ARM board in the past as well.

I tell you this in order to have you think about the possibility that your
potential students may be at different levels when it comes to hardware and
software.

Simon.

--
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980's technology to a 21st century world

Re: a hobby class on microcontrollers
On Tue, 29 Jun 2010 13:12:39 +0000 (UTC), Simon Clubley

Quoted text here. Click to load it

I plan the case where both are poor, but will embrace those
with better skills on either side and work with that.  The
plan is to work very hard to make everyone comfortable and
satisfied that they succeeded in some fashion.  But not to
expect them to necessarily want to continue afterwards.  I
just want it to be fun; a tiny bit challenging but not beyond
their own limits.  And where they get to take home something
they can show others and laugh about or feel kind of proud of
having worked on.  A tangible take-away is important, I
think.

Quoted text here. Click to load it

Yes.  And my comment about not letting them get near a
soldering iron probably holds.  I don't want to have to worry
about burns.  Probably use solderless breadboards for the
most part.

Quoted text here. Click to load it

And me.  I've had a job in my long since past doing soldering
as a job -- my first 'real' and regular job, in fact.  But
I've never been exceptional at it.  I'm still mostly a wire
wrap type, though I'm just starting to get the hang of layout
and making libraries of part footprints and getting a board
done.

Quoted text here. Click to load it

Yes, I'm there with you.  I can read and understand many
schematics, as well.  I can even produce a small number of
modest ones.  But I've never sold a single hour of my time
for that purpose.  And I never will try to.

Quoted text here. Click to load it

Thanks, Simon.

Jon

Re: a hobby class on microcontrollers
Quoted text here. Click to load it

It got 512 bytes of sram.  There are usb buffer rams as well, so it
won't cut into the 512 bytes.

Quoted text here. Click to load it

Yes, they asked for that.  Two port pins for red, green or off.

Quoted text here. Click to load it

We might be able to include the usb cable.

Quoted text here. Click to load it


Re: a hobby class on microcontrollers
On Mon, 28 Jun 2010 15:27:22 -0700 (PDT), linnix

Quoted text here. Click to load it

That's quite decent for many purposes.

Quoted text here. Click to load it

It's a nice feature to play with.

Quoted text here. Click to load it

Depending on what I can find, that might help some.

...

I think you've suggested a great option that I think I'd like
to explore more.  If you don't mind, I'd like to buy a couple
of them and try them out.  I want _options_ for the class,
not a limited one-horse deal, so this may help expand choices
a lot for the students... depending on what their interests
are.  Thanks for the suggestion!

Jon

Quoted text here. Click to load it

Re: a hobby class on microcontrollers
Quoted text here. Click to load it

Sorry, it's 1K sram and eeprom.  The chip is available for $3 and
unassembled kit for $6.  Fully assembled and tested for $9.  Cable
included.

Datasheet is here:
http://www.atmel.com/dyn/resources/prod_documents/doc7799.pdf

This chip is for building USB devices.  There are sample firmwares for
Keyboard, Mouse, CDC, etc.

I'll put some up for sale on ebay over the next few days.


Re: a hobby class on microcontrollers
On Tue, 29 Jun 2010 11:11:29 -0700 (PDT), linnix

Quoted text here. Click to load it

So this is the ATmega32U2?  With 32kb flash, 1kb sram, and
1kb ee?  That's quite good for many uses.

Quoted text here. Click to load it

Actually, that might help me for some of my own tinkering.

Quoted text here. Click to load it

Thanks.  I'll look for something along these lines, then.
Expect an order for at least two from me.  Then comes the
longer work ahead to make some use of them and try them out.

One of the things that I know I will need to supply to a few
students is a BASIC that supports floating point.  I am still
not sure if that is what I want to do for total beginners.
But I can easily see students coming back for more perhaps
wanting to expand their own skills and wanting to do some
work that might be a lot easier to teach if I had floating
point support available.  Having 32k flash solves the
technical problem fielding a decent FP capable device.

Jon

Site Timeline