[2.0.x] Add GTM32 Pro VB support#10898
[2.0.x] Add GTM32 Pro VB support#10898thinkyhead merged 2 commits intoMarlinFirmware:bugfix-2.0.xfrom
Conversation
|
Thanks! This will need to be rebased and cleaned up, but after I do that work it can be merged. |
6f90fab to
2f60502
Compare
Marlin/src/pins/pins_GTM32_PRO_VB.h
Outdated
| // | ||
| #define SDPOWER -1 | ||
| #define SDSS -1 | ||
| #define LED_PIN PD12 |
There was a problem hiding this comment.
Excuse me, what is this pin driving? Where physically on GTM32Pro board is this LED located? Can't find any on mine. Can see only voltage presence LEDs. Do you mind posting an photo?
There was a problem hiding this comment.
Not used, should be -1
Marlin/src/pins/pins_GTM32_PRO_VB.h
Outdated
|
|
||
| #define Y_STEP_PIN PA12 | ||
| #define Y_DIR_PIN PA11 | ||
| #define Y_ENABLE_PIN PA15 // core conflict? |
There was a problem hiding this comment.
What's this core conflict comment is about? I can't get Y and Z axis moving. Is this because of this "conflict"?
|
@chepo92 — Are there some changes that need to be applied to this pins file now that it's had some time out in the wild? |
|
Will come with a new PR for the LED pins, |
|
@thinkyhead, I'm going to post an updated pin file for this board soon (next weekend, I suppose). It will have all board's pins described. @chepo92, I'm using exactly Geeetech GTM32Pro board (the "VB" as you call it). It is STM32F103VE. |
|
@AlexanderAmelkin the pins are already updated on my repo, made a PR but was closed? (#11177) |
|
@chepo92, disabling JTAG doesn't help. Well, it enables PA15 (the Y_ENABLE_PIN), but PA11 and PA12 (Y_DIR_PIN and Y_STEP_PIN) remain non-functional. I believe that is related to rogerclarkmelbourne/Arduino_STM32#222, but I can't figure out how to properly disable USB for this board. |
|
Hi guys nice job. |
|
@redangel1984, it almost works except for the Y tower. Maybe there will be more problems, but now I'm stuck at that. |
|
@AlexanderAmelkin Check this http://stm32duino.com/viewtopic.php?t=1998.Some people made it work |
|
@AlexanderAmelkin |
|
@amitlobo, thanks for the update. Will check and report. Don't expect this soon, I don't have much time to spend on this. |
|
@amitlobo, defining Also, with the latest PlatformIO code it was forcing After modifying that wicked python script, I finally got the STEP (PA12) pin on Y axis working, but the DIR pin (PA11) is still non-functional. The axis moves one way only regardless of the requested direction. |
|
In case anyone is interested, here are my current changes to PlatformIO: diff -ur /tmp/.platformio/packages/framework-arduinoststm32/STM32F1/boards.txt .platformio/packages/framework-arduinoststm32/STM32F1/boards.txt
--- /tmp/.platformio/packages/framework-arduinoststm32/STM32F1/boards.txt 2018-09-10 00:39:12.181556517 +0300
+++ .platformio/packages/framework-arduinoststm32/STM32F1/boards.txt 2018-09-10 00:37:51.091715754 +0300
@@ -696,7 +696,8 @@
genericSTM32F103V.menu.upload_method.DFUUploadMethod=STM32duino bootloader
genericSTM32F103V.menu.upload_method.DFUUploadMethod.upload.protocol=maple_dfu
genericSTM32F103V.menu.upload_method.DFUUploadMethod.upload.tool=maple_upload
-genericSTM32F103V.menu.upload_method.DFUUploadMethod.build.upload_flags=-DSERIAL_USB -DGENERIC_BOOTLOADER
+#genericSTM32F103V.menu.upload_method.DFUUploadMethod.build.upload_flags=-DSERIAL_USB -DGENERIC_BOOTLOADER
+genericSTM32F103V.menu.upload_method.DFUUploadMethod.build.upload_flags=-DGENERIC_BOOTLOADER
genericSTM32F103V.menu.upload_method.DFUUploadMethod.build.vect=VECT_TAB_ADDR=0x8002000
genericSTM32F103V.menu.upload_method.DFUUploadMethod.build.ldscript=ld/stm32f103veDFU.ld
genericSTM32F103V.menu.upload_method.DFUUploadMethod.upload.usbID=1EAF:0003
@@ -710,7 +711,8 @@
genericSTM32F103V.menu.upload_method.STLinkMethod=STLink
genericSTM32F103V.menu.upload_method.STLinkMethod.upload.protocol=STLink
genericSTM32F103V.menu.upload_method.STLinkMethod.upload.tool=stlink_upload
-genericSTM32F103V.menu.upload_method.STLinkMethod.build.upload_flags=-DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1 -DSERIAL_USB -DGENERIC_BOOTLOADER
+#genericSTM32F103V.menu.upload_method.STLinkMethod.build.upload_flags=-DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1 -DSERIAL_USB -DGENERIC_BOOTLOADER
+genericSTM32F103V.menu.upload_method.STLinkMethod.build.upload_flags=-DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1 -DGENERIC_BOOTLOADER
genericSTM32F103V.menu.upload_method.BMPMethod=BMP (Black Magic Probe)
genericSTM32F103V.menu.upload_method.BMPMethod.upload.protocol=gdb_bmp
diff -ur /tmp/.platformio/packages/framework-arduinoststm32/STM32F1/cores/maple/boards.h .platformio/packages/framework-arduinoststm32/STM32F1/cores/maple/boards.h
--- /tmp/.platformio/packages/framework-arduinoststm32/STM32F1/cores/maple/boards.h 2018-09-10 00:47:42.666729301 +0300
+++ .platformio/packages/framework-arduinoststm32/STM32F1/cores/maple/boards.h 2018-09-09 23:37:16.210005273 +0300
@@ -168,7 +168,12 @@
* @brief Feature test: nonzero iff the board has SerialUSB.
*/
//Roger Clark. Change so that BOARD_HAVE_SERIALUSB is always true, so that it can be controller by -DSERIAL_USB
-#define BOARD_HAVE_SERIALUSB 1
+#ifdef SERIAL_USB // amelkin for gtm32
+ #warning "SERIAL_USB is set!"
+ #define BOARD_HAVE_SERIALUSB 1
+#else
+ #warning "SERIAL_USB is not set!"
+#endif
/*(defined(BOARD_USB_DISC_DEV) && defined(BOARD_USB_DISC_BIT))*/
diff -ur /tmp/.platformio/platforms/ststm32/builder/frameworks/arduino/maple/stm32f1.py .platformio/platforms/ststm32/builder/frameworks/arduino/maple/stm32f1.py
--- /tmp/.platformio/platforms/ststm32/builder/frameworks/arduino/maple/stm32f1.py 2018-09-10 00:48:13.150172460 +0300
+++ .platformio/platforms/ststm32/builder/frameworks/arduino/maple/stm32f1.py 2018-09-10 00:12:46.564431530 +0300
@@ -76,7 +76,7 @@
if upload_protocol not in ("dfu", "serial"):
env.Append(CPPDEFINES=[
("CONFIG_MAPLE_MINI_NO_DISABLE_DEBUG", 1),
- "SERIAL_USB",
+# "SERIAL_USB",
"GENERIC_BOOTLOADER"
]) |
|
@AlexanderAmelkin — Is that a universal solution for all STM32F1, or only applicable to your STM32F103VE? As an aside, Geeetech is working on getting Marlin working well on their STM32 boards so they can move away from Smartto. I'm not sure how much longer it will be before they share their work with us. |
|
Geeetech is working as a Smartto alternative for the users. They don’t want to move away from Smartto, just want to offer multiplatform compatibility for their board/printer. |
|
I see! Well, perhaps in future years they'll decide it's easier to maintain a single firmware. I'm sure Smartto is very good, but it probably doesn't receive as much love as this project. |
|
@thinkyhead, this is a universal solution for any STM32F1 board NOT using PA11/PA12 for USB Serial. So it is not universal actually. I personally find it utterly dumb to hard-code such things as certain function configurations or presence of certain peripherals on certain pins (or at all), such as this USB Serial thing or the error LED. But, alas! PlatformIO people apparently think different. ;) That my patch is just for reference. It wasn't indended as production grade (otherwise it would be a pull request). |
|
@thinkyhead, there is just one thing that is good about Smartto - it doesn't use any monstrous frameworks. It's purely CMSIS and SPL based. So it's a lot easier to understand and build. This very same thing is also its con: you can't use it on anything but STM32 (but that's fine with me). However, Smartto looks very feature-limited. |
|
After all this time and a number of updates to stm32duino, I still can't make PA11 work. Updates to stm32duino really enabled PA12 and it works as expected, but PA11 just doesn't react to any values in GPIOA ODR, always staying low, IIRC. I have checked CRL (MODE, CNF bits), even changed AFIO_MAPR bits 13:14 to remap CAN1 away from PA11. Didn't help. If anyone has any clues, I'd appreciate that. |
|
Sorry, in 2018 I went on a long trip around the world... By disabling JTAG I meant: Let's see how is this working with current Marlin code, last time I used the rostock and made this PR I had issues with the delta parameters and thermistor values. |
|
I also wasn't very expert using github, as I mentioned, #11177 had the corrections, but I did a mess with my base branch and trying to sync with the upstream |
|
the final workaround I did in 2018 was 3a479e7 #if MB(BOARD_GTM32_PRO_VB) |
Just to let everyone know. I found out that the reason was in burnt PA11 pin on my STM32. I think it got burned because my kids were moving the carets on a turned off printer and there are no diodes that would protect from reverse current. Anyway, replacing the MCU didn't help as the board is made of extremely low quality materials and all pads went off during resoldering. A new board's price at Geeetech is inadequately high for this quality and this amount of features, so I decided to go with BigTreeTech's SKR Pro v1.1. Thus I'm not interested in GTM32 Pro VB anymore. Thanks everyone for your help. |
Requirements
Description
Added pinmap of GTM32 Pro VB Support, basic functionality (no LCD+sdcard)
Benefits
New board support GTM32 Pro, used in Delta Rostock 301
Related Issues