tunes: fix constness for _default_tunes

_default_tunes was marked as 'const char *' array, which means the data
of the array was not actually const and thus landed in the data section
(so in RAM instead of FLASH).
The size of the array is 64 bytes.
This commit is contained in:
Beat Küng
2018-03-29 13:57:18 +02:00
committed by Daniel Agar
parent d40d165b4b
commit 576f4e02da
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -38,7 +38,7 @@
#include "tunes.h"
// initialise default tunes
const char *Tunes::_default_tunes[] = {
const char *const Tunes::_default_tunes[] = {
"", // empty to align with the index
"MFT240L8 O4aO5dc O4aO5dc O4aO5dc L16dcdcdcdc", // startup tune
"MBT200a8a8a8PaaaP", // ERROR tone
+1 -1
View File
@@ -126,7 +126,7 @@ public:
unsigned int get_maximum_update_interval() {return (unsigned int)TUNE_MAX_UPDATE_INTERVAL_US;}
private:
static const char *_default_tunes[];
static const char *const _default_tunes[];
static const uint8_t _note_tab[];
static const unsigned int _default_tunes_size;
bool _repeat = false; ///< if true, tune restarts at end