Arduino vs. Maple – early impressions

Arduino Technology
Arduino vs. Maple – early impressions


For those that haven’t heard, LeafLabs’ Maple board is an Arduino-compatible microcontroller platform based on an STM32 ARM Cortex-M3 chip. The full feature list includes –

  • Microcontroller: STM32 F103RB
  • Clock Speed: 72 MHz
  • Operating Voltage: 3.3V
  • Input Voltage (recommended): 3.0V-18V
  • Digital I/O Pins: 39
  • Analog Input Pins: 16
  • Flash Memory: 128 KB
  • SRAM: 20KB
  • 64 Channel nested vector interrupt handler (including external interrupt on GPIO’s)
  • Integrated SPI/I2C and 7 Channels of Direct Memory Access (DMA)
  • Supplies up to 800mA @ 3.3v
  • Support for low power and sleep modes (<500uA)
  • Dimensions: 2.05″x2.1″

I recently got my hands on one of these new boards, and although a fully-functioning version of the Maple IDE has yet to be released, I compiled available source files from the project’s repository, allowing me to upload a sketch from Windows XP (via Parallels on OS X).

My example sketch uses the shiftOut function to create a sine waveform via an MCP4921 DAC chip. I also ran the same test setup on an Arduino Duemilanove (ATMega328p) and superimposed the two resulting signals for the sake of comparison –

arduinoVSMaple-sine.jpgArduino Duemilanove (ATMega328p) in blue, LeafLabs Maple (STM32F103RB) in green
Note – differing voltage ranges due to difference in DAC VREF (5V, 3.3V)

As expected, Maple’s STM32 (running @ 72MHz) updates the DAC a whole lot faster than Arduino’s ATMega328p (@ 16MHz) – in fact about 9 times faster! This was a bit of a surprise to me as I’d only expected a 4.5x speed boost considering the difference in clock speeds. Definitely good news for Arduino users in need of extra clock cycles, but for most, the Duemilanove still offers big advantages – specifically:

  • Maple IDE software still in prerelease development stage
  • ATMega328p available in easily replaceable DIP package
  • Lower-level code (i.e. – port manipulation, timer interrupts) used with Arduino would need to be rewritten for the STM32
  • Arduino widely available in multiple forms, great big user community

In any case, it’s very cool to see more options (and speed!) made available to the Arduino community. It’ll definitely be interesting to see how things progress with the Maple and its slated relatives.

Discuss this article with the rest of the community on our Discord server!