From b657a18449356fb002199d17fbfc59fb21e8da0e Mon Sep 17 00:00:00 2001 From: MaikStohn Date: Fri, 4 May 2012 12:24:07 +0200 Subject: [PATCH] Revert "magic PROGMEM defines to avoid hundreds of wrong GCC warnings" This reverts commit 3682d9bd5b34bdc6560d97278d6d7eff3243bddc. --- Marlin/Marlin.h | 7 ------- Marlin/thermistortables.h | 14 +++++++------- 2 files changed, 7 insertions(+), 14 deletions(-) diff --git a/Marlin/Marlin.h b/Marlin/Marlin.h index 5982302da..5bb728c6f 100644 --- a/Marlin/Marlin.h +++ b/Marlin/Marlin.h @@ -20,13 +20,6 @@ #include #include -//do some magic defines in order to prevent hundreds of wrong warnings in gcc -//more info here: http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&p=646359 -typedef short prog_short PROGMEM; -#undef PROGMEM -#define PROGMEM __attribute__(( section(".progmem.data") )) -#undef PSTR -#define PSTR(s) (__extension__({static prog_char __c[] PROGMEM = (s); &__c[0];})) #include "fastio.h" #include "Configuration.h" diff --git a/Marlin/thermistortables.h b/Marlin/thermistortables.h index 0ac03d510..3071a6b5b 100644 --- a/Marlin/thermistortables.h +++ b/Marlin/thermistortables.h @@ -7,7 +7,7 @@ #if (THERMISTORHEATER_0 == 1) || (THERMISTORHEATER_1 == 1) || (THERMISTORHEATER_2 == 1) || (THERMISTORBED == 1) //100k bed thermistor -const prog_short temptable_1[][2] = { +const short temptable_1[][2] PROGMEM = { { 23*OVERSAMPLENR , 300 }, { 25*OVERSAMPLENR , 295 }, { 27*OVERSAMPLENR , 290 }, @@ -72,7 +72,7 @@ const prog_short temptable_1[][2] = { }; #endif #if (THERMISTORHEATER_0 == 2) || (THERMISTORHEATER_1 == 2) || (THERMISTORHEATER_2 == 2) || (THERMISTORBED == 2) //200k bed thermistor -const prog_short temptable_2[][2] = { +const short temptable_2[][2] PROGMEM = { {1*OVERSAMPLENR, 848}, {54*OVERSAMPLENR, 275}, {107*OVERSAMPLENR, 228}, @@ -98,7 +98,7 @@ const prog_short temptable_2[][2] = { #endif #if (THERMISTORHEATER_0 == 3) || (THERMISTORHEATER_1 == 3) || (THERMISTORHEATER_2 == 3) || (THERMISTORBED == 3) //mendel-parts -const prog_short temptable_3[][2] = { +const short temptable_3[][2] PROGMEM = { {1*OVERSAMPLENR,864}, {21*OVERSAMPLENR,300}, {25*OVERSAMPLENR,290}, @@ -131,7 +131,7 @@ const prog_short temptable_3[][2] = { #endif #if (THERMISTORHEATER_0 == 4) || (THERMISTORHEATER_1 == 4) || (THERMISTORHEATER_2 == 4) || (THERMISTORBED == 4) //10k thermistor -const prog_short temptable_4[][2] = { +const short temptable_4[][2] PROGMEM = { {1*OVERSAMPLENR, 430}, {54*OVERSAMPLENR, 137}, {107*OVERSAMPLENR, 107}, @@ -156,7 +156,7 @@ const prog_short temptable_4[][2] = { #endif #if (THERMISTORHEATER_0 == 5) || (THERMISTORHEATER_1 == 5) || (THERMISTORHEATER_2 == 5) || (THERMISTORBED == 5) //100k ParCan thermistor (104GT-2) -const prog_short temptable_5[][2] = { +const short temptable_5[][2] PROGMEM = { {1*OVERSAMPLENR, 713}, {18*OVERSAMPLENR, 316}, {35*OVERSAMPLENR, 266}, @@ -222,7 +222,7 @@ const prog_short temptable_5[][2] = { #endif #if (THERMISTORHEATER_0 == 6) || (THERMISTORHEATER_1 == 6) || (THERMISTORHEATER_2 == 6) || (THERMISTORBED == 6) // 100k Epcos thermistor -const prog_short temptable_6[][2] = { +const short temptable_6[][2] PROGMEM = { {28*OVERSAMPLENR, 250}, {31*OVERSAMPLENR, 245}, {35*OVERSAMPLENR, 240}, @@ -263,7 +263,7 @@ const prog_short temptable_6[][2] = { #endif #if (THERMISTORHEATER_0 == 7) || (THERMISTORHEATER_1 == 7) || (THERMISTORHEATER_2 == 7) || (THERMISTORBED == 7) // 100k Honeywell 135-104LAG-J01 -const prog_short temptable_7[][2] = { +const short temptable_7[][2] PROGMEM = { {46*OVERSAMPLENR, 270}, {50*OVERSAMPLENR, 265}, {54*OVERSAMPLENR, 260},