Powerful, Ultra-Cheap Microcontroller Board - STM32F4

626 views
Skip to first unread message

G Bulmer

unread,
Jan 24, 2012, 4:36:23 PM1/24/12
to Birmingham Hack Space
For folks who think Arduino is a bit weedy, have a look at the STM32F4-
DISCOVERY board at ST Micro:
http://www.st.com/internet/evalboard/product/252419.jsp

It s available for £9.96 from Farnell, and RS (i.e. about half the
price of an Arduino)
I believe this is a marketing promotion, so don't plan to buy them in
6 months time (I might be wrong, but manufacturers often put
development boards out to stimulate interest, but stop production once
interest has been stirred)

It's spec is a bit Bonkers:
- 1MByte flash
- 192KByte RAM
- ARM Cortex-M4 32bit processor with hardware floating point
- 168MHz
- It's a 100pin part, so lots of IO
- 3 x 2.4Msamples/second ADC
- Stereo DACs
- 2 USB interfaces
- lots of UASRTs, SPI, I2C, SDIO, ...

As if that wasn't enough, it comes with 'proper' Audio out (stereo
96KHz 24bit), a microphone, and a 3-axis accelerometer, as well as
some LEDs and a button.

It also has a proper USB/SWD hardware debugger on board (I am not sure
if OpenOCD support is released yet).

The standard software is a bit complex to use. It is intended for
engineers who want maximum flexibility, not ease of use, and really
requires you to read a 1315 page manual (RM0090)

BUT, as of yesterday, ala42 has released a *subset* of the Wiring
libraries (Arduino started with Wiring) for it!!
http://forums.leaflabs.com/topic.php?id=1268&page=2#post-7828

