Monday, 06 September 2010
 
 
A+ | A- | Reset
Why BasicX Print E-mail
Monday, 03 January 2005
Article Index
Why BasicX
Microcontroller Options
Conclusions

This article explains why I choose the BasicX platform over other microcontroller platforms such as PIC, Basic Stamp etc.

Criteria

I recently got interested in working with microcontrollers. Some would say that I’m late to the party but I would say that I am entering a more mature market. Although I am a software engineer, what got me started in programming over 20 years ago was electronics and digital electronics. So with this background and experience I investigated the different options in the market. I wouldn’t say that I did an exhaustive evaluation but I did have some basic criteria in mind:

  • Programming should be in a high-level language such as Basic or C. Modern compilers are very good and programming in a high-level language is just so much more productive that there is little excuse to use assembly language programming. Supporters of assembly language programming say that it is more efficient but in most cases this is not noticeable and there shouldn’t be a big concern about running out of memory for modern microcontrollers. The other negative often quoted is performance. With a good chipset and compiler/interpreter again this shouldn’t be a problem. To me assembly language programming is trying to optimize too early – save it for the very rare occasions where it is warranted. In some circles it might be seen as the “macho” thing to do but smart programmers know better.
  • The programming language must support multi-tasking. Any real-world application of a microcontroller must support interrupts and multiple simultaneous tasks. A single-tasking environment becomes limited in a very short time once you want to start controlling things such as motors or displays while waiting for user input. In a single-tasking environment everything is held up while waiting for user input or at least waiting and timing out on user input.It surprised me how many microcontroller environments did not support multitasking and then others like Lego Mindstorms clearly saw the need for it.
  • Debugging of programs should be easy. Preferably I would like to single-step through my program to see what it is doing although this is sometime hard to achieve in a multitasking environment because of timing issues. At least there should be a “print line debugger” where I can see a running dump of variable or program actions.
  • Entry cost should be low both for the microcontroller and the tools. I wanted a low initial investment and didn’t want to spend hundreds of dollars on tools such compilers, simulators or in-circuit emulators (ICE). Or at least not in the beginning until I had some more experience and I knew more what I was looking for.
  • The microcontroller and development environment needs to support iterative development. It is the nature of experimentation or in fact developing any program that you need to start small and incrementally add function, testing as you go. Most microcontrollers only support a 1000 or 10,000 programming cycles which can be exhausted quite quickly. A better choice is that the program is loaded in RAM or EEPROM.
  • Entry cost should be low in terms of getting up and running. Programming was not going to be a problem as I have wide experience of multiple languages and environments, but the hardware side should also be easy. Futzing with programmers and moving the microcontroller to the test circuit was not an option. In-circuit programming was fine providing that the programmer was not expensive – see criteria 4.

 
All Content Copyright 2005-2009 Oak Micros. All Rights Reserved. See Terms and Conditions.
Powered by Joomla and osCommerce.