3 hours ago
(This post was last modified: 1 hour ago by MinimumJargon.)
Just thought if anyone was thinking/trying to use a rock64 to control their 3d printers with Klipper / Mainsail over serial, that this might help
I did this with four rock64 v3 and got everyone working exactly like my pis, controlling 2 Prusa MK3S each.
I am not a Linux user, I managed to piece this together for the first one and the other 3 went smoothly following this.
Some of these steps may be redundant or unnecessary, but the result is that it works.
Base Setup:
Wipe SD card with SD Card Formatter
Download and use Armbian Imager to image SD
select board and OS
I used OS Minimal 25.5.1 bookworm
sudo apt update && sudo apt upgrade
sudo apt-get install git -y
sudo apt install network-manager
sudo reboot
Set up wifi dongle: (you may need specific firmware for brand if not Linux native. Mine was, I used a Ralink dongle)
nmcli device wifi list
nmcli dev wifi connect "Your_WiFi_SSID" password "Your_WiFi_Password"
nmcli device status
sudo reboot
Setup Mailsail and klipper, just follow prompts to install 1-3 or follow a guide for Kiauh:
cd ~ && git clone https://github.com/dw-0/kiauh.git
./kiauh/kiauh.sh
(install 1, 2, and 3)
sudo reboot
sudo apt update && sudo apt upgrade
Reduced bootup time for no Lan connection from 2min to 10 sec:
find / -name "systemd-networkd-wait-online.service"
(This should be the location, but confirm with the find)
sudo nano /etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service
(add text under [Service])
TimeoutStartSec=10
(At this point you could run klipper over a usb to the printer
Mailsail/klipper web GUI is whatever IP the rock64 or wifi dongle grabs
It will be at the top of the screen when you ssh/login)
Tx/Rx setup on UART2/tty2:
sudo apt update && sudo apt upgrade
1.Overlays
sudo armbian-config
system>kernel>boot01
(added text to boot/armbianEvn.txt under overlay)
overlays=rk3328-uart1 rk3328-uart2 rk3328-uart3
2.Kernel
sudo armbian-config
system>kernel>ker001 - alt kernel
updated to the newest rock kernel
3.disabled console
sudo systemctl mask serial-getty@ttyS2
4. Added users to dialout group
sudo usermod -a -G dialout <username>
(confirm user is in dialout group)
groups
5. echo test with jumper if you want(jump the UART2 Tx and Rx pins(8,10) together with a wire, no ground needed)
sudo apt install picocom
sudo picocom -b 115200 -r -l /dev/ttyS2
Type anything, if writing appears port is working
ctrl a then ctrl x to exit
In your printer.config file under the MCU you will use
serial: /dev/ttyS2
Happy Printing!!!
I did this with four rock64 v3 and got everyone working exactly like my pis, controlling 2 Prusa MK3S each.
I am not a Linux user, I managed to piece this together for the first one and the other 3 went smoothly following this.
Some of these steps may be redundant or unnecessary, but the result is that it works.
Base Setup:
Wipe SD card with SD Card Formatter
Download and use Armbian Imager to image SD
select board and OS
I used OS Minimal 25.5.1 bookworm
sudo apt update && sudo apt upgrade
sudo apt-get install git -y
sudo apt install network-manager
sudo reboot
Set up wifi dongle: (you may need specific firmware for brand if not Linux native. Mine was, I used a Ralink dongle)
nmcli device wifi list
nmcli dev wifi connect "Your_WiFi_SSID" password "Your_WiFi_Password"
nmcli device status
sudo reboot
Setup Mailsail and klipper, just follow prompts to install 1-3 or follow a guide for Kiauh:
cd ~ && git clone https://github.com/dw-0/kiauh.git
./kiauh/kiauh.sh
(install 1, 2, and 3)
sudo reboot
sudo apt update && sudo apt upgrade
Reduced bootup time for no Lan connection from 2min to 10 sec:
find / -name "systemd-networkd-wait-online.service"
(This should be the location, but confirm with the find)
sudo nano /etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service
(add text under [Service])
TimeoutStartSec=10
(At this point you could run klipper over a usb to the printer
Mailsail/klipper web GUI is whatever IP the rock64 or wifi dongle grabs
It will be at the top of the screen when you ssh/login)
Tx/Rx setup on UART2/tty2:
sudo apt update && sudo apt upgrade
1.Overlays
sudo armbian-config
system>kernel>boot01
(added text to boot/armbianEvn.txt under overlay)
overlays=rk3328-uart1 rk3328-uart2 rk3328-uart3
2.Kernel
sudo armbian-config
system>kernel>ker001 - alt kernel
updated to the newest rock kernel
3.disabled console
sudo systemctl mask serial-getty@ttyS2
4. Added users to dialout group
sudo usermod -a -G dialout <username>
(confirm user is in dialout group)
groups
5. echo test with jumper if you want(jump the UART2 Tx and Rx pins(8,10) together with a wire, no ground needed)
sudo apt install picocom
sudo picocom -b 115200 -r -l /dev/ttyS2
Type anything, if writing appears port is working
ctrl a then ctrl x to exit
In your printer.config file under the MCU you will use
serial: /dev/ttyS2
Happy Printing!!!

