Removing the old serial libray:little Arduino hack

A little Arduino hack...

add a "/*" (without the quotes) to line 214 of file wiring.c (in the folder "lib\targets\arduino") and get an extra 400+ bytes of programming space! Oh and by doing this you can't use the Old deprecated serial library anymore (see for more info), but I think it's worth it, as the new Serial library is better.

I have been trying to work the most punch out custom libraries lately. Just when you think your code is optimized, you compile it and discover it's larger than your previous version.

One thing I discovered, it's usually better to use more memory for variables, than using more functions.



we might just drop the old library for version 5 maybe we should run a poll :)

I'm sure we can optimise quite a bit of code.... the linker is a very important piece of the whole system that we need to understand a lot better


For Aduino0005, since the old serial library was not removed, you have to remove it manually. Since the file wiring.c hanged slightly, you must add a "/*" (without the quotes) at line 217 (just before "void beginSerial(long baud)") That way, lines 217 to 320 are commented out.



thanks for the contribution!

remember that arduino 0005 doesn't exist yet :)

it's marked 0005 in the svn but we're still working on it


Oh! :o I recently reinstalled Arduino my Linux/Debian box, that's why version 0005.