@@ -7,6 +7,7 @@ Luban 和 Cura with SnapmakerPlugin 对于新手很友好,但是我的大部
7
7
## 功能
8
8
- 支持 Snapmaker 2 A/J1/Artisan 全系列打印机
9
9
- 自动发现局域网内所有的 Snapmaker 打印机(和 Luban 相同的协议,使用 UDP 广播)
10
+ - 模拟 OctoPrint Server,这样就可以在各种切片软件,比如 Cura/PrusaSlicer/SuperSlicer/ideaMaker 中向 Snapmaker 打印机发送文件
10
11
- Snapmaker 2 A-Series 第一次连接时需要授权,之后可以直接一步上传
11
12
- 支持 macOS/Windows/Linux/RaspberryPi 多个平台
12
13
@@ -15,18 +16,48 @@ Luban 和 Cura with SnapmakerPlugin 对于新手很友好,但是我的大部
15
16
- Linux/macOS 下,可能需要赋予可执行权限 ` chmod +x sm2uploader `
16
17
17
18
```
19
+ ## 自动查找模式
18
20
$ sm2uploader /path/to/code-file1 /path/to/code-file2
19
21
Discovering ...
20
22
Use the arrow keys to navigate: ↓ ↑ → ←
21
- ? Found 2 machines:
22
- ▸ A350-3DP@192.168.1.20 - Snapmaker 2 Model A350
23
- A250-CNC@192.168.1.18 - Snapmaker 2 Model A250
24
- J1V19@192.168.1.19 - Snapmaker J1
25
- Printer IP: 192.168.1.20
23
+ ? Found 3 machines:
24
+ ▸ A350-3DP@192.168.1.20 - Snapmaker A350
25
+ A250-CNC@192.168.1.18 - Snapmaker A250
26
+ J1V19@192.168.1.19 - Snapmaker-J1
27
+ Printer IP: 192.168.1.19
28
+ Printer Model: Snapmaker J1
29
+ Uploading file 'code-file1' [1.2 MB]...
30
+ - SACP sending 100%
31
+ Upload finished.
32
+
33
+ ## 指定 IP 连接模式
34
+ $ sm2uploader -host 192.168.1.19 /path/to/code-file1 /path/to/code-file2
35
+ Printer IP: 192.168.1.19
36
+ Printer Model: Snapmaker J1
37
+ Uploading file 'code-file1' [1.2 MB]...
38
+ - SACP sending 100%
39
+ Upload finished.
40
+
41
+ ## 指定打印机名字进行连接
42
+ $ sm2uploader -host J1V19 /path/to/code-file1 /path/to/code-file2
43
+ Discovering ...
44
+ Printer IP: 192.168.1.19
26
45
Printer Model: Snapmaker J1
27
46
Uploading file 'code-file1' [1.2 MB]...
28
47
- SACP sending 100%
29
48
Upload finished.
49
+
50
+ ## 模拟 OctoPrint (CTRL-C 终止运行)
51
+ $ sm2uploader -octoprint :8844 -host A350
52
+ Printer IP: 192.168.1.20
53
+ Printer Model: Snapmaker 2 Model A350
54
+ Starting OctoPrint server on :8844 ...
55
+ Server started, now you can upload files to http://localhost:8844
56
+ Request GET /api/version completed in 6.334µs
57
+ - HTTP sending 100.0%
58
+ Upload finished: model.gcode [382.2 KB]
59
+ Request POST /api/files/local completed in 951.080458ms
60
+ ...
30
61
```
31
62
32
63
打印机的 UDP 应答服务有时会挂掉,通常需要重启打印机来解决。或者你可以直接指定目标IP: ` sm2uploader -host 192.168.1.20 /file.gcode `
@@ -38,4 +69,4 @@ Upload finished.
38
69
## 在 macOS 系统提示文件无法打开的解决方法
39
70
macOS 不允许直接打开未经数字签名的程序,参考解决方案: https://osxdaily.com/2012/07/27/app-cant-be-opened-because-it-is-from-an-unidentified-developer/
40
71
41
- 也可以直接在终端执行 ` xattr -d com.apple.quarantine sm2uploader-darwin `
72
+ 也可以直接在终端执行 ` xattr -d com.apple.quarantine sm2uploader-darwin `
0 commit comments