Skip to content

Settings Module

The Settings module provides the complete user-facing configuration interface for the Pibot CNC pendant. It is composed of two complementary screens — a radial Settings Screen and a scrollable Settings List Screen — that together expose every configurable parameter, from UI appearance to CNC transport details and jog motion tuning.

Both screens run exclusively on LVGL Core 1 and follow the pendant’s standard screen lifecycle: create() → active use → prepareForDestruction() → LVGL LV_EVENT_DELETE auto-cleanup. All changes are persisted to NVS via ESP3DSettings (esp3dXsettings) and take effect immediately or after the next restart, as documented per setting.


navigate to settings

navigate back

Settings Editor section

Language section

Output Selection section

Output Config (serial/uart_ext)

Output Config (WiFi socket/ws)

Output Config (BT)

Server Scan section

Reset / Factory confirm

navigate back

Polling

Screen Timeout

File Ext / WiFi SSID / etc.

Forget WiFi / Forget BT confirm

Main Screen

(main_screen.cpp)

Settings Screen

(settings_screen.cpp)

CircularMenuScreen

Settings List Screen

(settings_list_screen.cpp)

ListMenuScreen

Languages Screen

Output Selection Screen

Baudrate Screen

WiFi Scan Screen

BT Scan Screen

Server Scan Screen

Message Box Screen

(confirm dialogs)

Polling Screen

Screen Timeout Screen

Input Screen

(text / numeric / PIN)


Core Services

Status Overlays

UI Framework

Settings Module

SettingsScreen

(CircularMenuScreen)

SettingsListScreen

(ListMenuScreen)

CircularMenuScreen

(base class)

ListMenuScreen

(base class)

CircularMenuComponent

VirtualButtonsComponent

ConnectionStatusComponent

FirmwareStatusComponent

UIManager

(ui_manager)

ESP3DSettings

(esp3dXsettings)

TranslationService

esp3d_sound


Both screens implement the same safe three-phase lifecycle pattern used throughout the UI framework:

UIManagerLVGLScreenCallerUIManagerLVGLScreenCallerActive usecreate()lv_obj_create() + register componentslv_obj_add_event_cb(LV_EVENT_DELETE, onScreenDestroy)registerScreen()navigateTo(target) via ESP3D_TRANSITION_STARTcleanup_timer_cb() firesprepareForDestruction()lv_scr_load_anim(next_screen)LV_EVENT_DELETE firesonScreenDestroy() - delete C++ objectsunregisterScreen()
Sub-moduleFileBase ClassPurpose
Settings Screensettings_screen.cppCircularMenuScreenRadial menu hub — UI preferences, theme, output routing
Settings List Screensettings_list_screen.cppListMenuScreenScrollable list editor — jog tuning, network credentials, feature toggles

The Settings Screen (settingsScreen namespace) is the primary entry point from the Main Screen. It presents a CircularMenuScreen (radial icon menu) whose sections are conditionally compiled based on build features.

SectionFeature GuardAction
Lock UI—Toggles pendant lock button visibility
SoundESP3D_BUZZER_FEATUREToggles buzzer on/off
RotationESP3D_DYNAMIC_ROTATION_FEATUREEncoder adjusts screen orientation (0°/90°/180°/270°)
BacklightESP3D_BRIGHTNESS_CONTROL_FEATUREEncoder adjusts brightness 0–100%
Language—Navigates to Languages Screen
Theme—Encoder cycles through available UI themes (live preview)
Reset Settings—Confirmation → esp3dXsettings.reset() → restart
Factory RebootESP3D_FACTORY_FEATUREConfirmation → boot factory partition → restart
Settings Editor—Navigates to Settings List Screen
Output SelectionBT/WiFi/UART Ext buildsNavigates to Output Selection Screen
Output Configuration—Context-sensitive: baud rate / WiFi scan / BT scan
Server ScanESP3D_IP_CNC_CLIENT_FEATURENavigates to Server Scan Screen

The circular menu supports three special encoder sub-modes beyond normal section navigation:

  • ESP3D_ENCODER_THEME — cycles themes; live-previews colors before confirming
  • ESP3D_ENCODER_ROTATION — rotates pending_orientation_ ±90° steps; confirmed or cancelled on Back/OK
  • ESP3D_ENCODER_BACKLIGHT — adjusts brightness in 5% increments; saved to NVS on confirm

See Settings Screen for full details.


Settings List Screen — High-Level Summary

Section titled “Settings List Screen — High-Level Summary”

The Settings List Screen (settingsListScreen namespace) is a scrollable ListMenuScreen reached from the Settings Editor section. It exposes two categories of settings:

Section titled “Navigation Settings (open a sub-screen or dialog)”
  • Polling interval, Screen timeout, File extensions
  • Network credentials: WiFi SSID / Password / Forget, BT PIN / BLE passkey / Forget BT Host
  • IP/WebSocket transport: Server address, Server port, WebSocket path
  • Per-axis Jog steps and Jog feedrates (X/Y/Z/A/B/C)
  • Macros enabled, Probe enabled, Tool Change enabled
  • Bypass Safety Focus, MPG Mode (grblHAL only), Swap RX/TX

The list preserves scroll position across navigations via last_selected_index. Axis names respect the grblHAL $376 UVW naming observable (axis_names).

See Settings List Screen for full details.


Settings List Screen

Settings Screen

load on create

load on create

writeByte / writeString

writeByte / writeString

/ writeUint32

NVS

(ESP3DSettings)

User Input

(touch / encoder / buttons)

Read current values

(buzzer, theme, backlight…)

Write updated values

(toggle / encoder confirm)

Read setting values

(jog steps, WiFi SSID…)

Write setting values

(on OK callback)


SystemUsed ByHow
ESP3DSettings (esp3dXsettings)Both screensRead/write all persistent configuration values
UIManager (ui_manager)Both screensTheme, orientation, screen registration, overlay anchoring
ESP3DTranslationServiceBoth screensAll labels translated at render time
esp3d_soundSettings ScreenSound toggle + auditory feedback
ESP3DCommandsSettings List ScreenDetect active transport type for conditional items
ConnectionStatusComponentSettings ScreenLive transport status overlay
FirmwareStatusComponentSettings ScreenLive CNC firmware status overlay
messageBoxScreenBoth screensConfirmation dialogs (reset, factory, forget WiFi/BT)
inputScreenSettings List ScreenText/numeric/PIN editors for credentials and jog values
macroManagerSettings List ScreenLoad/clear macro list when macro toggle changes