Skip to content

Commit

Permalink
10/23 Update menu changes
Browse files Browse the repository at this point in the history
  • Loading branch information
classicrocker883 committed Oct 23, 2022
1 parent f08c7be commit 079c1f5
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 410 deletions.
2 changes: 1 addition & 1 deletion Marlin/src/HAL/STM32/pinsDebug.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@

#define _PIN_ADD(NAME_ALPHA, ARDUINO_NUM) { NAME_ALPHA, ARDUINO_NUM },
#define PIN_ADD(NAME) _PIN_ADD(#NAME, NAME)
#include "../../inc/MarlinConfig.h"

typedef struct {
char Port_pin_alpha[5];
pin_t Ard_num;
Expand Down
6 changes: 2 additions & 4 deletions Marlin/src/HAL/STM32F1/HAL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,7 @@ void MarlinHAL::adc_start(const pin_t pin) {
_TCASE(POWER_MONITOR_CURRENT, POWER_MONITOR_CURRENT_PIN, POWERMON_CURRENT)
_TCASE(POWER_MONITOR_VOLTAGE, POWER_MONITOR_VOLTAGE_PIN, POWERMON_VOLTS)
}
//adc_result = (adc_results[(int)pin_index] & 0xFFF) >> (12 - HAL_ADC_RESOLUTION); // shift out unused bits
adc_result = (adc_results[(int)pin_index] >> 2) & 0x3FF; // shift out unused bits
adc_result = (adc_results[(int)pin_index] & 0xFFF) >> (12 - HAL_ADC_RESOLUTION); // shift out unused bits
}

#endif // ndef VOXELAB_N32
Expand Down Expand Up @@ -2260,8 +2259,7 @@ void MarlinHAL::adc_start(const pin_t pin) {
_TCASE(POWER_MONITOR_CURRENT, POWER_MONITOR_CURRENT_PIN, POWERMON_CURRENT)
_TCASE(POWER_MONITOR_VOLTAGE, POWER_MONITOR_VOLTAGE_PIN, POWERMON_VOLTS)
}
//adc_result = (adc_results[(int)pin_index] & 0xFFF) >> (12 - HAL_ADC_RESOLUTION); // shift out unused bits
adc_result = (adc_results[(int)pin_index] >> 2) & 0x3FF; // shift out unused bits
adc_result = (adc_results[(int)pin_index] & 0xFFF) >> (12 - HAL_ADC_RESOLUTION); // shift out unused bits
}

