Can you guarantee you never run out of ram? Or do you just restart regularly?
(I typically am to scared to even use malloc on a microcontroller...)
(I typically am to scared to even use malloc on a microcontroller...)
But MicroPython's gc is fairly simple and easy to reason with. We've gotten a lot of value out of two useful tools/techniques: 1) Rendering memory use over long periods of time (micropython.mem_info(1) will output a text representation of how memory is used). It's pretty obvious when memory use starts expanding. 2) Turning the gc off in key unit tests so we can be sure critical sections do not allocate (an exception will be raised if memory is requested from the gc).
But, of course, memory use in any embedded application is critical.