Blank sketch takes up 466 bytes???

Anyone have any ideas why this is happening?

Thanks,
baum

You sure that isn't the size it should be? Because I'm getting the same compiled size.
466 bytes is under half a KB, just saying...

apart from calling your empty code, it has quite a lot of housekeeping to set up, in case you use resources, like pins!

edit: it does housekeeping, you have to manage your own hose keeping!

So even if I don't use a certain function, it may still be compiled? In that case I may compile some of my code myself with avr-gcc and just include avr/io.h...

baum

not quite
but the i/o systems and timers have to be initialised

baum:
So even if I don't use a certain function, it may still be compiled? In that case I may compile some of my code myself with avr-gcc and just include avr/io.h...

baum

Are you expecting your sketch to consume enough flash that it'll be an issue?

You have code for setup and loop. The compiler still has to set those things up as well as setting up the normal environment stuff. No big deal, its a "problem" anytime you use a high level language. Minimal code for a stepper driver I wrote was 1200 bytes in C and 88 bytes in assembler. The compiler is setup for doing something useful and there is some overhead because of that. If you want to create an empty program, Oh well, your are going to see some of that overhead. There is a lot of register pushing and popping whenever a function is called along with other code that is just there to make things work.

OK. I'll try it w/out Arduino and see what the size of my program is... Thanks for the help!

baum