[SOLVED] Support STM32L1 ?

Any other STM32 based boards
faweiz
Posts: 1
Joined: Mon Sep 07, 2015 4:12 am

[SOLVED] Support STM32L1 ?

Post by faweiz » Mon Sep 07, 2015 4:22 am

Hello!

I've a Stm32L152C-Discovery board, does the Arduino_For_STM32 support this STM32L152RC chip? if so, how to support it on Arduino IDE?

Link: http://uk.farnell.com/stmicroelectronic ... 0000005178

Thank you!
Tony

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

Re: Support STM32L1 ?

Post by RogerClark » Mon Sep 07, 2015 6:52 am

None of the cores we have will support that device, however its possible that the new HALMX core that we are looking at building could probably be made to suport that device if the STMCubeMX supports it.

bgolab
Posts: 6
Joined: Wed Oct 14, 2015 10:02 am
Location: Krakow, Poland

Re: Support STM32L1 ?

Post by bgolab » Wed Oct 14, 2015 10:04 am

STM32L1 is supported by the STMCubeMX.

It would be nice to have this board supported.

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

Re: Support STM32L1 ?

Post by RogerClark » Wed Oct 14, 2015 8:52 pm

At the moment the new HALMX core development seems to be dormant.

i've not personally had any time to do any work on the HALMX core, and it doesn't look like anyone else has the time to push it forward either.

User avatar
sheepdoll
Posts: 241
Joined: Fri May 22, 2015 12:58 am
Location: Silicon Valley Vortex
Contact:

Re: Support STM32L1 ?

Post by sheepdoll » Wed Oct 14, 2015 10:05 pm

The HALMX core is not going to write itself.

I have another project at the moment which is AVR based. Others are happy with the STM32F103.

There seemed to be an interest that petered out when it was clear that HALMX is not a turnkey solution. Still there is enough where others can work with basic GPIO and serial stream. Sure that is boring, Even I want to jump forward and make the TFT and USB MIDI work.

In the HALMX project there is enough written in the docs based on the postings here to add a L1 to the cores, then get a GPIO blink and serial stream to run. If the docs are not clear, then it would be nice to get feedback as to how to make them better.

The way I structured HALMX is to use STMCube to do the heavy lifting. Understanding STMCube is a good first step. Especially if one of the demo boards is used as a starting place.

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

Re: Support STM32L1 ?

Post by RogerClark » Wed Oct 14, 2015 10:51 pm

Hi Julie,

See my PM.

I totally agree with you.

Cores do not write themselves.

You put a lot of effort into getting the groundwork done, but no one else seems to be willing to put any effort into this, and unfortunately I"ve been unable to do any work on this, as I've been away on business for the last month.

neofun
Posts: 1
Joined: Sat Jan 09, 2016 4:45 pm

Re: Support STM32L1 ?

Post by neofun » Sat Jan 09, 2016 5:22 pm

Hi Roger,
I'd like to program a STM32L151Cx wit he Arduino IDE.
I stumbled upon your posts in hackster.io and then arrived here...
Unfortunately it seems that the little difference between STM32L and STM32F as I got it from https://en.wikipedia.org/wiki/STM32 isn't that little at all - although they use the same Cortex-M3 core.
I searched the web and it seems that really nobody is currently trying to port the STM Arduino bootloader and/or the libmaple to STM32L - although I found several requests for that.
Would it be possible that you, with your experience in that area, could write up some tasks for the bootloader and maybe the libmaple which have to be addressed/programmed/solved, that it would easier for interested programmers to contribute to the STM32L support?
Unfortunately I'm more in hardware design and periphery programming than in core programming.
I appreciate your help.

Kind regards
Tom

User avatar
sheepdoll
Posts: 241
Joined: Fri May 22, 2015 12:58 am
Location: Silicon Valley Vortex
Contact:

Re: Support STM32L1 ?

Post by sheepdoll » Sat Jan 09, 2016 6:31 pm

neofun wrote: ...
I searched the web and it seems that really nobody is currently trying to port the STM Arduino bootloader and/or the libmaple to STM32L - although I found several requests for that.
...
Kind regards
Tom
Tom, welcome to this forum.

In some ways you are placing the cart before the horse.

In order to program a bootloader you need to have programming hardware. In the STM32 world this is called ST-Link which is a JTAG dongle. In the AVR world there are similar devices such as the AVR-ISP or Dragon programmer. While these devices use proprietary protocols, there are open source ports of the command line programming tool such as Texanne or OpenOCD for the STM32 and AVRDUDE for the Atmel products.

To install the bootloader into the bare metal chip someone needs to use one of these devices first. Bootloader programmed chips then need to be distributed. This takes time and resource. Most distributors are going to favor the most popular devices. Manufactures understand this, and make reference designs that are cheap and often "free" to the trade. In the case of ST, they include a limited St-Link which can be snapped off the demo board and used to program other chips.

The good news is that a few of use have managed to get Eclipse to run the toolchain which supports OpenOcd. This makes bootstrapping the bootstrap even easier. The middle ware of the STM32CubeMX USB tool has already written code to support a DFU uploader through HAL. In effect ST has already done the core programming. One just graphically sets the peripherals in the CubeMX program then generate all the core and library code.

HALMX, which is a variant, based on the core maple header files and data structures is a sort of glue to allow for the Arduino IDE to talk to the device programmer hardware. When the manufactures hardware dongle is used as in the case of the "Free" ST-Link, the IDE simply builds the code then calls the open source version of the tool that downloads the code. In this case no bootloader is needed.

While I have not dealt with the STM32L1xxx I did get a STM32L0 reference design board with an ePaper display at a tradeshow, this includes the ST-Link snap away section. It took me about 3 hours to configure the HALMX using the STM32CubeMX to access the serial USART and output a print stream. Same for a STM32F0 board I have.

The F0 board was interesting, in that I had acquired it from a ST seminar back in 2012 that was promoting the use of an Arduino like suite of tools (That were built on some now outdated libraries called the "Standard Peripheral Library." ) This provides a simple implementation of GPIO, Serial, And SPI. It also shows some of the mindset in the way that ST was looking at Arduino. It can also be seen how the F0 implementation of GPIO has evolved to become the "Arduino Headers" on the Nucleo Reference design boards. (Which also contain a "Free" snap away ST-link.)

The above is all the horse. Any of the above methods can be used like lego blocks to assemble a way to create something useful. The trick is to find the correct order that the lego blocks need to be placed to build the cart.

gevard
Posts: 4
Joined: Wed Feb 24, 2016 4:36 pm

Re: Support STM32L1 ?

Post by gevard » Sun Oct 02, 2016 4:39 pm

For information, Radino propose arduino products based on STM32L151. They call it Raduino32.
The link at the bottom of the page is the files to add to your Arduino installation.
I personnally never test it, as I don't have STM32L151 boards. But I appreciate your feadback.
Regards

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

Re: Support STM32L1 ?

Post by RogerClark » Sun Oct 02, 2016 8:59 pm

Interesting.

I will check if I have a L1 board kicking around that I could test it on

Post Reply