Explorar o código

Merge pull request #3633 from 3d-gussner/MK3_BETA_message

Remove BETA Warnings
3d-gussner %!s(int64=2) %!d(string=hai) anos
pai
achega
9f6d3e2c10
Modificáronse 8 ficheiros con 50 adicións e 39 borrados
  1. 2 2
      .travis.yml
  2. 2 0
      Firmware/Marlin.h
  3. 13 10
      Firmware/Marlin_main.cpp
  4. 3 0
      Firmware/messages.cpp
  5. 9 6
      Firmware/messages.h
  6. 4 4
      Firmware/temperature.cpp
  7. 16 16
      PF-build.sh
  8. 1 1
      build.sh

+ 2 - 2
.travis.yml

@@ -11,11 +11,11 @@ before_install:
 script:
   - cp Firmware/variants/1_75mm_MK3S-EINSy10a-E3Dv6full.h Firmware/Configuration_prusa.h
   - bash -x build.sh || { echo "1_75mm_MK3S-EINSy10a-E3Dv6full variant failed" && false; }
-  - bash -x build.sh EN_ONLY || { echo "1_75mm_MK3S-EINSy10a-E3Dv6full EN_ONLY failed" && false; }
+  - bash -x build.sh EN_FARM || { echo "1_75mm_MK3S-EINSy10a-E3Dv6full EN_FARM failed" && false; }
   - rm Firmware/Configuration_prusa.h
   - cp Firmware/variants/1_75mm_MK3-EINSy10a-E3Dv6full.h Firmware/Configuration_prusa.h
   - bash -x build.sh || { echo "1_75mm_MK3-EINSy10a-E3Dv6full variant failed" && false; }
-  - bash -x build.sh EN_ONLY || { echo "1_75mm_MK3-EINSy10a-E3Dv6full EN_ONLY failed" && false; }
+  - bash -x build.sh EN_FARM || { echo "1_75mm_MK3-EINSy10a-E3Dv6full EN_FARM failed" && false; }
   - rm Firmware/Configuration_prusa.h
   - cp Firmware/variants/1_75mm_MK25S-RAMBo13a-E3Dv6full.h Firmware/Configuration_prusa.h
   - bash -x build.sh || { echo "1_75mm_MK25S-RAMBo13a-E3Dv6full variant failed" && false; }

+ 2 - 0
Firmware/Marlin.h

@@ -386,7 +386,9 @@ void bed_analysis(float x_dimension, float y_dimension, int x_points_num, int y_
 void bed_check(float x_dimension, float y_dimension, int x_points_num, int y_points_num, float shift_x, float shift_y);
 #endif //HEATBED_ANALYSIS
 float temp_comp_interpolation(float temperature);
+#if 0
 void show_fw_version_warnings();
+#endif
 uint8_t check_printer_version();
 
 #ifdef PINDA_THERMISTOR

+ 13 - 10
Firmware/Marlin_main.cpp

@@ -828,30 +828,31 @@ void factory_reset()
 	}
 	KEEPALIVE_STATE(IN_HANDLER);
 }
-
+#if 0
 void show_fw_version_warnings() {
 	if (FW_DEV_VERSION == FW_VERSION_GOLD || FW_DEV_VERSION == FW_VERSION_RC) return;
 	switch (FW_DEV_VERSION) {
-	case(FW_VERSION_ALPHA):   lcd_show_fullscreen_message_and_wait_P(_i("You are using firmware alpha version. This is development version. Using this version is not recommended and may cause printer damage."));   break;////MSG_FW_VERSION_ALPHA c=20 r=8
-	case(FW_VERSION_BETA):    lcd_show_fullscreen_message_and_wait_P(_i("You are using firmware beta version. This is development version. Using this version is not recommended and may cause printer damage."));    break;////MSG_FW_VERSION_BETA c=20 r=8
+	case(FW_VERSION_BETA):    lcd_show_fullscreen_message_and_wait_P(MSG_FW_VERSION_BETA);   break;
+	case(FW_VERSION_ALPHA):
   case(FW_VERSION_DEVEL):
 	case(FW_VERSION_DEBUG):
     lcd_update_enable(false);
     lcd_clear();
-  #if FW_DEV_VERSION == FW_VERSION_DEVEL
+  #if (FW_DEV_VERSION == FW_VERSION_DEVEL || FW_DEV_VERSION == FW_VERSION_ALPHA)
     lcd_puts_at_P(0, 0, PSTR("Development build !!"));
   #else
     lcd_puts_at_P(0, 0, PSTR("Debbugging build !!!"));
   #endif
     lcd_puts_at_P(0, 1, PSTR("May destroy printer!"));
-    lcd_puts_at_P(0, 2, PSTR("ver ")); lcd_puts_P(PSTR(FW_VERSION_FULL));
-    lcd_puts_at_P(0, 3, PSTR(FW_REPOSITORY));
+    lcd_puts_at_P(0, 2, PSTR("FW")); lcd_puts_P(PSTR(FW_VERSION_FULL));
+    lcd_puts_at_P(0, 3, PSTR("Repo: ")); lcd_puts_P(PSTR(FW_REPOSITORY));
     lcd_wait_for_click();
     break;
 //	default: lcd_show_fullscreen_message_and_wait_P(_i("WARNING: This is an unofficial, unsupported build. Use at your own risk!")); break;////MSG_FW_VERSION_UNKNOWN c=20 r=8
 	}
 	lcd_update_enable(true);
 }
+#endif
 
 #if defined(FILAMENT_SENSOR) && defined(FSENSOR_PROBING)
 //! @brief try to check if firmware is on right type of printer
@@ -1487,7 +1488,9 @@ void setup()
 #if defined(FILAMENT_SENSOR) && defined(FSENSOR_PROBING)
     check_if_fw_is_on_right_printer();
 #endif //defined(FILAMENT_SENSOR) && defined(FSENSOR_PROBING)
+#if 0
     show_fw_version_warnings();    
+#endif
   }
 
   switch (hw_changed) { 
@@ -1593,17 +1596,17 @@ void setup()
       manage_heater(); // Update temperatures 
 #ifdef DEBUG_UVLO_AUTOMATIC_RECOVER 
 		printf_P(_N("Power panic detected!\nCurrent bed temp:%d\nSaved bed temp:%d\n"), (int)degBed(), eeprom_read_byte((uint8_t*)EEPROM_UVLO_TARGET_BED));
-#endif 
+#endif
      if ( degBed() > ( (float)eeprom_read_byte((uint8_t*)EEPROM_UVLO_TARGET_BED) - AUTOMATIC_UVLO_BED_TEMP_OFFSET) ){ 
           #ifdef DEBUG_UVLO_AUTOMATIC_RECOVER 
         puts_P(_N("Automatic recovery!")); 
-          #endif 
+          #endif
          recover_print(1); 
       } 
       else{ 
           #ifdef DEBUG_UVLO_AUTOMATIC_RECOVER 
         puts_P(_N("Normal recovery!")); 
-          #endif 
+          #endif
           if ( lcd_show_fullscreen_message_yes_no_and_wait_P(_T(MSG_RECOVER_PRINT), false) == LCD_LEFT_BUTTON_CHOICE) {
               recover_print(0); 
           } else { 
@@ -4570,7 +4573,7 @@ eeprom_update_word((uint16_t*)EEPROM_NOZZLE_DIAMETER_uM,0xFFFF);
         retract(false,retracted_swap[active_extruder]);
        #else
         retract(false);
-       #endif 
+       #endif
       break;
 #endif //FWRETRACT
 

+ 3 - 0
Firmware/messages.cpp

@@ -172,6 +172,9 @@ extern const char MSG_THERMAL_ANOMALY[] PROGMEM_I1 = ISTR("THERMAL ANOMALY");///
 extern const char MSG_LOAD_ALL[] PROGMEM_I1 = ISTR("Load All"); ////MSG_LOAD_ALL c=18
 
 //not internationalized messages
+#if 0
+const char MSG_FW_VERSION_BETA[] PROGMEM_N1 = "You are using a BETA firmware version! It is in a development state! Use this version with CAUTION as it may DAMAGE the printer!"; ////MSG_FW_VERSION_BETA c=20 r=8
+#endif
 const char MSG_SPOOL_JOIN[] PROGMEM_N1 = "SpoolJoin"; ////MSG_SPOOL_JOIN c=13
 const char MSG_FIRMWARE[] PROGMEM_N1 = "Firmware"; ////MSG_FIRMWARE c=8
 const char MSG_TOSHIBA_FLASH_AIR_COMPATIBILITY[] PROGMEM_N1 = "FlashAir"; ////MSG_TOSHIBA_FLASH_AIR_COMPATIBILITY c=8

+ 9 - 6
Firmware/messages.h

@@ -76,7 +76,6 @@ extern const char MSG_NO[];
 extern const char MSG_NOZZLE[];
 extern const char MSG_PAPER[];
 extern const char MSG_PAUSE_PRINT[];
-extern const char MSG_PINDA[];
 extern const char MSG_PLACE_STEEL_SHEET[];
 extern const char MSG_PLEASE_WAIT[];
 extern const char MSG_POWER_FAILURES[];
@@ -90,7 +89,6 @@ extern const char MSG_REMOVE_STEEL_SHEET[];
 extern const char MSG_RESET[];
 extern const char MSG_RESUME_PRINT[];
 extern const char MSG_RESUMING_PRINT[];
-extern const char MSG_SD_WORKDIR_FAIL[];
 extern const char MSG_SELFTEST_PART_FAN[];
 extern const char MSG_SELFTEST_EXTRUDER_FAN[];
 extern const char MSG_SELFTEST_FAILED[];
@@ -130,24 +128,20 @@ extern const char MSG_WIZARD_WELCOME[];
 extern const char MSG_WIZARD_WELCOME_SHIPPING[];
 extern const char MSG_YES[];
 extern const char MSG_V2_CALIBRATION[];
-extern const char MSG_WELCOME[];
 extern const char MSG_OFF[];
 extern const char MSG_ON[];
 extern const char MSG_NA[];
-extern const char MSG_SPOOL_JOIN[];
 extern const char MSG_CUTTER[];
 extern const char MSG_NONE[];
 extern const char MSG_WARN[];
 extern const char MSG_STRICT[];
 extern const char MSG_MODEL[];
-extern const char MSG_FIRMWARE[];
 extern const char MSG_GCODE[];
 extern const char MSG_GCODE_DIFF_PRINTER_CONTINUE[];
 extern const char MSG_GCODE_DIFF_PRINTER_CANCELLED[];
 extern const char MSG_NOZZLE_DIAMETER[];
 extern const char MSG_MMU_MODE[];
 extern const char MSG_SD_CARD[];
-extern const char MSG_TOSHIBA_FLASH_AIR_COMPATIBILITY[];
 extern const char MSG_SORT[];
 extern const char MSG_SORT_TIME[];
 extern const char MSG_SORT_ALPHA[];
@@ -182,6 +176,15 @@ extern const char MSG_THERMAL_ANOMALY[];
 extern const char MSG_LOAD_ALL[];
 
 //not internationalized messages
+#if 0
+extern const char MSG_FW_VERSION_BETA[];
+#endif
+extern const char MSG_SPOOL_JOIN[];
+extern const char MSG_FIRMWARE[];
+extern const char MSG_TOSHIBA_FLASH_AIR_COMPATIBILITY[];
+extern const char MSG_PINDA[];
+extern const char MSG_WELCOME[];
+extern const char MSG_SD_WORKDIR_FAIL[];
 extern const char MSG_BROWNOUT_RESET[];
 extern const char MSG_EXTERNAL_RESET[];
 extern const char MSG_FILE_SAVED[];

+ 4 - 4
Firmware/temperature.cpp

@@ -1210,27 +1210,27 @@ FORCE_INLINE static void soft_pwm_core()
   static unsigned char slow_pwm_count = 0;
   static unsigned char state_heater_0 = 0;
   static unsigned char state_timer_heater_0 = 0;
-#endif 
+#endif
 #if (EXTRUDERS > 1) || defined(HEATERS_PARALLEL)
   static unsigned char soft_pwm_1;
 #ifdef SLOW_PWM_HEATERS
   static unsigned char state_heater_1 = 0;
   static unsigned char state_timer_heater_1 = 0;
-#endif 
+#endif
 #endif
 #if EXTRUDERS > 2
   static unsigned char soft_pwm_2;
 #ifdef SLOW_PWM_HEATERS
   static unsigned char state_heater_2 = 0;
   static unsigned char state_timer_heater_2 = 0;
-#endif 
+#endif
 #endif
 #if HEATER_BED_PIN > -1
   // @@DR static unsigned char soft_pwm_b;
 #ifdef SLOW_PWM_HEATERS
   static unsigned char state_heater_b = 0;
   static unsigned char state_timer_heater_b = 0;
-#endif 
+#endif
 #endif
   
 #if defined(FILWIDTH_PIN) &&(FILWIDTH_PIN > -1)

+ 16 - 16
PF-build.sh

@@ -85,7 +85,7 @@
 # 15 Feb 2019, 3d-gussner, troubleshooting and minor fixes
 # 16 Feb 2019, 3d-gussner, Script can be run using arguments
 #                          $1 = variant, example "1_75mm_MK3-EINSy10a-E3Dv6full.h" at this moment it is not possible to use ALL
-#                          $2 = multi language OR English only [ALL/EN_ONLY]
+#                          $2 = multi language OR English only [ALL/EN_FARM]
 #                          $3 = development status [GOLD/RC/BETA/ALPHA/DEVEL/DEBUG]
 #                          If one argument is wrong a list of valid one will be shown
 # 13 Mar 2019, 3d-gussner, MKbel updated the Linux build environment to version 1.0.2 with an Fix maximum firmware flash size.
@@ -124,7 +124,7 @@
 #                          After compiling All multi-language variants it makes it easier to find missing or unused translations.
 # 12 May 2020, DRracer   , Cleanup double MK2/s MK25/s `not_tran` and `not_used` files
 # 13 May 2020, leptun    , If cleanup files do not exist don't try to.
-# 01 Oct 2020, 3d-gussner, Bug fix if using argument EN_ONLY. Thank to @leptun for pointing out.
+# 01 Oct 2020, 3d-gussner, Bug fix if using argument EN_FARM. Thank to @leptun for pointing out.
 #                          Change Build number to script commits 'git rev-list --count HEAD PF-build.sh'
 # 02 Oct 2020, 3d-gussner, Add UNKNOWN as argument option
 # 05 Oct 2020, 3d-gussner, Disable pause and warnings using command line with all needed arguments
@@ -268,7 +268,7 @@ echo "  -d : '$(tput setaf 2)GOLD$(tput sgr0)', '$(tput setaf 2)RC$(tput sgr0)',
 echo "  -g : '$(tput setaf 2)0$(tput sgr0)' no '$(tput setaf 2)1$(tput sgr0)' lite '$(tput setaf 2)2$(tput sgr0)' fancy  '$(tput setaf 2)3$(tput sgr0)' lite  with Quad_HR '$(tput setaf 2)4$(tput sgr0)' fancy with Quad_HR"
 echo "  -i : '$(tput setaf 2)1.8.5$(tput sgr0)', '$(tput setaf 2)1.8.19$(tput sgr0)'"
 echo "  -j : '$(tput setaf 2)0$(tput sgr0)' no, '$(tput setaf 2)1$(tput sgr0)' yes"
-echo "  -l : '$(tput setaf 2)ALL$(tput sgr0)' for multi language or '$(tput setaf 2)EN_ONLY$(tput sgr0)' for English only"
+echo "  -l : '$(tput setaf 2)ALL$(tput sgr0)' for multi language or '$(tput setaf 2)EN_FARM$(tput sgr0)' for English only"
 echo "  -m : '$(tput setaf 2)0$(tput sgr0)' no, '$(tput setaf 2)1$(tput sgr0)' yes '$(tput setaf 2)2$(tput sgr0)' with MMU2"
 echo "  -n : '$(tput setaf 2)0$(tput sgr0)' no, '$(tput setaf 2)1$(tput sgr0)' yes"
 echo "  -o : '$(tput setaf 2)1$(tput sgr0)' force or '$(tput setaf 2)0$(tput sgr0)' block output and delays"
@@ -882,7 +882,7 @@ else
     fi
 fi
 
-#'-l' argument defines if it is an English only version. Known values EN_ONLY / ALL
+#'-l' argument defines if it is an English only version. Known values EN_FARM / ALL
 #Check default language mode
 MULTI_LANGUAGE_CHECK=$(grep --max-count=1 "^#define LANG_MODE *" $SCRIPT_PATH/Firmware/config.h|sed -e's/  */ /g'|cut -d ' ' -f3)
 
@@ -897,7 +897,7 @@ if [ -z "$language_flag" ] ; then
                 break
                 ;;
             "English only") 
-                LANGUAGES="EN_ONLY"
+                LANGUAGES="EN_FARM"
                 break
                 ;;
             *)
@@ -906,11 +906,11 @@ if [ -z "$language_flag" ] ; then
         esac
     done
 else
-    if [[ "$language_flag" == "ALL" || "$language_flag" == "EN_ONLY" ]] ; then
+    if [[ "$language_flag" == "ALL" || "$language_flag" == "EN_FARM" ]] ; then
         LANGUAGES=$language_flag
     else
         echo "$(tput setaf 1)Language argument is wrong!$(tput sgr0)"
-        echo "Only $(tput setaf 2)'ALL'$(tput sgr0) or $(tput setaf 2)'EN_ONLY'$(tput sgr0) are allowed as language '-l' argument!"
+        echo "Only $(tput setaf 2)'ALL'$(tput sgr0) or $(tput setaf 2)'EN_FARM'$(tput sgr0) are allowed as language '-l' argument!"
         failures 5
     fi
 fi
@@ -1110,9 +1110,9 @@ prepare_hex_folders()
         if [ $OUTPUT == "1" ] ; then
             read -t 10 -p "Press Enter to continue..."
         fi
-    elif [[ -f "$SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_ONLY.hex"  &&  "$LANGUAGES" == "EN_ONLY" ]]; then
+    elif [[ -f "$SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_FARM.hex"  &&  "$LANGUAGES" == "EN_FARM" ]]; then
         echo ""
-        ls -1 $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_ONLY.hex | xargs -n1 basename
+        ls -1 $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_FARM.hex | xargs -n1 basename
         echo "$(tput setaf 6)This hex file to be compiled already exists! To cancel this process press CRTL+C and rename existing hex file.$(tput sgr 0)"
         if [ $OUTPUT == "1" ] ; then
             read -t 10 -p "Press Enter to continue..."
@@ -1171,7 +1171,7 @@ prepare_variant_for_compiling()
     sed -i -- 's/#define FW_REPOSITORY "Unknown"/#define FW_REPOSITORY "Prusa3d"/g' $SCRIPT_PATH/Firmware/Configuration.h
 
     #Prepare English only or multi-language version to be build
-    if [ $LANGUAGES == "EN_ONLY" ]; then
+    if [ $LANGUAGES == "EN_FARM" ]; then
         echo " "
         echo "English only language firmware will be built"
         sed -i -- "s/^#define LANG_MODE *1/#define LANG_MODE              0/g" $SCRIPT_PATH/Firmware/config.h
@@ -1379,17 +1379,17 @@ create_multi_firmware()
 }
 #### End: Create and save Multi Language Prusa Firmware
 
