Instructions
- This tutorial is based on Raspberry Pi OS with Desktop
- System version:
Debian GNU/Linux 12 (bookworm)
- Ensure that Klipper and Moonraker are already installed on your system, and you can access the Klipper web interface (such as Mainsail or Fluidd) via browser.
- Before getting started, ensure you have SSHed into your Raspberry Pi. To confirm your system version, run the following command:
cat /etc/os-release
- You should see an output similar to
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
. - If you are using a different system, you may still refer to the installation instructions below; some commands might not apply, so please adjust accordingly.
Wiring
- Updating
Install Components
- Run the following command for automatic installation
curl -sSL https://cnb.cool/3dmellow/public/Moon2Uart/-/git/raw/master/scripts/install.sh | sudo bash
Edit Configuration
Step 1
- Open and edit the
/boot/firmware/config.txt
filesudo nano /boot/firmware/config.txt
- Add the following lines at the end of the file
enable_uart=1
dtoverlay=miniuart-bt
force_turbo=1
dtoverlay=uart0 - Save and exit the editor by pressing
Ctrl + S
, thenCtrl + X
.
Step 2
- Open and edit the
/boot/firmware/cmdline.txt
filesudo nano /boot/firmware/cmdline.txt
- If
console=serial0,115200
exists, please remove it. - Save and exit the editor by pressing
Ctrl + S
, thenCtrl + X
.
- If
Step 3
- Run the following command via SSH
- No prompt indicates success
sudo chmod 777 /home/pi/printer_data/logs/moon2uart.log
Step 4
- Access the Klipper web interface (such as Mainsail or Fluidd) through a browser.
- Open the
moon2uart.cfg
file - Find the address following
SERIAL_PORT=
and change it to "/dev/ttyAMA0"
Note
- The UART interface name in Raspberry Pi may vary depending on the system version. If you cannot find
/dev/ttyAMA0
in the configuration file, try using/dev/ttyS0
or others. - For other host systems, please refer to their respective serial port names.
- For example, Fly host should use
/dev/ttyS0

- After making changes, click the
SAVE & RESTART
button at the top right to save and restart the service.
Step 5
- Restart your Raspberry Pi
Loading...