Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training




Loading

STM32 and FreeRTOS

Posted by Kitt Bennts on March 10, 2013
Hello,

I have a problem with the CORTEX_STM32F103_IAR Demo example of FreeRTOS.
The OS works well , however the low level packages are dirrerent from the samples that ST Semiconductor has published.
For example, the file stm32f10x_can is different in the FreeRTOS example from the Original ST examples.
The problem is that I can't add to the free RTOS project the periphery level files from ST examples(the functions are different).

Is it possible to get a Demo CORTEX_STM32F103_IAR that based on the last ST template?
Can you please advice?

Kitt

RE: STM32 and FreeRTOS

Posted by Kitt Bennts on March 10, 2013
The CORTEX_STM32F103_IAR Demo ST BSP files is from 2006, the new ST BSP files is from 2011.

Kitt

RE: STM32 and FreeRTOS

Posted by Richard on March 10, 2013
Originally library files were stored in a 'common' area so demo projects referenced a core set of files that could be easily updated - however as the number of demos grew that soon proved unworkable. Now a fix baseline of drivers is included directly in the demo directory so a demo is guaranteed to work as provided.

The FreeRTOS files can be used with any STM32 project though - the core files do not make use of any library functions (and in fact work on all Cortex-M devices, be they STM32 or not). Only the demos use the driver libraries.

http://www.freertos.org/Creating-a-new-FreeRTOS-project.html
http://www.freertos.org/porting-a-freertos-demo-to-different-hardware.html

Regards.

RE: STM32 and FreeRTOS

Posted by Kitt Bennts on March 10, 2013
The Demo works fine, but if I want to look forward, to build a project with more peripheries (ADC,CAN,UARTS,INT,IIC,SPI etc), I will have problems avery time I will try to use the new ST examples.

Is it possible to add the FREERTOS files to an old project? I tried but it didn't work :-)

RE: STM32 and FreeRTOS

Posted by Jerry Durand on March 10, 2013
I do that all the time. You have to be careful to update EVERYTHING having to do with FreeRTOS.

I'm using Code Red tools (gcc based) and in my case that's everything in my FreeRTOS folder under SRC as well as the FreeRTOSConfig.h and cr_startup_lpc... that are in with the main files.

I copy the new FreeRTOSConfig.h file over and then change the settings to match the old one.

I leave the old cr_startup file there but compare it to the new one to see if there's anything I need to change. I do this because the demo files are normally for an older version of the tools than I use and they may also have things defined like interrupt vectors that are for a specific demo but I need them at the default handler or something else.

RE: STM32 and FreeRTOS

Posted by Kitt Bennts on March 11, 2013
Thank you very much.

I tried to add the FreeRTOS files to the STM32 old project, but when it runs it generates a reset when it goes to the assembler function:

vPortStartFirstTask
/* Use the NVIC offset register to locate the stack. */
ldr r0, =0xE000ED08
ldr r0, [r0]
ldr r0, [r0]
/* Set the msp back to the start of the stack. */
msr msp, r0
/* Call SVC to start the first task. */
cpsie i
svc 0

END

Can you please advice?

RE: STM32 and FreeRTOS

Posted by Richard on March 11, 2013
See item 1 here: http://www.freertos.org/FAQHelp.html

Regards.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists