Thanks to the Arduino, Atmel’s SAM line of ARM microcontrollers are seeing a lot of use as 32-bit learning tools. For his Hackaday Prize project, [Jeremey] is using one of these chips without all the Arduino drama. He’s built a tiny Atmel SAM dev board that’s cheap, simple, and interestingly for a 32-bit ARM board, easy to program.
For this board, [Jeremy] is using Atmel’s SAM D09, the smallest member of the family that also includes the chip on the new Arduino Zero and the Arduino M0 (built by the other Arduino). The MiniSam-Zero uses a slightly smaller chip with 8 kB of on-chip Flash. Eagle-eyed complainers will notice the SAM D09 does not have internal EEPROM, so an EEPROM is added on-board. Also on board is a temperature sensor and a Silicon Labs CP2102 for serial communications.
That last chip – the Serial USART – allows for a rather interesting build if the firmware is done right. Instead of futzing about with ARM SWD while programming the device, a serial bootloader would allow anyone to plug a USB cable into this board and upload code straight from an IDE. This is perhaps the coolest feature of the MiniSam-Zero, and something [Jeremy] has worked tirelessly to get right. He can upload directly from Atmel Studio, and after a bit more work, [Jeremy] will be able to program this board directly from the Arduino IDE. That’s great work, and although this board isn’t as capable as other ARM microcontroller offerings, it’s still a fantastically useful device.
Yeah, later for the Arduino drama.
https://hackaday.io/project/10208-winxi-arduino-zero-pro-m0-stick-atsamd21e18
https://hackaday.io/project/10210-dixi-arduino-sam-d11-usb-stick
With the USB capable STM32’s they have both DFU USB & serial built-in rom bootloader. To activate it bootloader mode simply pull the BOOT0 pin high while in RESET( RESET pin low). Adding a push button with a pull down resistor to the BOOT0 pin is all you need…in addition to the reset button with pull-up on the RESET button…but that RESET circuit should be there anyway. . Programming over the bootloader can be easily accomplished with the PC-based ‘dfu-util’ or ‘stm32flash’ cli tools.
Correct. I wonder as well why he messes with a bootloader here. Even the DIY-friendly LPC1114FN28 has one. There’s just no unified uploading tool like ‘avrdude’ to deal with all the chips with one binary.
I think it is atmel’s philosophy to not have a ROM bootloader. They do have SW bootloaders for most of the devices which you can also configure to your needs and an app to load the code. As I use them mostly for hobby, I normally spend most time with the debugger attached, however I understand the need for one if you are going to sell boards as stand alone.
There are people however who would not consider using a built in bootloader for security reasons.
Awesome, thanks for the article! The chip actually has 16kb NVM, and the bootloader works with a python frontend. Trying to get it to play nice with the arduino IDE is fun.. I just cracked the bootloader down to < 1.5kb with advanced options turned off.
Also the ST32's are nice, I have a few dev boards based around them. I wanted to break away from the 8-bit avr's and instead of torturing myself with a samd21 I figured I'd torture myself with a samd09. Only problem was there were no serial bootloaders for them, at least that I could find available on the internet. So with some debugging sessions provided by a few friends on hackaday.io I made one. I find that if i torture myself just right I learn more :)
Also to answer most questions I’m sure will pop up. I wanted to learn the hard way, it’s the only way that seems to keep information in my head. That’s why I chose a samd09 and to create a serial bootloader. Now I’m off to bitbang i2c and SPI ;) (joking or not?)
I don’t get this “minimalist” style of design. Why go for a super small micro that needs external eeprom, external usb-serial adapter. Just use a SAMD21 which has more stuff anyway and bigger code space and USB programming if this is what you want.
nice, but is price really the point of it?
because I doubt its $2 ‘Blue Pill’ STM32F103 cheap http://www.cnx-software.com/2016/05/17/bluepill-is-a-2-arduino-compatible-development-board-based-on-stmicro-stm32-mcu/
I’m sure that keeping price of the board low is a priority, even if really…’nothing’ can compete with the price/performance ratio of the blue pill..except maybe the ESP8266. I imagine the main goal was the learning exercise (developing the board/circuitry testing e.t.c) and the development of a functional bootloader. If the design is to go commercial and the price can remain below $12, it might just have an audience.
“Performance” can have many metrics. If low power is one of them, it will be better than the blue pill.
one thing I would love to see in the IDE saga…
An IDE which has:
-> simple view :just like the Arduino IDE. keeping it dirty and simple for a prototype
-> advanced view :like the full blown IDE which allows me to muck around in C and ASM when I need to do things myself…
is that even possible? ever??
or should I be simply using two different IDEs? one Arduino and another full fledged IDE….
I suppose you could use either the arduino IDE or program an arduino in atmel studio?
Atmel has incorporated the Arduino environment into atmel studio 7 to make the transition from the Arduino IDE to Atmel studio 7 less of a burden.
I found it useful, thatso the environment I used for my Micro numitron clock. Now I only use the Arduino ide to quickly test arduino compatability.