Go Down

Topic: my 2¢ (Read 2 times) previous topic - next topic

Andrew

Maybe code rot would be helped (or at least the potential for it flagged up) by having some standard #defines or #pragmas in sketches. Say something like

Code: [Select]
#define CPU atmega328
#define IDE 0.19


then the Arduino code pre-processor could squawk if the values didn't match with the currently selected board/CPU and IDE version.

Something for the Arduino 1.0 suggestions thread?

Andrew

mowcius

#11
Aug 04, 2010, 11:03 pm Last Edit: Aug 04, 2010, 11:03 pm by mowcius Reason: 1
Quote
Something for the Arduino 1.0 suggestions thread?

Go on then ;)

I doubt it'll help. I don't think it'll get put in now, maybe in 1.0.1 :P

Mowcius

sonicj

Quote
I am paying 5 bucks a month, and only getting a TB of bandwidth

at 30k a sketch, thats only 36,650,387 downloads!

Quote
The trouble is, the code probably was legit when someone put it in the playground, but then three versions of the IDE later there's some incompatibility and it doesn't work anymore.

ahhh... i see!


Quote

Code: [Select]
#define CPU atmega328
#define IDE 0.19

then the Arduino code pre-processor could squawk if the values didn't match with the currently selected board/CPU and IDE version.

Something for the Arduino 1.0 suggestions thread?

Andrew

this seems like a brilliantly elegant solution! a fix of this sort would have a much further reach than just the playground as code posted outside of arduino.cc would also need to comply. 2 additional lines of code would be a small price to pay for instant, easily identifiable compatibility verification and would add to the overall quality of the platform!

again, just my 2¢ fwiw.
-sj

retrolefty

Quote
You give me 5 star rating or I no talk to you anymore!


Promise  ;)

sonicj

File Attachment Mod

quick reply box

quote and/or quick quote would be super too!


Go Up