Browse Source

Merge pull request #9153 from thinkyhead/bf2_malyan_support

[2.0.x] Fix support for Malyan M150
Scott Lahteine 6 years ago
parent
commit
3b15c88225
No account linked to committer's email address

+ 1
- 1
Marlin/src/config/examples/Malyan/M150/Configuration.h View File

@@ -133,7 +133,7 @@
133 133
 // The following define selects which electronics board you have.
134 134
 // Please choose the name from boards.h that matches your setup
135 135
 #ifndef MOTHERBOARD
136
-  #define MOTHERBOARD BOARD_MELZI
136
+  #define MOTHERBOARD BOARD_MELZI_MALYAN
137 137
 #endif
138 138
 
139 139
 // Optional custom name for your RepStrap or other custom machine

+ 55
- 3
Marlin/src/config/examples/Malyan/M150/README.md View File

@@ -1,3 +1,55 @@
1
-# Configuration for Malyan M150 hobbyking printer
2
-# config without automatic bed level sensor
3
-# or in other words, "as stock"
1
+# Configuration for Malyan M150 HobbyKing printer
2
+
3
+Config without automatic bed level sensor, or in other words, "as stock"
4
+
5
+## To install:
6
+
7
+1. Install [Arduino](https://www.arduino.cc/en/Main/Software)
8
+
9
+1. Install U8glib
10
+    * `Sketch` -> `Include Library` -> `Manage Libraries...`
11
+    * Search for and install `U8glib` by oliver
12
+
13
+1. Install Sanguino
14
+    * `File` -> `Preferences`
15
+    * Add
16
+    `https://raw.githubusercontent.com/Lauszus/Sanguino/master/package_lauszus_sanguino_index.json`
17
+    to `Additional Boards Manager URLs`
18
+
19
+1. Modify Sanguino `boards.txt`
20
+    * Close Arduino
21
+    * Locate Arduino15 folder
22
+        - `C:\Users\<username>\AppData\Local\Arduino15` for Windows
23
+        - `~/.arduino15` for Linux
24
+
25
+    * Locate `boards.txt` in `packages/Sanguino/hardware/avr/1.0.2`
26
+    (version number may change)
27
+    * Add the following to the end of `boards.txt`
28
+    (note that it is the same as sanguino.menu.cpu.atmega1284p but with
29
+    a different name and upload speed)
30
+
31
+            ## Malyan M150 W/ ATmega1284P 16MHz
32
+            sanguino.menu.cpu.malyan_m150=Malyan M150
33
+            sanguino.menu.cpu.malyan_m150.upload.maximum_size=130048
34
+            sanguino.menu.cpu.malyan_m150.upload.maximum_data_size=16384
35
+            sanguino.menu.cpu.malyan_m150.upload.speed=57600
36
+            sanguino.menu.cpu.malyan_m150.bootloader.file=optiboot/optiboot_atmega1284p.hex
37
+            sanguino.menu.cpu.malyan_m150.build.mcu=atmega1284p
38
+            sanguino.menu.cpu.malyan_m150.build.f_cpu=16000000L
39
+
40
+1. Configure Marlin
41
+    * Copy `_Bootscreen.h`, `Configuration.h`, and `Configuration_adv.h`
42
+    from `Marlin/config/examples/Malyan/M150` to `Marlin`
43
+    (overwrite files)
44
+    * Read `Configuration.h` and make any necessary changes
45
+
46
+1. Flash Marlin
47
+    * Turn on printer while pressing scroll wheel button
48
+    * Plug printer in to computer with USB cable
49
+    * Open `Marlin/Marlin.ino` with Arduino
50
+    * Configure Arduino
51
+        - `Tools` -> `Board` -> `Sanguino`
52
+        - `Tools` -> `Processor` -> `Malyan M150`
53
+        - `Tools` -> `Port` -> Select your port
54
+
55
+    * `Sketch` -> `Upload` or click arrow in top right corner

+ 1
- 0
Marlin/src/core/boards.h View File

@@ -114,6 +114,7 @@
114 114
 #define BOARD_MELZI             63    // Melzi
115 115
 #define BOARD_MELZI_MAKR3D      66    // Melzi with ATmega1284 (MaKr3d version)
116 116
 #define BOARD_MELZI_CREALITY    89    // Melzi Creality3D board (for CR-10 etc)
117
+#define BOARD_MELZI_MALYAN      92    // Melzi Malyan M150 board
117 118
 #define BOARD_STB_11            64    // STB V1.1
118 119
 #define BOARD_AZTEEG_X1         65    // Azteeg X1
119 120
 

+ 2
- 0
Marlin/src/pins/pins.h View File

@@ -193,6 +193,8 @@
193 193
   #include "pins_MELZI_MAKR3D.h"      // ATmega644P, ATmega1284P
194 194
 #elif MB(MELZI_CREALITY)
195 195
   #include "pins_MELZI_CREALITY.h"    // ATmega644P, ATmega1284P
196
+#elif MB(MELZI_MALYAN)
197
+  #include "pins_MELZI_MALYAN.h"      // ATmega644P, ATmega1284P
196 198
 #elif MB(STB_11)
197 199
   #include "pins_STB_11.h"            // ATmega644P, ATmega1284P
198 200
 #elif MB(AZTEEG_X1)

+ 50
- 0
Marlin/src/pins/pins_MELZI_MALYAN.h View File

@@ -0,0 +1,50 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4
+ *
5
+ * Based on Sprinter and grbl.
6
+ * Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
+ * GNU General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License
19
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
20
+ *
21
+ */
22
+
23
+/**
24
+ * Melzi (Malyan M150) pin assignments
25
+ */
26
+
27
+#define BOARD_NAME "Melzi (Malyan)"
28
+#define IS_MELZI
29
+
30
+#include "pins_SANGUINOLOLU_12.h"
31
+
32
+#undef LCD_SDSS
33
+#undef LCD_PINS_RS
34
+#undef LCD_PINS_ENABLE
35
+#undef LCD_PINS_D4
36
+#undef BTN_EN1
37
+#undef BTN_EN2
38
+#undef BTN_ENC
39
+
40
+#define LCD_PINS_RS     17 // st9720 CS
41
+#define LCD_PINS_ENABLE 16 // st9720 DAT
42
+#define LCD_PINS_D4     11 // st9720 CLK
43
+#define BTN_EN1         30
44
+#define BTN_EN2         29
45
+#define BTN_ENC         28
46
+
47
+// Alter timing for graphical display
48
+#define ST7920_DELAY_1 DELAY_2_NOP
49
+#define ST7920_DELAY_2 DELAY_2_NOP
50
+#define ST7920_DELAY_3 DELAY_2_NOP

Loading…
Cancel
Save