Browse Source

Add Einstart-S support (#11219)

Indeed the HAL does not need to be mucked around with to expose ATmega2560 pins not available as numbers on the MEGA board, I'll need to update the wiki with that tidbit and a reference to the pin-mapping comment in `fastio_1280.h`.
Lee Olivares 6 years ago
parent
commit
094e6d81a5

+ 1945
- 0
Marlin/src/config/examples/Einstart-S/Configuration.h
File diff suppressed because it is too large
View File


+ 1728
- 0
Marlin/src/config/examples/Einstart-S/Configuration_adv.h
File diff suppressed because it is too large
View File


+ 152
- 0
Marlin/src/config/examples/Einstart-S/readme.md View File

@@ -0,0 +1,152 @@
1
+## Einstart S Machine Notes
2
+
3
+The Einstart S is a commercial machine that ships with a proprietary firmware and "licensed" slicer program which requires the original SD card or license file (.lic/.reg) from support in order to function. The impetus for the port was that I acquired the machine on the weekend when tech support was closed.
4
+
5
+## Specifications:
6
+
7
+ - Powder coated, formed steel enclosure
8
+ - Machined Aluminum internal axis support frame
9
+ - Genuine matched HIWIN rails on all axis
10
+ - Genuine Minebea NEMA17 motors (200 steps/rev)
11
+ - THC7128 3A Stepper Drivers (configured for 16 microsteps, loud)
12
+ - 160x160 magnetically coupled non-heated bed
13
+ - PLA Only Direct Drive extruder
14
+ - SH1106 OLED Display w/ Cardinal navigation
15
+ - 9533 I2C PWM RGB LED Chassis illumination
16
+ - Onboard SD-Card Support
17
+
18
+## Initial modifications
19
+
20
+### Bootloader/Marlin installation
21
+
22
+This machine probably doesn't ship with the arduino boot loader, so unless you reflow a 2560 on there to replace the atmega1280 like I did (to preserve the original firmware), you'll need to use ISP to do an initial firmware load and/or bootloader flash!
23
+
24
+It's not that bad though, you can just buy an ISP programmer with the appropriate header, or build an ISP programmer using the Arduino ISP sketch (wiring is easier if you use the "old style wiring" which utilizes  the following pinout: (see the comments in the ArduinoISP sketch).
25
+
26
+I used an arduino Nano and a header I had lying around, but you could do the same with a nano and some dupont headers cut and soldered to the board, and taped/glued into a header.
27
+
28
+Triple check your pinouts, it shouldn't fry if connected backwards but if your pinout is wrong you're going to struggle for sure.
29
+
30
+#### ArduinoISP Sketch pinout for 10pin ISP header using "old style wiring":
31
+
32
+See the comments in the ArduinoISP sketch under File:Examples:ArduinoISP
33
+
34
+1 MOSI  D11
35
+2 5v    Vcc
36
+3 N/C
37
+4 GND
38
+5 RES   D10
39
+6 N/C
40
+7 SCK   D13
41
+8 N/C
42
+9 MISO  D12
43
+10 GND  GND
44
+
45
+#### Einstart Motherboard ISP Header Pinout
46
+
47
+The 10 pin ISP Header is located to the right of the ATMEGA chip, just above the long LCD header.
48
+
49
+#### ISP Diagram
50
+
51
+<--- Face of chassis
52
+
53
+MOSI ( 1 ) ( 2 ) Vcc
54
+ N/C ( 3 ) ( 4 ) GND
55
+ RST ( 5 ) ( 6 ) GND
56
+ SCK ( 7 ) ( 8 ) GND
57
+MISO ( 9 ) (10 ) GND
58
+
59
+Component Plugs --->
60
+
61
+### Motherboard Diagram
62
+
63
+ |1234|1234|1234|1234|12|12|12|12|12|12|12|12|12|12|123|12|1234|
64
+ ---------------------------------------------------------------
65
+| XMOT YMOT ZMOT EMOT EF HB HE PF ZS YS XS PS BT ET PT1 TC VBRG |
66
+|     =====     ======                                       [DC|
67
+|======    ======              ____     ISP          IC1__   ___|
68
+|                             |1280|   :::::           |  | |USB|
69
+|                             |____|   1               |__| |___|
70
+|                         BUTTON                            |SD |
71
+|                         GDLRUO  LCD                       |___|
72
+|________________________[......][....................]_________|
73
+
74
+Legend:
75
+
76
+XMOT    X-Motor
77
+YMOT    Y-Motor
78
+ZMOT    Z-Motor
79
+EMOT    E-Motor
80
+EF      Extruder Fan
81
+HB      Heated Bed  (PWM)
82
+HE      Hot End     (PWM)
83
+PF      Part Fan    (PWM)
84
+ZS      Z-Endstop   (Max)
85
+YS      Y-Endstop   (Min)
86
+XS      X-Endstop   (Min)
87
+PS      SPST Switch to enable DC 24v 
88
+BT      Bed Thermistor (header not populated)
89
+ET      Extruder Thermistor
90
+PT1     PT100 Thermocouple (not populated)
91
+TC      Thermocouple (not populated)
92
+VBRG    LED Output from PCA5933
93
+BUTTONS
94
+G       GND  (buttons are pulled low on activation)
95
+D       DOWN
96
+L       LEFT
97
+R       RIGHT
98
+U       UP
99
+O       OK   (MIDDLE)
100
+
101
+## Uploading Marlin firmware to a stock Einstart S
102
+
103
+### Summary:
104
+
105
+Make, buy or steal a 10 pin ISP programmer and select the appropriate programmer option via Tools:Programmer in Arduino IDE, use the Sketch:Upload Using Programmer command or Shift-Ctrl-U (vs Ctrl-U to upload via serial).
106
+
107
+### Detailed procedure:
108
+
109
+You can either load Marlin directly via ISP programmer (easiest, but requires opening the chassis every time you want to change/update firmware)  or, just program the bootloader which will enable later uploads via USB. HOWEVER, to actually upload the sketch you will need one of the following:
110
+
111
+ - ISP programming header (ArduinoISP sketch, pinout below)
112
+ - OR
113
+ - Install bootloader on atmega1280 to enable native USB uploads (also requires ISP).
114
+ - AND
115
+ - Connect button between RESET and GND on ISP header, release post compile just before upload starts.
116
+ - OR
117
+ - Install permanent modification described below, requires no button press during upload.
118
+
119
+### Permanent modification to enable USB uploads via Arduino IDE
120
+
121
+As a permanent modification to enable direct USB upload from the arduino IDE, you would need to flash the boot loader using ISP first; but then you can solder a wire or 100n capacaitor between the DTR line on the FTDI to the reset line, which is conveniently located in several places on the board.
122
+
123
+#### FTDI Chip Diagram (IC1)
124
+
125
+           ______
126
+   TXD  --|1   28|--OSCO
127
+   DTR  --|2   27|--OSCI
128
+   RTS  --|3   26|--TEST
129
+   VCCIO--|4   25|--AGND
130
+   RXD  --|5   24|--N/C
131
+   RI   --|6   23|--CBUS0
132
+   GND  --|7   22|--CBUS1
133
+   N/C  --|8   21|--GND
134
+   DSR  --|9   20|--Vcc
135
+   DCD  --|10  19|--RES
136
+   CTS  --|11  18|--GND
137
+   CBUS4--|12  17|--3V3
138
+   CBUS2--|13  16|--USBDM
139
+   CBUS3--|14  15|--USBDP
140
+          |______|
141
+
142
+#### Arduino Reset Circuit
143
+
144
+   DTR-----||----GND----/\/\/\/----Vcc
145
+          100nf           10k
146
+
147
+With this modification you no longer need the reset button and you can program directly from the Arduino IDE.
148
+
149
+### Power notes during flashing.
150
+
151
+You do NOT need power connected when flashing via ISP.
152
+You DO need power when flashing via USB Serial but you MUST time the release of the reset line to allow the upload unless you've performed the permanent modification.

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

@@ -104,6 +104,7 @@
104 104
 #define BOARD_SCOOVO_X9H        321   // abee Scoovo X9H
105 105
 #define BOARD_GT2560_REV_A      74    // Geeetech GT2560 Rev. A
106 106
 #define BOARD_GT2560_REV_A_PLUS 75    // Geeetech GT2560 Rev. A+ (with auto level probe)
107
+#define BOARD_EINSTART_S        666   // Einstart retrofit
107 108
 
108 109
 //
109 110
 // ATmega1281, ATmega2561

+ 12
- 0
Marlin/src/inc/Conditionals_LCD.h View File

@@ -202,6 +202,18 @@
202 202
 #endif
203 203
 
204 204
 /**
205
+ * SPI PANELS
206
+ */
207
+
208
+ // Einstart OLED has Cardinal nav via pins defined in pins_EINSTART-S.h
209
+ #if ENABLED(U8GLIB_SH1106_EINSTART)
210
+   #define ULTRA_LCD
211
+   #define DOGLCD
212
+   #define ULTIPANEL
213
+   #define NEWPANEL
214
+ #endif
215
+
216
+/**
205 217
  * I2C PANELS
206 218
  */
207 219
 

+ 2
- 0
Marlin/src/lcd/thermistornames.h View File

@@ -94,6 +94,8 @@
94 94
   #define THERMISTOR_NAME "PT100 4K7"
95 95
 #elif THERMISTOR_ID == 110
96 96
   #define THERMISTOR_NAME "PT100 1K"
97
+#elif THERMISTOR_ID == 666
98
+  #define THERMISTOR_NAME "Einstart S"
97 99
 
98 100
 // High Temperature thermistors
99 101
 #elif THERMISTOR_ID == 66

+ 3
- 0
Marlin/src/lcd/ultralcd_impl_DOGM.h View File

@@ -181,6 +181,9 @@
181 181
   // The MINIPanel display
182 182
     //U8GLIB_MINI12864 u8g(DOGLCD_CS, DOGLCD_A0);  // 8 stripes
183 183
     U8GLIB_MINI12864_2X u8g(DOGLCD_CS, DOGLCD_A0); // 4 stripes
184
+#elif ENABLED(U8GLIB_SH1106_EINSTART)
185
+  // Connected via motherboard header
186
+  U8GLIB_SH1106_128X64 u8g(DOGLCD_SCK, DOGLCD_MOSI, DOGLCD_CS, LCD_PINS_DC, LCD_PINS_RS);    
184 187
 #else
185 188
   // for regular DOGM128 display with HW-SPI
186 189
     //U8GLIB_DOGM128 u8g(DOGLCD_CS, DOGLCD_A0);  // HW-SPI Com: CS, A0  // 8 stripes

+ 98
- 0
Marlin/src/module/thermistor/thermistor_666.h View File

@@ -0,0 +1,98 @@
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
+ * This file was generated by tltgen on Thu Jul  5 15:46:43 2018.
25
+ * tltgen was created by Pieter Agten (pieter.agten@gmail.com).
26
+ */
27
+//#include "output_table.h"
28
+
29
+/*
30
+ * Parameters:
31
+ * A: -0.000480634
32
+ * B: 0.00031362
33
+ * C: -2.03978e-07
34
+ */
35
+#define NUMTEMPS 61
36
+const short temptable_666[NUMTEMPS][2] PROGMEM = {
37
+  { OV(  1), 794 },
38
+  { OV( 18), 288 },
39
+  { OV( 35), 234 },
40
+  { OV( 52), 207 },
41
+  { OV( 69), 189 },
42
+  { OV( 86), 176 },
43
+  { OV(103), 166 },
44
+  { OV(120), 157 },
45
+  { OV(137) ,150 },
46
+  { OV(154), 144 },
47
+  { OV(172), 138 },
48
+  { OV(189), 134 },
49
+  { OV(206), 129 },
50
+  { OV(223), 125 },
51
+  { OV(240), 121 },
52
+  { OV(257), 118 },
53
+  { OV(274), 115 },
54
+  { OV(291), 112 },
55
+  { OV(308), 109 },
56
+  { OV(325), 106 },
57
+  { OV(342), 103 },
58
+  { OV(359), 101 },
59
+  { OV(376),  99 },
60
+  { OV(393),  96 },
61
+  { OV(410),  94 },
62
+  { OV(427),  92 },
63
+  { OV(444),  90 },
64
+  { OV(461),  88 },
65
+  { OV(478),  86 },
66
+  { OV(495),  84 },
67
+  { OV(512),  82 },
68
+  { OV(530),  80 },
69
+  { OV(547),  78 },
70
+  { OV(564),  76 },
71
+  { OV(581),  74 },
72
+  { OV(598),  72 },
73
+  { OV(615),  70 },
74
+  { OV(632),  68 },
75
+  { OV(649),  67 },
76
+  { OV(666),  65 },
77
+  { OV(683),  63 },
78
+  { OV(700),  61 },
79
+  { OV(717),  59 },
80
+  { OV(734),  57 },
81
+  { OV(751),  55 },
82
+  { OV(768),  53 },
83
+  { OV(785),  51 },
84
+  { OV(802),  49 },
85
+  { OV(819),  47 },
86
+  { OV(836),  44 },
87
+  { OV(853),  42 },
88
+  { OV(871),  39 },
89
+  { OV(888),  37 },
90
+  { OV(905),  34 },
91
+  { OV(922),  30 },
92
+  { OV(939),  27 },
93
+  { OV(956),  23 },
94
+  { OV(973),  18 },
95
+  { OV(990),  11 },
96
+  { OV(1007),  2 },
97
+  { OV(1023),-25 }
98
+};

+ 4
- 1
Marlin/src/module/thermistor/thermistors.h View File

@@ -100,7 +100,7 @@
100 100
 #if ANY_THERMISTOR_IS(60) // beta25 = 3950 K, R25 = 100 kOhm, Pull-up = 4.7 kOhm, "Maker's Tool Works Kapton Bed"
101 101
   #include "thermistor_60.h"
102 102
 #endif
103
-#if ANY_THERMISTOR_IS(66) // beta25 = 4500 K, R25 = 2.5 MOhm, Pull-up = 4.7 kOhm, "DyzeDesign 500 °C Thermistor"
103
+#if ANY_THERMISTOR_IS(66) // beta25 = 4500 K, R25 = 2.5 MOhm, Pull-up = 4.7 kOhm, "DyzeDesign 500 °C Thermistor"
104 104
   #include "thermistor_66.h"
105 105
 #endif
106 106
 #if ANY_THERMISTOR_IS(12) // beta25 = 4700 K, R25 = 100 kOhm, Pull-up = 4.7 kOhm, "Personal calibration for Makibox hot bed"
@@ -118,6 +118,9 @@
118 118
 #if ANY_THERMISTOR_IS(147) // Pt100 with 4k7 pullup
119 119
   #include "thermistor_147.h"
120 120
 #endif
121
+#if ANY_THERMISTOR_IS(666) // beta25 = UNK, R25 = 200K, Pull-up = 10 kOhm, "Unidentified 200K NTC thermistor (Einstart S)"
122
+  #include "thermistor_666.h"
123
+#endif
121 124
 #if ANY_THERMISTOR_IS(1010) // Pt1000 with 1k0 pullup
122 125
   #include "thermistor_1010.h"
123 126
 #endif

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

@@ -183,6 +183,8 @@
183 183
   #include "pins_GT2560_REV_A.h"      // ATmega1280, ATmega2560                     env:megaatmega1280 env:megaatmega2560
184 184
 #elif MB(GT2560_REV_A_PLUS)
185 185
   #include "pins_GT2560_REV_A_PLUS.h" // ATmega1280, ATmega2560                     env:megaatmega1280 env:megaatmega2560
186
+#elif MB(EINSTART_S)
187
+  #include "pins_EINSTART-S.h"        // ATmega1280, ATmega2560                     env:megaatmega1280 env:megaatmega2560
186 188
 
187 189
 //
188 190
 // ATmega1281, ATmega2561

+ 122
- 0
Marlin/src/pins/pins_EINSTART-S.h View File

@@ -0,0 +1,122 @@
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
+ * Einstart S pin assignments
25
+ * PCB Silkscreen: 3DPrinterCon_v3.5
26
+ */
27
+
28
+#if ENABLED(TARGET_LPC1768)
29
+  #error "Oops!  Set MOTHERBOARD to an LPC1768-based board when building for LPC1768."
30
+#elif defined(__STM32F1__)
31
+  #error "Oops!  Set MOTHERBOARD to an STM32F1-based board when building for STM32F1."
32
+#endif
33
+
34
+#if DISABLED(IS_RAMPS_SMART) && DISABLED(IS_RAMPS_DUO) && DISABLED(IS_RAMPS4DUE) && DISABLED(TARGET_LPC1768)
35
+  #if !defined(__AVR_ATmega1280__) && !defined(__AVR_ATmega2560__)
36
+    #error "Oops!  Make sure you have 'Arduino Mega' selected from the 'Tools -> Boards' menu."
37
+  #endif
38
+#endif
39
+
40
+#ifndef BOARD_NAME
41
+  #define BOARD_NAME "EINSTART_S"
42
+#endif
43
+
44
+//
45
+// Limit Switches
46
+//
47
+#define X_STOP_PIN         44   // 2560 PIN 40
48
+#define Y_STOP_PIN         43   // 2560 PIN 41 
49
+#define Z_STOP_PIN         42   // 2560 PIN 42
50
+
51
+//
52
+// Steppers
53
+//
54
+#define X_STEP_PIN         76   // 2560 PIN 68
55
+#define X_DIR_PIN          75   // 2560 PIN 67
56
+#define X_ENABLE_PIN       73   // 2560 PIN 66
57
+
58
+#define Y_STEP_PIN         31   // 2560 PIN 59
59
+#define Y_DIR_PIN          32   // 2560 PIN 58
60
+#define Y_ENABLE_PIN       72   // 2560 PIN 65
61
+
62
+#define Z_STEP_PIN         34   // 2560 PIN 56
63
+#define Z_DIR_PIN          35   // 2560 PIN 55
64
+#define Z_ENABLE_PIN       33   // 2560 PIN 57
65
+
66
+#define E0_STEP_PIN        36   // 2560 PIN 54
67
+#define E0_DIR_PIN         37   // 2560 PIN 53
68
+#define E0_ENABLE_PIN      30   // 2560 PIN 60
69
+
70
+//
71
+// Temperature Sensors
72
+//
73
+#define TEMP_0_PIN          0   // Analog Input
74
+#define TEMP_BED_PIN        1   // Analog Input
75
+
76
+//
77
+// Heaters / Fans
78
+//
79
+#define HEATER_0_PIN       83   // 2560 PIN 49
80
+#define HEATER_BED_PIN     38   // 2560 PIN 50
81
+
82
+#define FAN_PIN            82   // 2560 PIN 48
83
+
84
+//
85
+// Misc. Functions
86
+//
87
+#define SDSS               53   // 2560 PIN 19
88
+#define LED_PIN             4   // 2560 PIN 1
89
+
90
+//////////////////////////
91
+// LCDs and Controllers //
92
+//////////////////////////
93
+
94
+//
95
+// LCD Display output pins
96
+//
97
+
98
+// Requires #define U8GLIB_SH1106_EINSTART in Configuration.h
99
+// u8glib constructor
100
+// U8GLIB_SH1106_128X64 u8g(DOGLCD_SCK, DOGLCD_MOSI, DOGLCD_CS, LCD_PINS_DC, LCD_PINS_RS);
101
+
102
+#define LCD_PINS_DC        78   // 2560 PIN 4
103
+#define LCD_PINS_RS        79   // 2560 PIN 8
104
+// DOGM SPI LCD Support
105
+#define DOGLCD_CS           3   // 2560 PIN 7
106
+#define DOGLCD_MOSI         2   // 2560 PIN 6
107
+#define DOGLCD_SCK          5   // 2560 PIN 5
108
+#define DOGLCD_A0           2   // 2560 PIN 6
109
+
110
+//
111
+// LCD Display input pins
112
+//
113
+#define BTN_UP             25   // 2560 PIN 75
114
+#define BTN_DWN            26   // 2560 PIN 74
115
+#define BTN_LFT            27   // 2560 PIN 73
116
+#define BTN_RT             28   // 2560 PIN 72
117
+
118
+// 'OK' button
119
+#define BTN_ENC            29   // 2560 PIN 71
120
+
121
+// Set Kill to right arrow, same as RIGID_PANEL
122
+#define KILL_PIN           28   // 2560 PIN 72

Loading…
Cancel
Save