Quantcast
Channel: Reprap Forum - Firmware - Marlin
Viewing all articles
Browse latest Browse all 12089

Enabling #define RGB_LED results in compiler error

$
0
0
Hi, just downloaded 1.1 release as I wanted to RGB LED functionality. However, when I enable #define RGB_LED in Configuration.h and compile I get an error. Compiling with the define commented out is ok. It seems to be in Marlin_main.cpp, the errors are shown below. My coding skills are very basic so I'm not sure how to interpret these errors, but I suspect this is a single syntax mistake that cascades. My Arduino IDE is 1.8.2. Can anyone help me understand what to look for, please?

sketch\Marlin_main.cpp: In function 'void gcode_M190()':

Marlin_main.cpp:6890: error: expected 'while' before 'float'

         const float temp_diff = fabs(target_temp - temp);

               ^

Marlin_main.cpp:6890: error: expected '(' before 'float'

Marlin_main.cpp:6890: error: expected primary-expression before 'float'

Marlin_main.cpp:6890: error: expected ')' before 'float'

Marlin_main.cpp:6890: error: expected ';' before 'float'

Marlin_main.cpp:6890: error: 'temp' was not declared in this scope

         const float temp_diff = fabs(target_temp - temp);

                                                    ^

Marlin_main.cpp:6908: error: break statement not within loop or switch

           if (old_temp - temp < MIN_COOLING_SLOPE_DEG_BED) break;

                                                            ^

sketch\Marlin_main.cpp: At global scope:

Marlin_main.cpp:6914: error: expected unqualified-id before 'while'

     } while (wait_for_heatup && TEMP_BED_CONDITIONS);

       ^

Marlin_main.cpp:6916: error: expected unqualified-id before 'if'

     if (wait_for_heatup) LCD_MESSAGEPGM(MSG_BED_DONE);

     ^

In file included from sketch\Marlin.h:32:0,

                 from sketch\Marlin_main.cpp:223:

ultralcd.h:64: error: expected unqualified-id before ')' token

   #define LCD_MESSAGEPGM(x) lcd_setstatuspgm(PSTR(x))

                                              ^

sketch\Marlin_main.cpp:6916:26: note: in expansion of macro 'LCD_MESSAGEPGM'

     if (wait_for_heatup) LCD_MESSAGEPGM(MSG_BED_DONE);

                          ^

In file included from sketch\Marlin_main.cpp:223:0:

Marlin.h:358: error: expected unqualified-id before 'do'

   #define KEEPALIVE_STATE(n) do{ busy_state = n; }while(0)

                              ^

sketch\Marlin_main.cpp:6917:5: note: in expansion of macro 'KEEPALIVE_STATE'

     KEEPALIVE_STATE(IN_HANDLER);

     ^

Marlin.h:358: error: expected unqualified-id before 'while'

   #define KEEPALIVE_STATE(n) do{ busy_state = n; }while(0)

                                                   ^

sketch\Marlin_main.cpp:6917:5: note: in expansion of macro 'KEEPALIVE_STATE'

     KEEPALIVE_STATE(IN_HANDLER);

     ^

Marlin_main.cpp:6918: error: expected declaration before '}' token

   }

   ^

exit status 1
expected 'while' before 'float'

Viewing all articles
Browse latest Browse all 12089

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>