non-blocking-rtttl-arduino icon indicating copy to clipboard operation
non-blocking-rtttl-arduino copied to clipboard

Changing prog_uint16 to uint16

Open cefn opened this issue 11 years ago • 2 comments

John Cooper is reporting that he had to change the line...

const prog_uint16_t notes[] PROGMEM = ...to... const uint16_t notes[] PROGMEM =

...and this seems to be linked to version changes with Arduino as discussed here... https://github.com/logicalzero/gamby/pull/4

We need to decide which is the least nasty choice to make, and possibly use a macro to switch based on version number once we figure out where the issue is.

Note, the Arduino official doctrine is still to use the declaration as per our original http://www.arduino.cc/en/Reference/PROGMEM

cefn avatar May 03 '13 14:05 cefn

The preferred change may be from... const prog_uint16_t ...to... const unsigned int[] PROGMEM = ...or... PROGMEM const unsigned int[] =

...but needs testing. Worst of all it seems to depend on the OS which is running, since Arduino distributes a different compiler toolchain in each package.

cefn avatar May 03 '13 15:05 cefn

Hi, I am using the Arduino that comes with Debian wheezy 1:1.0.1+dfsg-7 so I think it's essentially 1.0.1 if that helps.

choffee avatar May 03 '13 15:05 choffee