ricmoo / QRCode

QR code generation library in C, optimized for low-power devices, such as Arduino.
Other
638 stars 202 forks source link

The code consumes a significant amount of Stack and Heap memory! #40

Open electrosaeed opened 4 months ago

electrosaeed commented 4 months ago

I'm using this library on STM32 and Keil. I encountered an issue when trying to generate QR codes above version 8. After some experimentation, I discovered that it requires additional Heap and Stack memory. Currently, with 12KB of Stack and 4KB of Heap memory allocated, I am able to generate QR codes up to version 13. However, for higher versions, more memory is needed, which I currently lack. I attempted to set LOCK_VERSION to 14, but it did not resolve the issue. Is there a way to optimize memory usage and reduce consumption?

photo_2024-03-16_12-45-38 This image is for version 13 on a thermal printer.