Hi I like the Adafruit_BusIO library for its almost zero-overhead abstraction of the I2C and the DAC chip MCP4725. As an embedded programmer of constrained hardware, I wonder why the library invokes the new operator in the code?
In other words, is there a strong reason not to modify the code like the following, in order to avoid malloc at run-time?
Hi I like the
Adafruit_BusIO
library for its almost zero-overhead abstraction of the I2C and the DAC chipMCP4725
. As an embedded programmer of constrained hardware, I wonder why the library invokes thenew
operator in the code?In other words, is there a strong reason not to modify the code like the following, in order to avoid
malloc
at run-time?