Difference between revisions of "Gb.getFreeRam"
From Gamebuino Wiki
(creation) |
m |
||
Line 1: | Line 1: | ||
− | {{ | + | {{lowercase}} |
__NOTOC__ | __NOTOC__ | ||
== Description == | == Description == |
Latest revision as of 2014-05-20T21:04:56
Description
Returns the amount of free RAM in number of bytes by measuring the distance between he heap and the stack. Results are not really consistent as the measure is taken in a single place in the program, and it doesn't take in account background operations (interrupts). When your Gamebuino acts randomly, you're probably out of RAM. More info here: Memory optimization.
Syntax
gb.getFreeRam();
Parameters
none
Returns
int: the amount of free RAM in number of bytes