Appearance
Week 12 - Mechanical design, Machine design
Assignments of the Week
Group Assignment
- design a machine that includes mechanism+actuation+automation+application
- build the mechanical parts and operate it manually
- document the group project and your individual contribution
Project Introduction: Inspired by a YouTube video demonstrating PCB printing using a 3D printer, I decided to make this the theme of our group project - designing and building a mechanical device capable of printing PCBs. My primary responsibility is the structural design. The machine adopts a gantry-style 3D printer architecture, utilizing dual Z-axis motors with lead screws for vertical movement control, while employing timing belt drives for precise X and Y axis positioning. For circuit patterning, conductive silver paste replaces traditional etching processes. For system control, we plan to implement Marlin firmware to operate and control the entire machine.
YouTube Reference Video:
Model Design
I completed the device's exterior modeling using Fusion 360, with the design concept referencing the common CoreXY architecture. The framework is constructed with 3030 aluminum profiles to ensure mechanical stability and scalability.
Main tools and materials used:
- Main control board: Arduino Mega 2560
- Driver expansion board: RAMPS 1.4
- Stepper motors: 42 stepper motors × 4
- Stepper motor drivers: A4988 × 4
- Z-axis transmission structure:
- 2mm lead screws × 2
- Couplers (5mm to 8mm) × 2
- Aluminum profiles:
- 3030 aluminum profiles: 250mm × 6, 200mm × 2
- 2020 V-slot aluminum profiles: 300mm × 1
- Auxiliary components:
- Various 3D printed parts (such as slider brackets, belt clamps, etc.)
Here is the mechanical structure designed in Fusion 360:
The sidebar shows some auxiliary components designed, primarily various mounting brackets. Originally planned to use entirely 3D printed parts for mounting, but during actual assembly we found some components didn't perform satisfactorily, so we ultimately decided to use standard hardware instead.
Here are some of the 3D printed components, including T-shaped and L-shaped brackets, whose mounting performance proved unsatisfactory, leading us to ultimately adopt standard hardware. For the timing belt fasteners, we designed several gear-clip structures, but during operation we observed belt slippage, prompting us to switch to screw-based fastening instead.
Fabrication Process
Based on the completed 3D model design, my teammate Yaorun Zhang and I jointly completed the aluminum profile processing work. We used measuring tapes to determine required dimensions and performed the cutting operations using a cutting machine.
Here is the chassis section, which uses timing belt transmission: The timing belt fastening method references the approach used in mechanical cutting machines, utilizing screw-based fixation.
Reference for laser cutter timing belt fastening method:
This is conductive silver paste, which we will use to draw circuits Here are photos of the assembly process with my teammate Yaorun Zhang:
Software Debugging
The software side utilizes Marlin firmware, which is flashed using Arduino IDE and debugged with a serial port assistant. Here's an introduction to Marlin firmware:
- Marlin firmware is an open-source 3D printer project from the RepRap series. It originated from the open-source Sprinter and grbl projects, becoming an independent open-source project on August 12, 2011, freely available to everyone. Using Marlin firmware allows customization of 3D printers (for functions like laser engraving, writing, CNC, etc.), with the firmware providing corresponding configuration interfaces for these features.
Visit the Marlin official website and click Download
Here I selected the current Marlin version, downloaded and extracted it
When configuring Marlin firmware, only a few configuration files need to be modified:
Configuration.h: Contains core settings for hardware, language and controller selection, as well as settings for the most common features and components.
Configuration_adv.h: Provides more detailed customization options, add-ons, experimental features and other deeper-level settings.
Marlin firmware configuration mainly includes the following aspects:
- Communication baud rate
- Mainboard type (the specific board being used)
- Temperature sensor types (including extruder thermistor and heated bed thermistor)
- Temperature settings (including nozzle temperature and bed temperature)
- PID temperature control parameters (for both nozzle and bed temperature control)
- Endstop switches
- Stepper motor directions for all 4 axes
- Initial positions for X/Y/Z axes
- Printer movement range
- Auto bed leveling
- Movement speeds
- Axis movement resolution
- Standalone controller
Before configuration, I need to confirm some information. We are using RAMPS 1.4 + Mega2560, with temperature control disabled, endstops disabled, LCD disabled. Step distance and direction will be calibrated via G-code, with full manual control: We can send G0 or G1 commands through serial port to control motor movement. Now let's begin the configuration:
Communication Baud Rate
Mainboard Type
- Compatible with RAMPS 1.4 + Mega2560, using 4 stepper interfaces (X/Y/Z/E0)
- Temperature Sensor Type
- Since no temperature sensors are connected, using virtual sensors to bypass thermal protection
- Temperature Configuration
- Heating function not used, can be skipped. With virtual sensors, Marlin won't check temperatures and will directly allow motor operation
- PID Temperature Control Parameters
- No hotend/heated bed used, no need to set PID parameters. Marlin will ignore PID control by default
- Endstop Switches
- Not using endstop switches, can be skipped
- Stepper Motor Directions
- Using default directions
- X/Y/Z Initial Positions
- Without endstops, we'll make it "pretend" to be ready at origin. Home command won't perform actual movement.
- Printer Movement Range
- XY area: 150mm x 100mm, Z-axis set to 50mm
- Motor Drivers
- X, Y, Z motor drivers all set to A4988. Enabled second Z-axis motor (Z2), connected to Z2 driver (usually connected to E1 interface). Although extrusion function isn't used, Marlin requires definition - E0 interface can be left as default.
Compiled and uploaded the code to the mainboard, but currently encountering some issues. When using Arduino IDE serial port to send G-code commands for debugging, there are some problems - the X and Y axis motors can operate normally, but the Z axis motor fails to function properly, currently unresolved.
Debugging commands:
G90 Use absolute coordinates
G1 X100 Y50
G1 X100 Y100
G1 Z10