uint16_t analogRead(pin_t pin) {
Expand Down
13 changes: 6 additions & 7 deletions Marlin/src/lcd/e3v2/proui/dwin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3794,9 +3794,9 @@ void Draw_AdvancedSettings_Menu() {
checkkey = Menu;
if (SET_MENU(AdvancedSettings, MSG_UBL_MESH_LEVELING, 9)) {
BACK_ITEM(Goto_Main_Menu);
MENU_ITEM(ICON_ManualMesh, MSG_LEVEL_BED, onDrawMenuItem, ManualMeshStart);
MMeshMoveZItem = EDIT_ITEM(ICON_Zoffset, MSG_MOVE_Z, onDrawPFloat2Menu, SetMMeshMoveZ, &current_position.z);
MENU_ITEM(ICON_Axis, MSG_UBL_CONTINUE_MESH, onDrawMenuItem, ManualMeshContinue);
MENU_ITEM(ICON_ManualMesh, MSG_UBL_CONTINUE_MESH, onDrawMenuItem, ManualMeshStart);
MMeshMoveZItem = EDIT_ITEM(ICON_Zoffset, MSG_MESH_EDIT_Z, onDrawPFloat2Menu, SetMMeshMoveZ, &current_position.z);
MENU_ITEM(ICON_Axis, MSG_LEVEL_BED_NEXT_POINT, onDrawMenuItem, ManualMeshContinue);
MENU_ITEM(ICON_MeshViewer, MSG_MESH_VIEW, onDrawSubMenu, DWIN_MeshViewer);
#if ENABLED(USE_UBL_VIEWER)
EDIT_ITEM_F(ICON_PrintSize, "Change Mesh Viewer", onDrawChkbMenu, SetViewMesh, &BedLevelTools.view_mesh);
Expand All @@ -3817,7 +3817,7 @@ void Draw_AdvancedSettings_Menu() {
#else
void Draw_AdvancedSettings_Menu() {
checkkey = Menu;
if (SET_MENU(AdvancedSettings, MSG_ADVANCED_SETTINGS, 19)) { //2
if (SET_MENU(AdvancedSettings, MSG_ADVANCED_SETTINGS, 22)) {
BACK_ITEM(Goto_Main_Menu);
#if ENABLED(EEPROM_SETTINGS)
MENU_ITEM(ICON_WriteEEPROM, MSG_STORE_EEPROM, onDrawMenuItem, WriteEeprom);
Expand All @@ -3830,7 +3830,6 @@ void Draw_AdvancedSettings_Menu() {
#if HAS_BED_PROBE
MENU_ITEM(ICON_ProbeSet, MSG_ZPROBE_SETTINGS, onDrawSubMenu, Draw_ProbeSet_Menu);
#endif
MENU_ITEM(ICON_FilSet, MSG_FILAMENT_SET, onDrawSubMenu, Draw_FilSet_Menu);
#if ProUIex
MENU_ITEM(ICON_PhySet, MSG_PHY_SET, onDrawSubMenu, Draw_PhySet_Menu);
#endif
Expand All @@ -3843,6 +3842,7 @@ void Draw_AdvancedSettings_Menu() {
#if HAS_ESDIAG
MENU_ITEM_F(ICON_ESDiag, "End-stops diag.", onDrawSubMenu, Draw_EndStopDiag);
#endif
MENU_ITEM(ICON_Scolor, MSG_COLORS_SELECT, onDrawSubMenu, Draw_SelectColors_Menu);
#if ENABLED(PRINTCOUNTER)
MENU_ITEM(ICON_PrintStats, MSG_INFO_STATS_MENU, onDrawSubMenu, Goto_PrintStats);
MENU_ITEM(ICON_PrintStatsReset, MSG_INFO_PRINT_COUNT_RESET, onDrawSubMenu, PrintStats.Reset);
Expand All @@ -3863,7 +3863,7 @@ void Draw_AdvancedSettings_Menu() {
EDIT_ITEM(ICON_Pwrlossr, MSG_OUTAGE_RECOVERY, onDrawChkbMenu, SetPwrLossr, &recovery.enabled);
#endif
#if HAS_SD_EXTENDER
EDIT_ITEM(ICON_File, MSG_MEDIA_UPDATE, onDrawChkbMenu, SetMediaAutoMount, &HMI_data.MediaAutoMount);
EDIT_ITEM(ICON_File, MSG_MEDIA_UPDATE, onDrawChkbMenu, SetMediaAutoMount, &HMI_data.MediaAutoMount);
#endif
#if ENABLED(BAUD_RATE_GCODE)
EDIT_ITEM_F(ICON_SetBaudRate, "250K baud", onDrawChkbMenu, SetBaudRate, &HMI_data.Baud250K);
Expand All @@ -3872,7 +3872,6 @@ void Draw_AdvancedSettings_Menu() {
EDIT_ITEM(ICON_Brightness, MSG_BRIGHTNESS, onDrawPInt8Menu, SetBrightness, &ui.brightness);
MENU_ITEM(ICON_Brightness, MSG_BRIGHTNESS_OFF, onDrawMenuItem, TurnOffBacklight);
#endif
MENU_ITEM(ICON_Scolor, MSG_COLORS_SELECT, onDrawSubMenu, Draw_SelectColors_Menu);
}
ui.reset_status(true);
UpdateMenu(AdvancedSettings);
Expand Down
4 changes: 2 additions & 2 deletions Marlin/src/lcd/e3v2/proui/endstop_diag.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/**
* DWIN End Stops diagnostic page for PRO UI
* Author: Miguel A. Risco-Castillo (MRISCOC)
* Version: 1.2.3
* Date: 2022/02/24
* Version: 1.3.3
* Date: 2022/10/07
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/module/settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3718,7 +3718,7 @@ void MarlinSettings::reset() {
//
// PROUI custom G-codes
//
#if ProUIex
#if ProUIex && ENABLED(HAS_CGCODE)
custom_gcode_report(forReplay);
#endif
}
Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/pins/pins.h
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@
#elif MB(CHITU3D_V9)
#include "stm32f1/pins_CHITU3D_V9.h" // STM32F1 env:chitu_f103 env:chitu_f103_maple
#elif MB(CREALITY_V4)
#include "stm32f1/pins_CREALITY_V4.h" // STM32F1 env:STM32F103RE_creality env:STM32F103RE_creality_xfer env:STM32F103RC_creality env:STM32F103RC_creality_xfer env:STM32F103RE_creality_maple env:STM32F103RET6_voxelab_aquila_G32 env:STM32F103RET6_voxelab_aquila_N32 env:STM32F103RC_creality_maple
#include "stm32f1/pins_CREALITY_V4.h" // STM32F1 env:STM32F103RE_creality env:STM32F103RE_creality_xfer env:STM32F103RC_creality env:STM32F103RC_creality_xfer env:STM32F103RE_creality_maple
#elif MB(CREALITY_V4210)
#include "stm32f1/pins_CREALITY_V4210.h" // STM32F1 env:STM32F103RE_creality env:STM32F103RE_creality_xfer env:STM32F103RC_creality env:STM32F103RC_creality_xfer env:STM32F103RE_creality_maple
#elif MB(CREALITY_V425)
Expand Down
2 changes: 1 addition & 1 deletion configurations/Aquila/MM/Configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@

// Choose the name from boards.h that matches your setup
#ifndef MOTHERBOARD
#define MOTHERBOARD BOARD_CREALITY_V4 // BOARD_CREALITY_V427 BOARD_VOXELAB_AQUILA BOARD_CREALITY_V4
#define MOTHERBOARD BOARD_VOXELAB_AQUILA // BOARD_CREALITY_V427 BOARD_VOXELAB_AQUILA BOARD_CREALITY_V4
#endif

/**
Expand Down
2 changes: 1 addition & 1 deletion configurations/Aquila/UBL/Configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@

// Choose the name from boards.h that matches your setup
#ifndef MOTHERBOARD
#define MOTHERBOARD BOARD_CREALITY_V4 // BOARD_CREALITY_V427 BOARD_VOXELAB_AQUILA BOARD_CREALITY_V4
#define MOTHERBOARD BOARD_VOXELAB_AQUILA // BOARD_CREALITY_V427 BOARD_VOXELAB_AQUILA BOARD_CREALITY_V4
#endif

/**
Expand Down
2 changes: 1 addition & 1 deletion ini/stm32f1-maple.ini
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ lib_deps = ${env:STM32F103RC_btt_maple.lib_deps}
#
[env:STM32F103RE_creality_maple]
extends = env:STM32F103RE_maple
build_flags = ${STM32F1_maple.build_flags} -DTEMP_TIMER_CHAN=4 -DVOXELAB_N32
build_flags = ${STM32F1_maple.build_flags} -DTEMP_TIMER_CHAN=4
board_build.address = 0x08007000
board_build.ldscript = creality.ld
extra_scripts = ${STM32F1_maple.extra_scripts}
Expand Down
Loading

0 comments on commit 079c1f5

Please sign in to comment.