/var/www/restricted/ssh/stm32/www/stm32circle/ STM CircleOS forum / sprintf problem

Username:     
Password:     
             

Forum

# 1   2008-03-25 12:32:15 sprintf problem

gui.isep
New member
Registered: 2008-02-13
Posts: 2

sprintf problem

Hi!

When I try to use sprint function, the compiler software RIDE gives me an error..

Anybody know why?

This is the extract of the code:

#include <stdio.h>

...

void main()
{
char str [50];
int v=154; (for example)
   
  sprintf(str,"%d", v);

...

}


The error is:


"  C:\Documents and Settings\Guilherme\My Documents\STM32\I2C_Circle\objdebug\I2C_Circle.elf.ld:9: undefined symbol `!!!!!!!!! FLASH IS FULL !!!!!!!!!' referenced in expression 
collect2: ld returned 1 exit status 
 
Build failed  "


Best regards!

Offline

 

# 2   2008-03-25 12:49:33 sprintf problem

lionel
Member
From: Grenoble, France
Registered: 2007-07-24
Posts: 71
Website

Re: sprintf problem

"Flash is Full".

The linker script provided with a CircleOS app defines a limit at 8KB so that the CircleOS+app size does not exceed 23K. This limitation is set so that you can debug your app. But CircleOS apps can be greater than that, so you should edit the linker script.

Apart from that, if you define the function main(), it means to me that you are not using the CircleOS.
In that case, don't select the STM32F103RBT6_CircleOS pseudo-device when creating the project, but rather the STM32F103RBT6.

You will be given the standard linker scripts automatically generated by Ride7.

Lionel

Offline

 

# 3   2008-03-25 14:20:37 sprintf problem

gui.isep
New member
Registered: 2008-02-13
Posts: 2

Re: sprintf problem

Lionel,

Thank you for having responded to my post. Another question... How can I change the limitation for 23Kb? I changed the Circle_App.ld file but each time I compile my program, the RIDE software change it to the original size (8K) :-(

Best regards

Offline

 

# 4   2008-03-25 16:02:57 sprintf problem

lionel
Member
From: Grenoble, France
Registered: 2007-07-24
Posts: 71
Website

Re: sprintf problem

I don't understand what is going on. Can you send us your zipped project ?

thanks
Lionel

Offline

 

# 5   2008-03-26 09:58:31 sprintf problem

tybos
Member
Registered: 2007-08-07
Posts: 22

Re: sprintf problem

I got the same issue and solved it this way.

Offline

 

Board footer