STM8 Core

Arduino on the STM8 (8 bit processor)
Posts: 63
Joined: Wed May 11, 2016 4:29 pm

Re: STM8 Core

Post by dannyf » Fri Jul 07, 2017 12:43 am

ST is said to introduce STM8S001 soon, a 8pin device. Maybe a good replacement for 12F675.

Posts: 1
Joined: Sun Oct 02, 2016 11:40 pm

Re: STM8 Core

Post by MarkB » Mon Jul 17, 2017 5:47 pm

I've been playing with STM8 a bit over the past year and thought I might add a few observations.

1) I wouldn't call STM8 "obsolete" as it's one of the newest 8-bit microcontroller families on the market. It also seems to be very widely used.

2) Peripheral set is very similar to the STM32 line. This is helpful for those who might want to move back and forth between the 32 and 8 bit world.

3) The core runs at 1.8 V. This gives relatively low power at full speed, that is, the guaranteed clock speed does not roll off with voltage as does AVR. The MCU will tolerate a wide range of input voltage (2.95 - 5.5 V for STM8S) which is nice for running off unregulated battery. STM8L runs at lower voltage (1.65 - 3.6V). The I/O pin voltage are relative to Vdd.

4) Software/community support isn't anywhere near comparable to Arduino / AVR or for that matter PIC or MSP and so forth. I started with one of the commercial (but free for personal use with size restrictions that aren't relevant for the value-line STM8 products) compilers from IAR and have used the STM/COSMIC compiler as well. Both are full featured commercial grade products with a steep learning curve, but include (via STLINK) in circuit debugging tools, simulators, and such.

5) SDCC the open source compiler supports STM8 but documentation is pretty thin and it's hard to find example code. There is no open source support for debugging tools, but there are recent rumors of a project to do so.

6) I've lately been playing with an eForth port that supports compile to flash, interrupts, a periodic background task, "software serial", and "board support packages" for a number of cheap Chinese STM8 boards. As "hacker projects" go the code and documentation are quite good.

7) I haven't used it, but there exists an Arduino-like library for STM8/SDCC that is supposed to allow programming using Arduino paradigms. ... s/ Edit 2 (better link for Sduino):

Edit for addition observations per previous post:
a) There's no such thing as 8-bit ARM regardless of what eBay vendors say.

b) There are STM8 variants that have DMA, but the low-end STM8S103F3 or STM8S003F3 boards common on eBay don't have DMA.

c) Minimal circuit configuration for STM8S is MCU and 3 capacitors (Vdd bypass, Reset, and Vcap (1.8V core voltage)) using internal oscillator.
Last edited by MarkB on Tue Jul 18, 2017 2:36 pm, edited 1 time in total.

User avatar
Posts: 446
Joined: Mon Apr 27, 2015 2:28 pm
Location: Mt.Etna, Italy

Re: STM8 Core

Post by zoomx » Tue Jul 18, 2017 6:46 am

thanks for your review!

Posts: 63
Joined: Wed May 11, 2016 4:29 pm

Re: STM8 Core

Post by dannyf » Thu Jul 20, 2017 10:10 am

used the STM/COSMIC compiler as well.
STVD is a dog, ugly as hell.

there is an unlimited cosmic available on github. the morality of using it may be questionable to some, however.

I use IAR. it is simple, intuitive and very utilitarian as well. the beauty of it is that you can use the same IDE across most MCUs that I touch. couldn't have been happier with it.

User avatar
Posts: 6102
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia

Re: STM8 Core

Post by RogerClark » Fri Jul 21, 2017 10:33 pm

Can you post the link to the compiler on GitHub

I looked on STMs website about the compiler for STM8 and it seemed to be a free download, of what I presume is the compiler from Cosmic.

I looked on Cosmic's site and the STM8 compiler was available for free download, however there was some wierd legal stuff about it being only a 1 year license, albeit which they said was renewable.

I dont know if the compiler checks the date and time or whether the license duration is just from a legal standpoint.

BTW. Cosmic seem to have a compiler for the STM32 as well, but as STM official use gcc e.g. That's what the CubeMX is compatible with, I don't know who would use the Cosmic compiler for STM32

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest