stm32f103rbt6 - loss the value of variable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
2016-09-18 02:57 PM
Posted on September 18, 2016 at 23:57
Hi,
I have a strange problem. If I write code like this:#include ''stm32f10x.h''
floattest;
intmain(
void) {
while(1) {
test=test+0.01; } } and display variable test in STM Studio I see that this var go to value about 2,500 and after that sets to 0 and again in loop. If I write that code:#include ''stm32f10x.h''
inttest = 0;
intmain(
void) { test = 0;
while(1) {
} } and try change a var by STM Studio to for example 2, I see the value 2 about 0,5s, after that it sets to 0. It is strange for me and I dont understand it. Where is the problem? I use CooCox.
0 REPLIES 0
