The Null Device
Posts matching tags 'mbed'
Seen at Maker Faire: Two guys from ARM (the people who designed the CPU in your mobile phone and probably a dozen other devices you own) have designed an amazingly elegant new microcontroller prototyping board, for making electronic gadgets even more easily than with the Arduino. Called mbed, it consists of a board with a USB port and 40 pins. The pins do the usual things (analogue/digital I/O, USB, Ethernet, &c.), but that's not the impressive thing about it; the impressive part is the design of the whole system, which brings web-style agile development to microcontroller-based gadgets.
When you get an mbed, you plug it into your computer (which may be a Windows PC, a Mac, a Linux box or anything else which can mount USB drives); it then appears as a USB disk, containing one file: a web link. You go to the web link, which directs you to mbed's web site, where you log in or create an account; from then on, you have an integrated development environment in your browser, with source navigation, syntax highlighting and a compiler. Your code is hosted online on mbed's servers (the system uses the Subversion version control system as a store). Create a new project, and you get a "Hello World" program (written in C++) which, by default, flashes one of the mbed board's built-in LEDs. Hit the Compile button, and your browser soon prompts you to download a .bin file of the compiled program. Save it to the mbed card's drive, hit the reset button on it, and your program runs.
That's not all, though; the mbed card can work with a plethora of hardware modules, from Nokia-style LCD displays to GPS units, Bluetooth modems and more. Which is where the next bit of elegance comes in. There exists an ecosystem of modular classes for driving these various devices. To attach a supported device, all you have to do is add the class for it to your project (by pasting the URL of its Subversion repository into a dialog box; the IDE does the rest for you), instantiate it as an object and call its methods. For example, here is code for drawing on a Nokia-style LCD display:
This goes some way towards making building gadgets as easy as building web applications with a framework like Django or Ruby On Rails.MobileLCD lcd(p5,p6,p7,p8,p9); // the I/O pins lcd.background(0xffff99); lcd.foreground(0x000000); lcd.locate(2,2); lcd.printf("Hello world\n"); lcd.fill(0,64,128,128, 0xffffff);
mbed is somewhat more expensive than the Arduino (the price quoted was about £45 for the mbed board itself, whereas Arduino-compatible boards go for £13 or so). However, the elegance of the design, its ease of use and sheer niftiness could make it worth the price.