cancel
Showing results for 
Search instead for 
Did you mean: 

uClinux on STM32

awesten
Associate
Posted on November 17, 2009 at 18:36

uClinux on STM32

#stm32-uclinux-bootloader
40 REPLIES 40
kjepsen9
Associate II
Posted on May 17, 2011 at 12:16

Hi,

My board is up running...

Know i just need to learn uC linux...

How to get more drivers into it?

Kasper

tarm
Associate
Posted on May 17, 2011 at 12:16

Thanks STOne-32!

This is very exciting. This will let the stm32 span the whole range of embedded systems that interest me from just above 8-bit on the price and power side, to embedded linux systems with ethernet etc on the other. Having all those options in one family is fantastic.

I realize this is just a preview release, but I am very curious about it. I loaded it up and looked around. It still looks pretty basic with just a kernel and bare-bones busybox. Getting the image that small is very impressive! I assume you are basing your changes on Catalin Marinas's CM3 linux tree? How much additional modifications did you have to do to get it to boot? You seem to have drivers for GPIO, LCD, and USART. What additional peripherals do you intend to make drivers for?

One request though. Please push your linux modifications upstream as soon as you can. It is frustrating to have embedded platforms that are not upstream and only older kernels available from the manufacturer (or even more difficult, third party ''partners'') and they get old and stale very fast. If you can get the changes upstream, you will be doing your customers and yourself a big favor (from a maintenance perspective).

Thanks,

Tarm

16-32micros
Associate III
Posted on May 17, 2011 at 12:16

Hi Tarm,

Quote:

I realize this is just a preview release, but I am very curious about it. I loaded it up and looked around. It still looks pretty basic with just a kernel and bare-bones busybox. Getting the image that small is very impressive! I assume you are basing your changes on Catalin Marinas's CM3 linux tree? How much additional modifications did you have to do to get it to boot? You seem to have drivers for GPIO, LCD, and USART. What additional peripherals do you intend to make drivers for?

Thanks for the comments :) , Yes we started from Catalin Marinas's CM3 linux tree for the Cortex-M3 support and we have fixed some minors issues inside the Core then we build our own blocks and drivers especially for the UART and Clocks to enabled the boot. We are not planning to add more drivers from the time being however we will post the full source codes to give them to the Open community as starting point with STM32 to be enriched and developed by Linux /uclinux funs...

Quote:

One request though. Please push your linux modifications upstream as soon as you can. It is frustrating to have embedded platforms that are not upstream and only older kernels available from the manufacturer (or even more difficult, third party ''partners'') and they get old and stale very fast. If you can get the changes upstream, you will be doing your customers and yourself a big favor (from a maintenance perspective).

Thanks for the push, Yes it is planned once we get a proper and stable version to be uploaded to the www.uclinux.org

Our current build is based on the Original ''uClinux project page''

http://www.uclinux.org/pub/uClinux/dist/uClinux-dist-20080808.tar.bz2

which is the latest stable version of uClinux which implements the Linux kernel 2.6.26-uc0.

You also need the uClinux distribution update patch file:

http://www.uclinux.org/pub/uClinux/dist/patches/uClinux-dist-20080808-20090112.patch.gz

Cheers,

STOne-32.

slawcus
Associate II
Posted on May 17, 2011 at 12:16

I see no practical use of uClinux on STM32. This micro was not designed to run such OS. Big, slow, CM3 is not optimized to run from EMI.

I don't even see any practical use of uClinux on any micro. You always need external memory to store it and to run it. Why not real Linux instead?

The only part you need to change is micro with MMU. Price for such micro is basically the same to one without MMU.

Posted on May 17, 2011 at 12:16

Hi,

There is a lot of myths about linux (including uClinux. which is a version without MMU). The best thing about linux IMHO is it's networking part, the worst it's requirements for resources. Does it fit into embedded systems?

People will always try even to show, that they can.

Considering, that it is not practical to use internal flash and RAM with STM32 today, due to it's slow speed, the use of uClinux is questionable.

I use beagleboard for embedded linux and I use STM32 for embedded projects withot OS.

Another option to consider by ST is to include RTOS together with libraries into internal ROM (see Luminary Micro)

Regards

Jan

varun
Associate II
Posted on May 17, 2011 at 12:16

Quote:

On 24-07-2009 at 20:54, Anonymous wrote:

Dear all,

The implementation is running from the External Memories on the STM3210E-EVAL board Connected to the FSMC (Code is in External Flash and Data is in the external RAM),

Here attached the binaryfiles on how to get started step-by-step :

1) ''kernel_boot_loader.hex'' to put in into internal Flash using the ST Flash loader demonstrator into the flash, move boot jumpers to ''system Memory Mode'' before this operation.

2) Once done ( This bootloader is a version of DFU modified), Put again the jumpers to boot from user flash.

3) Connect USB cable to your PC and with ''DFuSe Software'', reset the board while maintaining the Key button pushed, Then upgrade the attached ''uClinux_on_stm32.dfu.dfu'' file.

4) Connect a RS232 Cable to Hyper-terminal on your Windows PC to USART1 on board and choose this connection : 19200 , 8 data, Parity ( None) , Stop Bit (1) , No Flow control

5) Reset the Board again to boot on µClinux

-> You should be able to see the Boot process

6) Here you go, You can play several commands :

''ls -l'' -> To see the root files system

''cat /proc/meminfo'' -> To see the memory usage

''ps'' -> To see the running processes

''kill -TERM 15'' -> End the task having the PID 15 (Led_Show application),

''ps'' -> To see the running processes after previous operation

''echo T > /dev/gpioF6'' ->This will switch the status (On/Off) of the first LED (LD1) connected to GPIO port F pin 6.

''echo 0 > /dev/gpioF6;echo 0 > /dev/gpioF7;echo 0 > /dev/gpioF8;echo 0 > /dev/gpioF9'' -> this will force all GPIOs Leds to be switched off.

Enjoy it ... And let me know your impressions and feedbacks :)

Cheers,

STOne-32.

It has been almost the end of summer, still st website doesn't tell anything about uclinux porting, pls. tell me are there any official plans to release the same.

Currently I am having STM3210B-Eval kit which contains STM32F103VB. Since FSMC is available only with high-density variants, I have no scope left, to try out uclinux on the same board. But still is there any provision to do that, I mean, if I replace the chip with a higher variant in the same board and put necessary circuit for external memories?

If not than I have to go for STM3210E-Eval, as suggested by you, but again I would expect the ported uclinux for the same to be available with it.

Regards,

Varun

adrian239955_st
Associate
Posted on May 17, 2011 at 12:16

Hi STOne-32,

I am wondering how deep the MPU of the STM32 is implemented in your uClinux porting.

I understand that there is no VM possible without MMU, but the MPU is meant to help protecting RAM sectors used by various parallel processes. On another page I read that the MPU only is able to seperate Kernel from User Space.

What is the case? And, if you compare to a Linux solution with MMU, how crucial do you think the security issue is?

Regards,

Adrian

PS: And yes... when can we get the porting from the ST webpage...? ;)

yonanir
Associate
Posted on May 17, 2011 at 12:16

Hello

Can st32m107 board can run ucLinux?

yonanir
Associate
Posted on May 17, 2011 at 12:16

stm32f107...

ekawahyu
Associate
Posted on May 17, 2011 at 12:16

Hi STOne-32,

Where can I get the source code of kernel_boot_loader.c from ST website?

Thanks