"variable must be const" fix for Arduino progrem
Using the source from this link I got it to compile following these steps.




Before opening the sketch in the Arduino:


Rename TVB.pde to TVB.ino
Rename WORLDcodes.cpp to WORLDcodes.h






Open the sketch (TVB.ino) in the Arduino IDE





Edit main.h and change:

// The structure of compressed code entries
struct IrCode {
  uint8_t timer_val;
  uint8_t numpairs;
  uint8_t bitcompression;
  uint16_t const *times;
  uint8_t const*codes;
};


to:

// The structure of compressed code entries
struct IrCode {
  uint8_t timer_val;
  uint8_t numpairs;
  uint8_t bitcompression;
  uint16_t const *times;
  uint8_t const*codes PROGMEM;
};


That is, add PROGMEM to the codes line.





Edit TVB.ino and change:

extern PGM_P *NApowerCodes[] PROGMEM;
extern PGM_P *EUpowerCodes[] PROGMEM;
extern uint8_t num_NAcodes, num_EUcodes;


to:

#include "WORLDcodes.h"


This avoids some linker problems in the original code.





Edit WORLDcodes.h and delete the line:

 #include "main.h"






Continue editing WORLDcodes.h and change:

const struct IrCode *NApowerCodes[] PROGMEM = {


to:

const struct IrCode * const NApowerCodes[] PROGMEM = {




And also change:

const struct IrCode *EUpowerCodes[] PROGMEM = {


to:

const struct IrCode * const EUpowerCodes[] PROGMEM = {



It should now compile OK.