Where to start with microcontrollers?

So here is the deal, I'm a self taught computer nerd and wish to mess around with small electronics and microcontrollers. I can already write ASM, C, JAVA, and BASIC with C and ASM under GNU/LINUX being my preferred languages. Seems I'd be in luck with the uC because ASM and C are pretty common from the looks of things, I have however a dilemma and I was hoping to find some help from the wisdom of others.

WHAT BRAND?!?!

I don't want to start with PIC and learn that for robotics, radio, or touch screen type applications PARALLAX or ATMEL are better due to something I don't understand right now and have to learn another uC (because I know each brand is going to have its own entertaining little traps and puzzles and stumbling blocks along the way no matter how well I speak any language).

I just want to learn one brand, PARALLAX looks best right now because they have the SX for smaller aps and the PROPELLER if I need to more power but I'm not sure if I am looking at all the correct parameters. Thanks for your time.

-BK

Reply to
somuchbadkarma
Loading thread data ...

Use the Atmel AVR cpu and the gcc compiler for it.

Reply to
BobG

The cloud: No matter what you pick, it'll be wrong for some application. If one microprocessor company were so much better than the rest, the rest would go out of business.

The silver lining: No matter what you pick, it'll be right (or at least acceptable) for many applications. So choose what looks good, and run with it. From a hardware perspective the PIC outshines the AVR. If I had to settle on one I'd look at the PIC-24 as it has gnu compiler support and it retains the outstanding current drive capability of the other Microchip parts.

The caveat: But expect to use something different at some point. It's inevitable, get used to it.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" gives you just what it says.
See details at http://www.wescottdesign.com/actfes/actfes.html
Reply to
Tim Wescott

I prefer the r8c/m16c/m32c family at the moment. Partly because I was responsible for the gcc tools for it (and still maintain them) but from an EE point of view, the chips are very nice to work with - programming them doesn't require special hardware, there is a plethora of on-chip peripherals, the CPU model is "conventional", and they're available in a very wide range of packages and performance, from a 20 pin R8C with 16k of flash, up to a 144 pin m32c with 1.5Mb of flash.

The only drawback is that none of them are available in standard DIP packages, but I've designed and built a couple of adapters for them, it's not that tricky.

Renesas's stuff:

formatting link
My stuff:
formatting link

Reply to
DJ Delorie

What's parallax ?

If you don't like PICs then the best and most used 'alternative' is the

80(C) 31/51/52 family and its derivatives. You simply can't go wrong with these.

OTOH, many here would now suggest the AVR or MSP430 families.

Graham

Reply to
Eeyore

What are those ?

Graham

Reply to
Eeyore

Hi I expect some other people may remember the heated discussions about 20 years ago, about which CPU was best - Z80, 6502, 6800 etc. etc. - we are still waiting for an answer :))

The fact is they are all good. For general applications what you can do is to pick the one that seems to be used by most other people. If you look around - what microcontroller has the most books available and seems to be the most popular in magazine projects. In this way you will probably get the best support.

That is why I chose PICs and development tools from Microchip.

Hope this is useful, Alan

Reply to
Alan

NONE of which are MICROCONTROLLERS you blithering IDIOT !

Can you actually read (the subject line) ?

Graham

Reply to
Eeyore

Follow the link to Renesas's site.

formatting link

In a nutshell, they're 16 bit CPUs with a combined data/code space (not harvard), flash, ram. Bigger chips have options for external address/data busses. Most of them run at 3.3 to 5v (bigger ones have split power, like FPGAs), some run as low as 1.8v.

The core architecture is much like the 8086 - some of the registers can be split into 8 bit registers, or you can combine them into larger registers (up to 64 bits). CISC encoding. Pointers are either 16 bits (r8c/m16c) or 24 bits (some m16c, all m32c).

Their focus seems to be automotive, so plenty of CAN, LIN, UART, and IrDA peripherals, in addition to the usual I2C, SPI, and motor control stuff. They're also designed to be ESD-tolerant; I have five of them in my furnace project - bolted to an ESD generator (the electrostatic filter) and none have had any problems with it. Even with all the handling and rework I've done in my prototypes, not one has stopped working.

Note that Renesas is the same company that brings us the H8, SH, and M32R processors, as well as a number of other mcu families.

Reply to
DJ Delorie

A truly STUPID piece of advice.

Graham

Reply to
Eeyore

And thirty years ago, everyone was pretty much starting out. Except for those with previous computer experience, anyone getting a home computer was not only learning about their given CPU, but about how to program and if they were hooking it up to something external, how to do that hardware and control the interface.

Coding is coding, and once you've picked that up, translation is relatively easy. Being able to imagine an end product and make it come to pass is another skill that is transferable.

But "learning about microcontrollers" is a move to hardware in a way that many that are used to computers nowadays haven't experienced.

My first computer, a KIM-1 back in 1979, was great for such things. It had a good monitor, so not only could I enter programs without having to program something (or else create a bootstrap ROM without any experience with programming) and it allowed me to single step and see how the instructions operated or set interrupt points so I could run a bit of code and then stop to see results. It had hardware built in so if I wanted to play with some LEDs or something else it was realy easy to attach them, and then play in the software to control them.