There are still problems.
For example, the manufacturers standard upload program only exists on
Windows. (That's a problem I and others are working on to fix.)
The board uses two rows of double row pins, which makes it harder to
get at signals than single row header sockets.

Summary: 10x faster, 30x more flash, 96x more RAM, 700x more ADC, HiFi
sound, and accelerometers for 1/2 the price of an Arduino.

Sarah Mount

unread,
Jan 24, 2012, 6:31:17 PM1/24/12
to birmingham...@googlegroups.com
Interesting! What are you going to do with it?

Sarah

> --
> You received this message because you are subscribed to the Google Groups "Birmingham Hack Space" group.
> To post to this group, send email to birmingham...@googlegroups.com.
> To unsubscribe from this group, send email to birmingham-hack-...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/birmingham-hack-space?hl=en.
>

--
Sarah Mount, Senior Lecturer, University of Wolverhampton
website:  http://www.snim2.org/
twitter: @snim2

G Bulmer

unread,
Jan 25, 2012, 4:13:06 PM1/25/12
to Birmingham Hack Space
There are several things I want to do, but the most obvious is sound
and music.

It has a reasonable quality audio output system (significantly better
than CD audio) that can directly drive headphones. It has a
microphone, and reasonable ADC inputs. It also has hardware floating
point.

So I am aiming to do some experiments to synthesise sound, play back
samples, apply effects, etc.

I still need to solve the upload problem, though.
> > For more options, visit this group athttp://groups.google.com/group/birmingham-hack-space?hl=en.

Ptolom

unread,
Jan 26, 2012, 4:34:09 PM1/26/12
to birmingham...@googlegroups.com
On 01/24/12 21:36, G Bulmer wrote:
> For folks who think Arduino is a bit weedy, have a look at the STM32F4-
> DISCOVERY board at ST Micro:
> http://www.st.com/internet/evalboard/product/252419.jsp
I would be so intrigued by that if I hadn't just got a Beaglebone. Going
use it as a server for controlling stuff wirelessly.

Ian Vaughan

unread,
Mar 8, 2012, 12:07:21 PM3/8/12
to birmingham...@googlegroups.com
Thanks Gary for this, I picked one up straightaway from RS. After hunting around I eventually found the QSTlink2 which runs under Linux and works well for the downloading via STLink V2. 

Since I run a x64 bit system I decided to compiler the Arm-Cortex M4 toolchain from source. After several attempts, I found an extremely useful make file hosted on Git along with various patches. After setting a number of options, the GNU C toolchain compiled flawlessly. 

Finally, I found an article of producing your first "Hello World" program with the arm-cortex m4 (the cortex m4 is considerably more complicated than the PIC and AVRs I've played with before). I copied the program, compiled it and downloaded it, and guess what, it ran first time.

I hope the above URLs are useful to others.

Ian 

Adrian Godwin

unread,
Mar 8, 2012, 12:38:08 PM3/8/12
to birmingham...@googlegroups.com
On Thu, Mar 8, 2012 at 5:07 PM, Ian Vaughan
<imva...@electrogadgets.co.uk> wrote:
>
>
> Thanks Gary for this, I picked one up straightaway from RS. After hunting
> around I eventually found the QSTlink2 which runs under Linux and works well
> for the downloading via STLink V2.
>
> Since I run a x64 bit system I decided to compiler the Arm-Cortex
> M4 toolchain from source. After several attempts, I found an extremely
> useful make file hosted on Git along with various patches. After setting a
> number of options, the GNU C toolchain compiled flawlessly.
>
> Finally, I found an article of producing your first "Hello World" program
> with the arm-cortex m4 (the cortex m4 is considerably more complicated than
> the PIC and AVRs I've played with before). I copied the program, compiled it
> and downloaded it, and guess what, it ran first time.
>
> I hope the above URLs are useful to others.
>
> Ian
>

Thanks Ian,

I bought a couple and haven't played with them yet, this will come in
very useful.

-adrian

G Bulmer

unread,
Mar 16, 2012, 10:24:46 AM3/16/12
to Birmingham Hack Space
If folks are willing to accept a slightly older toolchain (same
programs, just older versions), then there is a simple way to get the
tools

Download LeafLabs Maple IDE:
http://leaflabs.com/docs/maple-ide-install.html

They have a download for Windows, Linux and Mac.

Inside that download is the gcc toolchain, all the programs are
prefixed with arm-none-eabi-*, e.g. arm-none-eabi-gcc, (the whole set
includes gcc, g++, gdb, as, ld, ar objcopy, objdump).
There are versions without the 'long names' too, e.g. 'gcc', but I
avoid using them as I have programs with the same names installed
which compile for my Mac.

I use https://github.com/texane/stlink
for upload.

I have a github repo with an initial version of a 'Wire-like' library:
https://github.com/gbulmer/openstm32sw
based on work by 'ala42' a LeafLabs Maple user. I am modifying it so
that all of ST Micro's libraries work too.

I'll try to write a proper receipe on my blog http://ourduino.wordpress.com/

GB-)
> around I eventually found the QSTlink2 <http://code.google.com/p/qstlink2/> which
> runs under Linux and works well for the downloading via STLink V2.
>
> Since I run a x64 bit system I decided to compiler the Arm-Cortex M4
> toolchain <https://github.com/MikeSmith/summon-arm-toolchain> from source.
> After several attempts, I found an extremely useful make file hosted on Git
> along with various patches. After setting a number of options, the GNU C
> toolchain compiled flawlessly.
>
> Finally, I found an article of producing your first "Hello World"<http://jeremyherbert.net/get/stm32f4_getting_started> program

Gregory Fenton

unread,
Mar 16, 2012, 10:35:28 AM3/16/12
to birmingham...@googlegroups.com
As I read this I am in the process of fighting my way through the
google minefield looking for exactly this information.

It was great to meet you last night, my board should be with me in the
morning depending on how fast RS ship.

I apologise profusely, I believe I may have spelled your name
incorrectly as Gary rather than Garry (I found both variations of your
name when I looked).

Again, thanks for the session last night, it was incredibly interesting.

Best regards

Greg

Reply all
Reply to author
Forward
0 new messages