I am experiencing some strange problems in my arduino..
My sketch is big... It have about 28k and when I Run the freememory function, it returns me about 350 off free memory.
What happen is in my variables..
Example:
I have one (byte vscreen = 5) and when I print to my serial, the first 10 seconds aproximatelly it runs fine, bjt after that.. It returns to 0 and the arduino crashes.
And the problem happen with some other variables as well...
Hard to tell w/o seeing any of your code...
Are you doing any dynamic memory allocation and clearing (either manually with malloc and free, by using the String object, or something else)? Any array overruns? Using goto and letting the stack overflow? I could keep going. We really need to see code.
Sembazuru:
Hard to tell w/o seeing any of your code...
Are you doing any dynamic memory allocation and clearing (either manually with malloc and free, by using the String object, or something else)? Any array overruns? Using goto and letting the stack overflow? I could keep going. We really need to see code.
Actually I am using some String objects and not sure if Iam using dynamic allocation, the variables are declared globally like int value_1 =350..
cabecinhas:
Actually I am using some String objects and not sure if Iam using dynamic allocation, the variables are declared globally like int value_1 =350..
Could it be a memory problem?
Absolutely, the most common space-leak in fact. But that's guesswork.
cabecinhas:
the problem is with the vtom_beep (LAST VALUE)variable that losses its value that was supose to be 0.
There is no other place in code where I write into the vtom_beep variable..
The question is what writes to the variables next to vtom_beep. Sounds like you are overwriting something. Without all the code it is impossible to tell.