You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Conservatively assuming 20 characters per G-code command, 1,000,000 G-code commands would require roughly 72 + (37+20*7+8 )*1000000 bytes = 185000000 bytes = 185 MB for _buffer and another 185MB for the responses list (for calculation see https://code.tutsplus.com/tutorials/understand-how-much-memory-your-python-objects-use--cms-25609 ). If it is possible to replace those lists with ring buffers, that would be a nice change.
The following loop that simply moves back and forth will slowly consume more and more memory, presumably until it crashes.
The problem is that the
Printer
class is storing every line ever sent in_buffer
and doesn't clear it out until disconnecting.The text was updated successfully, but these errors were encountered: