You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30-57Lines changed: 30 additions & 57 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,12 +1,13 @@
1
1
> [!CAUTION]
2
-
> **THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND. BY USING IT YOU TAKE ALL THE RISKS FOR YOUR ACTIONS**
2
+
> **THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND. BY USING IT YOU TAKE ALL THE RISKS FOR YOUR ACTIONS**<br />
3
+
> **THIS FIRMWARE IS A WORK IN PROGRESS, DO NOT USE IT UNLESS YOU KNOW HOW TO USE LINUX AND HOW TO RECOVER OR UNBRICK YOUR PRINTER**
3
4
4
5
# Rinkhals
5
6
6
7
Rinkhals is a custom firmware for the Anycubic Kobra 3 3D printer. The goal of this project is to create a simple and safe overlay for the Kobra 3 firmware, adding some usefule features.
7
-
Multiple versions can be installed at the same time and it can easily be disabled.
8
+
This firmware will likely not support all use cases, like running vanilla Klipper or your specific feature / plugin.
8
9
9
-
Here is a list of the features I added:
10
+
Here are some of the features I added:
10
11
- Mainsail, Fluidd and Moonraker (using nginx)
11
12
- USB camera support through Fluidd and Moonraker (mjpg-streamer)
12
13
- Print from Moonraker will show the print screen (moonraker-proxy)
@@ -22,23 +23,11 @@ The stock firmwares are available on a separate branch: https://github.com/jbato
22
23
</p>
23
24
24
25
25
-
## Known issues / Future developments
26
+
## Documentation / Known issues
26
27
27
28
The [wiki](https://github.com/jbatonnet/Rinkhals/wiki) is a collection of documentation, reverse engineering and notes about the printer and development, don't forget to [check it out](https://github.com/jbatonnet/Rinkhals/wiki)!
28
29
29
-
- If not installed properly, the printer shows a 11407 error > [See the wiki about error 11407](https://github.com/jbatonnet/Rinkhals/wiki/Firmware#my-printer-shows-a-11407-error)
30
-
- The camera is not accessible from Anycubic apps anymore
- Installation screen (kill K3SysUi, show screens then reboot or restore K3SysUi?)
38
-
- Reimplement gkcam
39
-
- Timelapse support
40
-
- Logs cleanup
41
-
- Old Rinkhals versions cleanup
30
+
If your printer shows a 11407 error, check the wiki there: [See the wiki about error 11407](https://github.com/jbatonnet/Rinkhals/wiki/Firmware#my-printer-shows-a-11407-error)
42
31
43
32
44
33
## SWU tools
@@ -99,59 +88,43 @@ Then you can delete the /useremain/rinkhals directory. That's it!
99
88
</p>
100
89
101
90
102
-
## Repo structure
103
-
104
-
-**doc/**: Some documentation I gathered on my journey
105
-
-**build/**: The tools, scripts and Dockerfiles needed to build this project
106
-
-**1-buildroot/**: Buildroot setup to build the base filesystem / binaries
107
-
-**2-external/**: Scripts to get the external components like Fluidd and Mainsail
108
-
-**3-python/**: Dockerfile and script to build and get the necessary Python packages
109
-
-**files/**: The target filesystem overlay and the scripts needed to run the firmware
110
-
-**1-buildroot/**: First layer containing Buildroot built binaries
111
-
-**2-external/**: External components layer for Fluidd, Mainsail, Moonraker and OctoApp
112
-
-**3-python/**: Layer with all the necessary Python packages
113
-
-**4-rinkhals/**: Fimware config and scripts to run Rinkhals
114
-
115
-
116
-
## Firmware startup
117
-
118
-
During this custom firmware installation, **update.sh** will install the overlay filesystem in **/useremain/rinkhals**. Every version you install will end up in a different directory, allowing you to easily switch between versions or rollback if something goes wrong.
119
-
120
-
Then **start.sh.patch** if appended at the end of the default startup scripts. Its goal is to check Rinkhals installation with minimal modification and run **start-rinkhals.sh**.
91
+
## Development
121
92
122
-
**start-rinkhals.sh** will now check for the requested version in **/useremain/rinkhals/.version**, check for a **.disable-rinkhals** file on a USB drive if needed and then run the actual Rinkhals loader for the selected version.
93
+
> [!WARNING]
94
+
> If you develop on Windows, like I'm doing, don't forget to disable Git's autocrlf function, as this repo contains Linux scripts running on Linux machines.<br />
95
+
> Run `git config core.autocrlf false`**BEFORE** cloning the repo
123
96
97
+
If you want to fully build this firmware yourself and avoid using the prebuilt binaries, Dockerfiles and build scripts are provided.
124
98
125
-
## Development
99
+
Now if you just want to tweak things and maybe fix some bugs or add new features, you will need either a Linux machine or a Windows machine with Docker.
126
100
127
-
If you want to fully build this firmware yourself and avoid using the prebuilt binaries, you will need to do the following:
101
+
Here are the steps:
102
+
- Clone the repo or Download the zip
103
+
- Do your modifications
104
+
- Open a terminal at the root of the repo, and run: `docker run --rm -it -e KOBRA_IP=x.x.x.x -v .\build:/build -v .\files:/files --entrypoint=/bin/sh rclone/rclone:1.68.2 /build/deploy-dev.sh`
128
105
129
-
- Layer 1: Buildroot (**files/1-buildroot**)
130
-
- Build and run `build/buildroot/Dockerfile` or start your own instance
131
-
- Some run examples are provider in the Dockerfile
132
-
- Use the `build/buildroot/.config` Buildroot configuration file to build the base filesystem binaries
133
-
- Use `build/buildroot/build-target.sh` to filter and extract the files in `/output`
106
+
This will create a "dev" version on your printer. Using the script above will synchronize your workspace with your PC.
107
+
Now you can start/restart your updated "dev" version using SSH:
108
+
-`chmod +x /useremain/rinkhals/dev/start.sh`
109
+
-`/useremain/rinkhals/dev/start.sh`
134
110
135
-
- Layer 2: External apps (**files/2-external**)
136
-
- Update git submodules
137
-
- Build **files/2-external/Dockerfile** if you want
138
-
-`docker run --rm -it -v .\build:/build -v .\files:/files ghcr.io/jbatonnet/rinkhals/build /build/2-external/get-external.sh`
111
+
I use VS Code for everything here, and it takes me about 30s~1m per iteration.
139
112
140
-
- Layer 3: Python packages for Moonraker (**files/3-python**)
141
-
- Build **files/3-python/Dockerfile** if you want
142
-
-`docker run --privileged --rm tonistiigi/binfmt --install all`
143
-
-`docker run --rm -it -v .\build:/build -v .\files:/files ghcr.io/jbatonnet/rinkhals/python /build/3-python/copy-output.sh`
113
+
If you ever want to create a full SWU with your version, use the `build-swu.sh` script with Docker, and you'll get your SWU in build/dist/update.swu:
If you want to quickly iterate on development, a quick deployment method is provided:
116
+
And if you want to keep things even simpler, fork the repo, do your modifications and push them. I provided some GitHub Actions to build the SWU for you:
117
+
- Go there (on your fork): https://github.com/jbatonnet/Rinkhals/actions/workflows/build-swu.yml
118
+
- Click "Run workflow", select your branch
119
+
- The SWU will be built and added as an artifact to your workflow
146
120
147
-
- To synchronize your copy of Rinkhals on the printer, run `docker run --rm -it -e KOBRA_IP=x.x.x.x -v .\build:/build -v .\files:/files --entrypoint=/bin/sh rclone/rclone:1.68.2 /build/deploy-dev.sh`
148
-
- On the printer, update **/useremain/rinkhals/.version** to `dev`
149
-
- On the printer, run `/useremain/rinkhals/start-rinkhals.sh` to manually start Rinkhals
121
+
If you're ever stuck, reboot, use the SSH SWU tool to regain SSH if you lost it, or reflash the last version if things don't work.
0 commit comments