-#### Start: Save EN_ONLY language Prusa Firmware
+#### Start: Save EN_FARM language Prusa Firmware
 save_en_firmware()
 {
     #else
         echo "$(tput setaf 2)Copying English only firmware to PF-build-hex folder$(tput sgr 0)"
-        cp -f $BUILD_PATH/Firmware.ino.hex $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_ONLY.hex || failures 12
+        cp -f $BUILD_PATH/Firmware.ino.hex $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_FARM.hex || failures 12
         echo "$(tput setaf 2)Copying English only elf file to PF-build-hex folder$(tput sgr 0)"
-        cp -f $BUILD_PATH/Firmware.ino.elf $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_ONLY.elf || failures 12
+        cp -f $BUILD_PATH/Firmware.ino.elf $SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_FARM.elf || failures 12
     #fi
 }
-#### End: Save EN_ONLY language Prusa Firmware
+#### End: Save EN_FARM language Prusa Firmware
 
 #### Start: Cleanup Firmware
 cleanup_firmware()
@@ -1562,7 +1562,7 @@ if [[ ! -z "$mk404_flag" && "$variant_flag" != "All " ]]; then
     #cd ../MK404/master/build
 
 
-#Decide which hex file to use EN_ONLY or Multi language
+#Decide which hex file to use EN_FARM or Multi language
     if [ "$LANGUAGES" == "ALL" ]; then
         if [[ "$MK404_PRINTER" == "MK3" || "$MK404_PRINTER" == "MK3S" ]]; then
             MK404_firmware_file=$SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME.hex
@@ -1575,7 +1575,7 @@ if [[ ! -z "$mk404_flag" && "$variant_flag" != "All " ]]; then
             done
         fi
     else
-        MK404_firmware_file=$SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_ONLY.hex
+        MK404_firmware_file=$SCRIPT_PATH/../$OUTPUT_FOLDER/$OUTPUT_FILENAME-EN_FARM.hex
     fi
 
 # Start MK404

+ 1 - 1
build.sh

@@ -32,7 +32,7 @@ if [ ! -f "$SCRIPT_PATH/Firmware/Configuration_prusa.h" ]; then
     cp $SCRIPT_PATH/Firmware/variants/1_75mm_MK3-EINSy10a-E3Dv6full.h $SCRIPT_PATH/Firmware/Configuration_prusa.h || exit 8
 fi
 
-if [[ ! -z $LANGUAGES && $LANGUAGES == "EN_ONLY" ]]; then
+if [[ ! -z $LANGUAGES && $LANGUAGES == "EN_FARM" ]]; then
     echo "English only language firmware will be built"
     sed -i -- "s/^#define LANG_MODE *1/#define LANG_MODE              0/g" $SCRIPT_PATH/Firmware/config.h
 else