1 / 4
Official firmware for semi-smart addon (source code) — zdjęcie 1
1 / 4

Official firmware for semi-smart addon (source code)

Zamów wydruk tego modelu

Obliczymy ostateczną cenę na podstawie wybranego pliku. Sprawdzisz ją i zaakceptujesz przed płatnością.

Zapisane na tym urządzeniu.

Informacje o modelu

Źródło
Printables
Licencja
Creative Commons — Attribution — Noncommercial — Share Alike

⚠ Disclaimer
This firmware is provided "as is" without warranties. The user assumes all responsibility for installation, operation, and consequences. It is not a commercial product and has not been tested for all scenarios. Use at your own risk and never leave the printer unattended.

*Update to v1.1.0, improve heating and silent fans

🎯 Overview

The 3DMonkey Enhanced Semi Smart firmware optimizes environmental conditions in the CoreBoxx enclosure system using the Semi Smart PCB addon  by Voxel3D. It provides advanced temperature and humidity control, intelligent fan management, robust safety features, and a user-friendly interface with three operational states (OFF, STANDBY, ON).

🏗 System Architecture

Core Components

  • State Manager: Coordinates system operations.

  • Sensor Manager: Manages SHT4x temperature/humidity sensor.

  • PID Manager: Controls temperature using the GyverPID library.

  • Control System: Manages heater and fan operations.

  • Thermal Security: Ensures safety with multi-layer protection.

  • View Manager: Handles OLED display with multiple views, including splash screen.

  • Storage Manager: Saves settings in EEPROM.

  • GPIO Interface: Enables optional printer integration.

Hardware Requirements

🔧 System Operation

System States

  • SYSTEM_OFF: Complete shutdown (no fan, heater, or air cycling; minimal power use).

  • SYSTEM_STANDBY: Low-power mode with periodic air cycling (15s on, 5min off) and mode selection (USER/AUTO). Display shows "Standby".

  • SYSTEM_ON: Full operation with PID temperature control, proportional fan speed, and real-time data display.

State Transitions

  • USER Mode:

    • Controlled manually via buttons (see 📱 User Interface for button functions).

  • AUTO Mode:

    • Print start: OFF/STANDBY → ON (sets DRY_MODE_BY_HUM).

    • Print end: ON → OFF.

Operation Modes

  • AUTO Mode:

    • Automatic control based on printer status via GPIO.

    • PID temperature control with humidity monitoring.

    • Ideal for printers with xBuddy boards (e.g., Prusa MK4/S, MK3.9/S, MK3.5/S, CoreOne).

  • USER Mode:

    • Manual control via buttons.

    • PID temperature control with user-defined settings.

    • Suitable for standalone operation.

Dry Modes

  • DRY_MODE_BY_HUM: Stops when target humidity (5-90% RH) is reached.

  • DRY_MODE_BY_TIME: Runs for a user-specified duration (10min-12h).

📱 User Interface

Splash Screen

  • Duration: 2.5s on startup.

  • Content: VOXEL3D logo and "Code by 3DMonkey".

  • Priority: Blocks state changes during display.

Display Views

  • SYSTEM_OFF: Shows "System Off" and minimal conditions (e.g., current temperature/humidity).

  • SPLASH: Displays startup logo (2.5s).

  • STANDBY: Shows current conditions and control mode (USER/AUTO).

  • INFO: Real-time temperature, humidity, and status.

  • TEMP: Sets target temperature (15-45°C).

  • HUM: Sets target humidity (5-90% RH, AUTO mode only).

  • MODE: Selects dry mode (BY HUM / BY TIME).

  • DRY_TIME: Sets drying duration (BY TIME mode only).

Button Controls

  • Action Button:

    • Short press:

      • Toggles OFF ↔ STANDBY (any mode).

      • Enters/exits edit mode for settings (ON, USER mode).

    • Long press (2s):

      • STANDBY → ON (USER mode only).

      • ON → OFF (USER mode only).

  • Plus Button:

    • Navigates views or increments values.

    • Changes control mode (AUTO/USER) in STANDBY.

  • Minus Button:

    • Navigates views or decrements values.

Visual Indicators

  • Updates every 300ms.

  • Shows heater power percentage, countdown timers (DRY mode), safety warnings, and state-specific messages (e.g., "OFF", "STBY", "ON").

🌡 Temperature Control

  • PID Control: Uses GyverPID for precise regulation.

  • Setpoint Range: 15-45°C (59-113°F), default 35°C (95°F).

  • Safety Limits: 0-55°C (32-131°F).

  • Units: Configurable for Celsius (default) or Fahrenheit.

  • Fan Speed: Proportional to heater power (minimum 35% when heating).

