Shop OBEX P1 Docs P2 Docs Learn Events
The Best Microcontroller? — Parallax Forums

The Best Microcontroller?

Jim the HermitJim the Hermit Posts: 79
edited 2012-06-21 06:20 in General Discussion
Well, the Best microcontroller is a matter of "whatcha need?"

I need memory! The more the merrier.
Followed by good number of I/O lines and high-speed. And Price is a pretty close 2nd-3rd place.
Running some form of BASIC is good. I never liked C/C++.

I was thinking of experimenting with Propeller or BasicX. Anyone have other ideas?
Thnx

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2012-06-18 18:34
    Does the microcontroller you're considering do what you want? Depending on your needs for help, does the associated community offer help? Does the manufacturer provide the tools you want and the support you think you'll need?

    The Propeller is fast. It has multiple processors on chip. It has 32K of shared memory on-chip that is used for code (Spin) and data. There are 32 I/O pins that can be used interchangably (with some minor restrictions on 4 of them). It can do lots of things that would be hard to do directly with most other microcontrollers like video and a variety of soft peripherals. You can program in Spin, assembly, several integer Basics, Forth, C, etc. If your application is not speed intensive, you can use a large external memory to hold the code in C.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2012-06-19 08:32
    Love the one you have. More memory is not actually that useful for a microcontroller as many tasks require very little. Being fully deterministic is far better than having to deal with interrupts and jitter. ADC included makes hobby applications much easier to build.

    I find that a microcontroller generally does NOT require a file system; while a microcomputer always uses a file system. They are very different devices and for many projects having Linux or Windows or whatever is a huge waste of time and effort. Small is beautiful.

    Also, a wide well-informed user base to seek knowledge from is important. Some devices seem to have the blind leading the blind.

    BasicX is rather poorly documented or supported; but ZBasic is an off-shoot that is excellent. The contrast between the two well demonstrates how good support can make a great product and poor support can ruin excellent hardware.

    The Propeller is just more fun as it does a surprising amount of things that others struggle to do - and does such tasks better.
  • ercoerco Posts: 20,259
    edited 2012-06-19 09:21
    Fierce debates of religion, politics, and "best microcontroller" can go on forever without any agreement.

    Much like the great plywood and relay debate. :)
  • ZetsuZetsu Posts: 186
    edited 2012-06-19 14:00
    erco wrote: »
    Fierce debates of religion, politics, and "best microcontroller" can go on forever without any agreement.

    Much like the great plywood and relay debate. :)


    Debates as such are being solved ! http://www.youtube.com/watch?v=Bp464vKKu5g
  • ZetsuZetsu Posts: 186
    edited 2012-06-19 14:01
    That ladder would have totally won, if the table didn't cheat ;x
  • Jim the HermitJim the Hermit Posts: 79
    edited 2012-06-19 14:40
    Love the one you have. More memory is not actually that useful for a microcontroller as many tasks require very little.

    No, no, no. I have a basic stamp 2sx, and there isn't nearly enough memory to do what I want. (several 2 dimensional arrays kind of stuff) I need to upgrade.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2012-06-19 15:06
    Jim,

    Based on your previous robot project, I'd bet the Propeller would be the microcontroller that would be the most useful for your needs.

    The Prop's 32K if memory in a bit limited for video graphics work but if you're looking for a way to store sensor data and robot parameters, the Prop should be fine.

    The Prop doesn't have native 2D arrays, but you can easily fake them with a single dimension array.

    If you have a lot of data to store, you could add a SD card.

    I hope you've seen my PropBOE-Bot that can record it path and then play it back.

    The Prop is really an ideal microcontroller for robot projects. Being able to divide up the various tasks among multiple cogs is a very powerful capability and makes programming a robot a lot of fun.
  • jmgjmg Posts: 15,183
    edited 2012-06-19 17:32
    Well, the Best microcontroller is a matter of "whatcha need?"

    I need memory! The more the merrier.
    Followed by good number of I/O lines and high-speed. And Price is a pretty close 2nd-3rd place.
    Running some form of BASIC is good. I never liked C/C++.

    I was thinking of experimenting with Propeller or BasicX. Anyone have other ideas?

    You need hard values before closing in on a choice. "good number of I/O lines and high-speed" is very vague.

    Generally, you can start with the hard-numbers first, like Pin-Count, Supply voltage range, Peripherals, - that excludes many,
    then you can check into Core and languages supported....

    Do not be averse to using more than one Microcontroller.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2012-06-20 01:51
    The 'need for multiple dimension arrays' has long been a rather odd conflict.

    With a little simple coding, anything can have any kind of array that one wants. Providing a set of 'array' commands in a programming language leads to people not learning how to write their own as required into any platform.

    For a 2x array, it can be as simple as allocating a block of memory with such that data alternates in an 'ab,ab,ab, ab...' fashion for any number of items.
  • Invent-O-DocInvent-O-Doc Posts: 768
    edited 2012-06-20 13:08
    I fooled around with several basic based microcontrollers. I really liked the Coridium ARMite that has/had a great basic compiler/interpreter and had lots of RAM 64-128kb. Also, went as far to download all the ZBasic documentation. In the end, I ended up doing SX/B (Basic) on the SX chip because those platforms were so expensive per unit. I eventually ended up on the propeller and really like the multiprocessing and power. The big pull more me with the SX (initially) and the Prop is the fact that there is such an extensive and active support base compared to the other basi-based micros.
  • xanaduxanadu Posts: 3,347
    edited 2012-06-20 17:56
    Jim you didn't say what the memory is for or how fast it needs to be. The easiest way to add a lot of memory is an SD card adapter on a suitable microcontroller such as the Propeller.
  • Jim the HermitJim the Hermit Posts: 79
    edited 2012-06-20 18:14
    xanadu wrote: »
    Jim you didn't say what the memory is for or how fast it needs to be. The easiest way to add a lot of memory is an SD card adapter on a suitable microcontroller such as the Propeller.

    Yeah, I'm probably going to go with the propeller. The memory is for programming and data accumulation and storage. I imagine the program is going to be quite long, so it should be fast. How much memory, how fast? I don't know.
  • prof_brainoprof_braino Posts: 4,313
    edited 2012-06-21 06:20
    I need memory! The more the merrier.
    Followed by good number of I/O lines and high-speed. And Price is a pretty close 2nd-3rd place.
    Running some form of BASIC is good. I never liked C/C++.

    I was thinking of experimenting with Propeller or BasicX. Anyone have other ideas?
    Thnx

    IF, and this might be a big if, you can relax your requirement for BASIC, you have an optional that pretty much gives you what you want on the propeller: Propforth.

    The propeller is cheapest (assuming you already have one on you desk, most folks on these forums do).
    The propforth environment is a high level programming language with a simple syntax, much like BASIC, only much more powerful. Source is interpreted on the fly when code is input, and the definitions are compiled into the dictionary. Execution speed is very fast. If you need even faster, you can write "snippets" in assembler, and call these from high level forth. You get to concentrate on the parts that need assembler, without having to write the whole thing in assembler.

    Concerning memory: Forth is great for logging. With a couple resistors you can make a microSD adapter into a cheap SD slot, Propforth can read an write to this on the fly. SD access is done with very low overhead (no FAT support) so the transfer is VERY fast. In the propforth model, the SD can be seen as system ram (and storage), and the HUB and COG ram can be seen as "cache" (but maybe you need a good imagination for this image to work). When you do need to have SD with FAT, you either export the data to an external system, or simply install a second SD with FAT support, and arrange your processing at allow the slow transfers to FAT.

    Concerning I/O lines and processing: you can easily add additional prop chips to the initial propforth set up, the connection is transparent to the application, you just have six more cogs and 26 more pins available for you application. The synchronous serial connection has the protocol built in, and the transfers happen at pretty much as fast as the prop can handle, so there isn't too much difference between local cogs and remote cogs. The additional prop chips need no additional EEPROM, of course you can add more for additional storage, logging, etc.

    Only draw back is that it is forth, and folks seems to either love it or hate it. Forth fell out of favor when very fast processors with insane amounts of memory became cheap, but we now have to deal with grotesque code bloat. Propforth and forth in general lends itself to simple elegance and maximizing the least necessary resources.

    I would use forth on any development project on a microcontroller, and I would use the prop for any intial development, since this combination can do pretty much anything any other uC can do, and I already have it. After the prototype is complete, the algorithms can easily be ported to another lower cost and more specialized uC (e.g TMS430) in a more generic environment (e.g C). This is a typical model for very fast development.
Sign In or Register to comment.