• I guess it could be a memory corruption issue? The new Espruino builds will automatically defragment memory if they have trouble allocating a Flat String, so ideally it wouldn't fail.

    But it's a bit frustrating not being able to get the backing string out of the ArrayBuffer - I was sure there was a way to do it, but it seems not...

  • The new Espruino builds will automatically defragment memory

    how new is new approximately? Days/weeks? Would it move e.g. inline C binary around? Or other flat strings so older E.getAddressOf is no longer valid? just asking, currently I take getAddressOf(x,true) immediately before calling native code and the code is position independent anyway so hopefully it does not matter. And there is no real multithreading so this should not happen when Inline C code is running(?) as you probably don't allocate stuff that could cause this defragmentation from interrrupt handler. I'll check for the memory corruption on other board with swd available, add same/similar code until it breaks.

About

Avatar for Gordon @Gordon started