💨 Fan Management

  • States:

    • FAN_OFF: No operation (SYSTEM_OFF or STANDBY cycle off).

    • FAN_COOLDOWN: 100% PWM for 30s after heater shutdown.

    • FAN_STANDBY_CYCLING_ON: 40% PWM for 15s every 5min in STANDBY.

    • FAN_ON: Proportional speed (35-100% PWM).

  • Features: Smooth transitions (2s), automatic cooldown, standby cycling, and silence in SYSTEM_OFF.

🛡 Thermal Safety

  • Protection Mechanisms:

    • Validates sensor readings (-50°C to 150°C, 5-90% RH).

    • Monitors heater temperature with a separate thermistor.

    • Disables heater at 55°C, activates fan at 100% until 40°C recovery.

    • Warning: Never leave the printer unattended during operation.

  • States:

    • THERMAL_NORMAL: Standard operation.

    • THERMAL_PROTECTION: Heater off, fan at maximum.

    • THERMAL_COOLDOWN: Cooling until recovery.

  • Parameters: 5s minimum protection, 30s cooldown.

  • Alerts: Visual warnings on display.

🔄 Task Scheduling

Non-blocking scheduler ensures responsiveness:

  • Sensor readings: Every 2s.

  • Display updates: Every 300ms.

  • PID calculations: Every 100ms.

  • Thermal safety checks: Every 100ms.

  • Button polling: Every 200ms.

  • Splash screen: 2.5s on startup.

💾 Configuration Storage

  • Persistent Settings: Target temperature, humidity, dry mode, drying duration, and control mode.

  • EEPROM Management: Validates settings, falls back to safe defaults if corrupted.

📊 Sensor Integration

  • SHT4x Sensor: Measures temperature and humidity via I2C every 2s.

  • Validation: Checks ranges and rate-of-change (max 15°C per reading).

  • Error Handling: Falls back to safe values on errors.

🔌 Printer Integration (Optional)

  • GPIO Interface: Monitors printer status (e.g., xBuddy boards).

  • Logic:

    • Print start: Turns system ON, sets DRY_MODE_BY_HUM.

    • Print end: Enters SYSTEM_OFF.

    • Manual override available.

  • Compatibility: Prusa MK4/S, MK3.9/S, MK3.5/S, CoreOne; disable for Prusa XL or MK3 series and lower (standalone mode).

🚀 Getting Started

Prerequisites

  • Assemble Semi Smart PCB and CoreBoxx enclosure per Voxel3D’s instructions.

  • Ensure a 300W power supply.

Firmware Installation

  1. Download the firmware.

  2. Upload the Arduino sketch to an Arduino Nano.

  3. Power on; splash screen displays for 2.5s, then enters SYSTEM_OFF.

Initial Configuration

  1. Set target temperature (15-45°C).

  2. Set target humidity (5-90% RH, AUTO mode).

  3. Select dry mode (BY HUM / BY TIME).

  4. Set drying duration (BY TIME mode).

  5. Choose control mode (USER / AUTO).

Operation

  • USER Mode:

    1. Short press ACTION: OFF → STANDBY.

    2. Long press ACTION: STANDBY → ON or ON → OFF.

  • AUTO Mode: System starts/stops with print status; manual control available.

  • Monitor via INFO view and adjust settings as needed.

 

Hardware Configuration

  • **For printers without xBuddy (e.g., MK3 series)**: Set 

GPIO_INTERFACE_ENABLED 0 in config.h
  • **For printers with xBuddy**: Set 

GPIO_INTERFACE_ENABLED 1 in config.h (default)

 

Slicer Configuration

Add the following G-code commands in your slicer's "Printer Start G-code" section:

M262 P0 B0
M264 P0 B1

Add the following G-code command in your slicer's "Printer End G-code" section:

M262 P0 B0
M264 P0 B0

These commands enable automatic control of the enclosure system based on print status.

 

🛠 Troubleshooting

Common Issues

  • System won’t start (red LED blinking): Check SHT4x sensor and power supply.

  • Temperature not reaching target: Verify heater wiring (Pin 10), PID settings, and power supply.

  • Fan not operating: Check wiring (Pin 3), PWM configuration, and thermal safety status.

  • Display issues: Verify I2C connections and address (0x3C).

  • Splash screen not showing: Check display connections and timer initialization.

Error Indicators

  • Warning display: Thermal protection active.

  • No display: Check I2C connections.

  • Sensor errors: System uses safe fallback values.

📈 Performance

  • Response Times: Temperature control (<30s), fan (<1s), UI (300ms), safety (<100ms), splash screen (2.5s).

  • Accuracy: Temperature ±0.3°C, humidity ±2% RH, PID control ±0.5°C.

  • Power Consumption:

    • SYSTEM_OFF: <10mA.

    • STANDBY: <50mA.

    • Normal: ~100-150W.

    • Peak: Up to around 200W during heating.

 

🤝 Contributing

Contributions are welcome! Please feel free to open issues for bugs and feature requests.

3D Monkey Enhanced Semi Smart** - Enhanced firmware for Voxel3D's Semi Smart addon


 

Tagi