And those things are still important, likely more important than which CPU (and unless the original poster is going to use a 16bit CPU for this project, any CPU he chooses will be different from what he's used to, unlike the old days when you picked a CPU for often vague reasons, and used it for everything because it was more or less as good as anything else, and about the "top of the line" anyway).

Of course, in the old days there were articles about bootstrapping a CPU. About 1980, Byte ran an article about bootstrapping an 8085, adding some hardware so it would single step and jamming the databus with NOPs (I think it was) so the address bus would advance and then one could load RAM with the desired code (via some circuit board pads and a stylus). Because of the bootstrapping method, and because the bootstrapping hardware was simple, you could toss it all together with scraps. I later saw the same basic concept described in Dr. Dobbs for the 68000. You didn't even need an eprom programmer or eraser, added things that were some sort of obstacle for playing on that level.

I'm sure that sort of thing could be done today if desired, though I don't have the date of the Byte article handy. The simple circuitry to get things going is a way of getting started with hardware, which often is needed when using a micrcontroller.

But it is that controlling ot the external hardware that's important in the learning process. To make liitle bits of circuitry that can be controlled, and then play with the software to control them. Nowadays, many don't have that experience, even though they may be writing software, and modern operating systems tend to isolate the hardware from the software. You don't have to fiddle with a driver for that serial port, but then you don't have the experience at controlling the uart.

Michael

Reply to
Michael Black

I have used PICs for around 30 years. They are awkward little micros as they seem to have bits that need setting or resetting all over the place. After originally being a Z80 man I hated the subwf on the PIC it all seeems to work backwards from the Z80.

The 8051 series seem easier to use.

I still use PIC's but only because they are so cheap and I have many templates to work from instead of having to read the spec from start to finish to work out every bit setting.

Reply to
Marra

--
I\'ve been using Motorola\'s stuff (now Freescale) for about 20 years
and have absolutely _zero_ complaints.
Reply to
John Fields

6809 :-)
Reply to
Tom2000

Maybe you can *buy* a sense of humor. It's obvious you weren't given one.

Reply to
Tom2000

There's nothing humourous about it.

Graham

Reply to
Eeyore

out 20

ing

Why so harsh? He was just making an aside about CPUs, as he plainly noted, not microcontrollers.

Anyway, to the OP, I'd suggest looking at the AVR and/or 80C51 families. Later on if you feel the need you can check out the 32-bit ARM7 stuff like the LPC2000 family.

For AVR,

formatting link
is a good site. For 80C51 try
formatting link

Mike

Reply to
Mike Silva

I'd consider looking into the Arduino Diecimilia board. I teach a robotics class in the Boston area built around this board, and many people I know use it extensively. Here are the advantages:

  1. It's open source, so there's lots of development happening around it, and it's popularity is growing.
  2. It has a free, open source IDE that can be downloaded from the Arduino site.
  3. The board interfaces nicely with Processing which makes the integration between physical computing and multimedia (video) much easier.
  4. Very low cost, the whole board is about , or if you want to go with the bare bones version . (version for wearable, wireless also available).
  5. Lots of tutorials available online.
  6. Other language IDEs available too, including python and ruby.
  7. You can get a really nice protoshield for it.

I think the open source nature of this board has really done wonders for the robotics community. Check it out if you haven't already. The arduino site is:

formatting link

-Meredith Garniss

formatting link

Reply to
WilloughbyBaltic

You would be very foolish indeed not to consider the PIC, it has more beginner kits and info available than any other micro, and their range of devices is enormous. Easy to migrate from 8bit to 16bit to 32bit, with hundreds of specific devices to choose from. You are incorrect when you say ATMEL and PARALLAX are better than PIC. ATMEL and PIC are the two "biggies" for beginners who want to get serious. Parallax are not really professional devices, they are more designed for the hobby market.

Parallax are NOT a good choice if you intend to get serious with micros. The "STAMP's" are not really a micro as such, and the SX and Propellor are "fringe" devices that aren't nearly as popular as other micros like the PICs, ATMEL and TI's etc.

If you chose parallax it is very likely you will have to learn another brand at some point. Want a simple 8 pin micro that costs a dollar?, can't do that with parallax. Want a super cheap micro in volume specifically tailored to an application?, can't do that with Parallax. Think you might get into DSP?, Parallax is a poor choice. Want to get a job in the industry?, harder to do that with only Parallax experience. The list goes on.

You aren't really looking at the correct parameters.

I would recommend either PIC or ATMEL, or even TI MSP. All have plenty of development kits, free tools like professional C compilers and assemblers, and lots of user groups to help you out. All have their pros and cons.

Dave.

Reply to
David L. Jones

I would just like to say thank you all for your posts and that I read each of them completely and have learned more from the advice you have put up here than I have from countless other websites. Thank you

- BK

Reply to
somuchbadkarma

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.