没有合适的资源?快使用搜索试试~ 我知道了~
Marlin is a huge C++ program composed of many files, but among t
需积分: 0 0 下载量 48 浏览量
2023-11-16
22:15:48
上传
评论
收藏 1.51MB DOCX 举报
温馨提示
试读
133页
Marlin配置说明文档英文版 Marlin is a huge C++ program composed of many files, but among the most important are the files that contain all of Marlin’s compile-time configuration options
资源推荐
资源详情
资源评论
Configuring Marlin
Marlin is a huge C++ program composed of many files, but among the most important are
the files that contain all of Marlin’s compile-time configuration options:
• Configuration.h contains the core settings for the hardware, language and
controller selection, and settings for the most common features and components.
• Configuration_adv.h contains more detailed customization options, add-ons,
experimental features, and other esoteric settings.
• config.ini may be included to modify the configuration at the start of a PlatformIO
build. See the Configuration with INI page for more information.
The two files contain all of Marlin’s build-time configuration options. Simply edit or replace
these files, then build and upload Marlin to the board. Hundreds of user-donated
configurations are posted at the Configurations repository to get you started. .h
Compiler Directives
Marlin is configured using C++ compiler directives. This allows Marlin to leverage the C++
preprocessor and include only the code and data needed for the enabled options. This
results in the smallest possible binary. A build of Marlin can range from 50K to over 230K in
size.
Settings can be enabled, disabled, and assigned values using C preprocessor syntax like
so:
Plaintext
#define THIS_IS_ENABLED // this switch is enabled
//#define THIS_IS_DISABLED // this switch is disabled
#define OPTION_VALUE 22 // this setting is "22"
Migration
To use configurations from an earlier version of Marlin, first try dropping them into the newer
Marlin, updating and , and building the firmware. As part of the build process, Marlin will
check for outdated options and show error messages that explain exactly what needs to be
changed. CONFIGURATION_H_VERSION CONFIGURATION_ADV_H_VERSION
To migrate your settings to a new Configuration you can use tools like Notepad++ or
Winmerge to compare old configurations with the newer (default) configurations and copy
settings over on a change-by-change basis. Most settings will come over without changes,
then you can review any tricky changes that remain.
Sources of Documentation
The most authoritative source on configuration details will always be the configuration files
themselves . They provide pretty complete descriptions of each option, and are themselves
the source for most of the information presented here.
If you’ve never configured and calibrated a 3D Printer before, here are some good
resources:
• Calibration
• Calibrating Steps-per-unit (video)
• Průša’s calculators
• Triffid Hunter’s Calibration Guide
• The Essential Calibration Set
• Calibration of your RepRap
• XY 20mm Calibration Box
• G-code reference
• Marlin3DprinterTool
Before You Begin
To get your core settings right you’ll need to know the following things about your printer:
Configuration.h
• Printer style, such as Cartesian, Delta, CoreXY, or SCARA
• Driver board, such as RAMPS, RUMBA, Teensy, etc.
• Number of extruders
• Steps-per-mm for XYZ axes and extruders (can be tuned later)
• Endstop positions
• Thermistors and/or thermocouples
• Probes and probing settings
• LCD controller brand and model
• Add-ons and custom components
Configuration.h
The core and default settings of Marlin live in the file. Most of these settings are fixed. Once
you compile Marlin, that’s it. To change them you need to re-compile. However, several
items in only provide defaults -factory settings- that can be changed via the user interface,
stored on EEPROM and reloaded or restored to initial values. Configuration.h
Configuration.h
Settings that can be changed and saved to EEPROM are marked with . Options marked with
can be changed from the LCD controller.
Settings saved in EEPROM persist across reboots and still remain after flashing new
firmware, so always send M502 , M500 (or “Reset EEPROM” from the LCD) after flashing.
This section follows the order of settings as they appear. The order isn’t always logical, so
“Search In Page” may be helpful. We’ve tried to keep descriptions brief and to the point. For
more detailed information on various topics, please read the main articles and follow the
links provided in the option descriptions.
Configuration versioning
Plaintext
#define CONFIGURATION_H_VERSION 020005
Marlin now checks for a configuration version and won’t compile without this setting. If you
want to upgrade from an earlier version of Marlin, add this line to your old configuration file.
During compilation, Marlin will throw errors explaining what needs to be changed.
Firmware Info
Plaintext
#define STRING_CONFIG_H_AUTHOR "(none, default config)"
#define SHOW_BOOTSCREEN
#define SHOW_CUSTOM_BOOTSCREEN
#define CUSTOM_STATUS_SCREEN_IMAGE
• STRING_CONFIG_H_AUTHOR is shown in the Marlin startup message to identify the
author (and optional variant) of the firmware. Use this setting as a way to uniquely identify
your custom configurations. The startup message is printed whenever the board (re)boots.
• SHOW_BOOTSCREEN enables the boot screen for LCD controllers.
• SHOW_CUSTOM_BOOTSCREEN shows the bitmap in Marlin/_Bootscreen.h on startup.
• CUSTOM_STATUS_SCREEN_IMAGE shows the bitmap in Marlin/_Statusscreen.h on
the status screen.
Hardware Info
Serial Port
The index of the on-board serial port that will be used for primary host communication.
Change this if, for example, you need to connect a wireless adapter to non-default port pins.
The first serial port (-1 or 0) will always be used by the Arduino bootloader regardless of this
setting.
Enable this if your board has a secondary serial port.
Serial port -1 is the USB emulated serial port, if available.
Baud Rate
The serial communication speed of the printer should be as fast as it can manage without
generating errors. In most cases 115200 gives a good balance between speed and stability.
Start with 250000 and only go lower if “line number” and “checksum” errors start to appear.
Note that some boards ( e.g., a temperamental Sanguinololu clone based on the
ATMEGA1284P) may not be able to handle a baud rate over 57600. Allowed values: 2400,
9600, 19200, 38400, 57600, 115200, 250000.
Bluetooth
Enable the Bluetooth serial interface. For boards based on the AT90USB.
Motherboard
Plaintext
#define MOTHERBOARD BOARD_RAMPS_14_EFB
The most important setting is Marlin is the motherboard. The firmware needs to know what
board it will be running on so it can assign the right functions to all pins and take advantage
of the full capabilities of the board. Setting this incorrectly will lead to unpredictable results.
Using boards.h as a reference, replace BOARD_RAMPS_14_EFB with your board’s ID. The
boards.h file has the most up-to-date listing of supported boards - check there first if you
don’t see yours listed here .
The Sanguino board requires adding “Sanguino” support to Arduino IDE. Open
Preferences and locate the Additional Boards Manager URLs field. Copy and paste this
source URL . Then use Tools > Boards > Boards Manager to install “Sanguino” from the
list. An internet connection is required. (Thanks to “Dust’s RepRap Blog” for the tip.)
Custom Machine Name
Plaintext
//#define CUSTOM_MACHINE_NAME "3D Printer"
This is the name of your printer as displayed on the LCD and by M115 . For example, if you
set this to “My Delta” the LCD will display “My Delta ready” when the printer starts up.
Machine UUID
Plaintext
//#define MACHINE_UUID "00000000-0000-0000-0000-000000000000"
A unique ID for your 3D printer. A suitable unique ID can be generated randomly at
uuidtools.com . Some host programs and slicers may use this identifier to differentiate
between specific machines on your network.
Extruder Info
Extruders
This value, from 0 to 6, defines how many extruders (or E steppers) the printer has. By
default Marlin will assume separate nozzles all moving together on a single carriage. If you
have a single nozzle, a switching extruder, a mixing extruder, or dual X carriages, specify
that below.
This value should be set to the total number of E stepper motors on the machine, even if
there’s only a single nozzle.
Filament Diameter
剩余132页未读,继续阅读
资源评论
拿把斧头
- 粉丝: 8
- 资源: 10
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功