You are reading a single comment by @HughB and its replies. Click here to read the full conversation.
  • It's a hard one. I recently found an issue that caused NRF.setAdvertising to create a 'memory busy' error.

    If it helps: 'memory busy' means something running in an interrupt requested a new JS variable and one couldn't be provided because the main thread was using the variable store (most likely for Garbage collection).

    So... If you keep calling process.memory() which triggers a GC pass then it's far more likely that you get the error - things like the memory widget will do that a lot

  • Aha, Pastel calls process. memory every draw, 60 seconds, I did not realise it schedules a GC as well Is there a way to get current memory usage without triggering a GC? If not I will take this out of Pastel.

About

Avatar for HughB @HughB started