Squeezing Squirrel

I haven’t written a lot of code for the imp on my desk, yet I notice that the program storage used is already creeping up. To compare it to an earlier version of code, I commented out large sections of the source, only to find that the program storage used didn’t change! Does this mean that the raw source is stored in the imp device? I had thought that there’d be some sort of preprocessing of the Squirrel code, prior to downloading it. Has anyone given consideration to a pre-download “squeeze” of the Squirrel code, to ensure that limited space is used most efficiently? I’m not yet close to running out of code space, but I may have to rethink coding in a verbose form if I find that /comments/ also count as program space.

Comments don’t count as program space. Either you weren’t measuring what you thought you were, or the program-space display – which is a fairly new feature – isn’t showing quite the right thing.

Peter

That’s what I would have thought. I wrote a short program and your IDE reported 2.65% of program space used. I commented out most out of it. And it still reported 2.65%. It’s possible I could have made a mistake with the log, as it doesn’t update properly (needs constant refreshing, can’t be cleared and wraps around). So, I’ll try again and report my findings.

OK, I’ve retested it. The IDE Log reported my code as “2.72% program storage used”. I then commented out 50% of it and rebuilt it. The IDE Log reported “2.73% program storage used”!!! The extra 0.01% would be the /* and */ I added.

On a related note, have you considered a public-access bug tracker for Electric Imp?

It strikes me that you have an enthusiastic and supportive user base already. Using Jira or Bugzilla to expose existing issues and feature requests would lighten the load on the forum and allow it to focus on discussion. Meanwhile, a bug tracker allows developers (within Electric Imp and outside of it) to easily identify and monitor known issues, track releases etc.

The bug has been fixed on that - the IDE was reporting source size vs object size. Oops.

We have used Jira in the past but went back to pivotal so we can mix bugs, tasks, chores etc and prioritize between them. This makes public access a bit tricky as pivotal doesn’t really do that.