-
-
Notifications
You must be signed in to change notification settings - Fork 19.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update ststm32 to 8.0 for HAL/STM32 #18496
Update ststm32 to 8.0 for HAL/STM32 #18496
Conversation
I've updated the description to include soem sanity checks I've performed on a GTR V1.0. |
I was able to boot on some Malyan board I have. I messed up my bootloader, but managed to get something on there and write the firmware using a DFU connection over USB. This appears to be an "M200 v1" board, but has an STM32F070CB (Like the M300). I don't think the pinout exactly matches anything in Marlin right now, but I was able to move a motor and verify that endstop pins work, at least. |
@rudihorn - I think some of your work on feature request 18157 parallels this PR. |
I’m hoping that this can go in soon after the next tagged release, so people can start building features on top of the latest framework. 1.8 was full of bugs that had to be worked around, but so far 1.9 seems better. |
If you have an M200 mainboard and it has an 070 MCU on it, it's a V2. There's a very small number of V2s which have F103 processors on them (and an even smaller, like, possibly a handful) of M300 boards that have an 103. Does it reboot after 8 seconds? If not, it's in decent shape. |
@xC0000005 I have an M200 with an 070CB (I think the one in the platformio is an 070RB). There is a surprisingly huge number of variants of these boards.... |
Six that I know of, possibly more, but they haven’t changed the pinouts since the M100 (and it was likely derived from whatever CNC controller the M100 was extended from). The M300 is a different beast, and the new STM32F4 boards are even more different (but they run an official fork of Marlin). Now that Malyan has released their source, adding support should be easy.
… On Jul 2, 2020, at 3:45 PM, Jason Smith ***@***.***> wrote:
@xC0000005 <https://github.com/xC0000005> I have an M200 with an 070CB (I think the one in the platformio is an 070RB).
I also have another with an F103, but I haven't even even powered that one on yet. These were used boards I picked up cheap on eBay. I destroyed the original board from my Mini a long time ago.
There is a surprisingly huge number of variants of these boards....
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#18496 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AHVGS4JRL4LKDM6DWXYGYR3RZUEXDANCNFSM4OOS57QA>.
|
Did they release bootloader source by any chance? I accidentally erased mine, and I'm using someone's open-source bootloader I found on github, but I doubt it is capable of updating firmware from SD. |
Not that I saw, but I’ll share my “recalculate” sketch. If you look at any of the M200 bootlaoders (you can grab the one Mickey uploaded to the marlin 4 mp mini delta project) in a hex editor, at the very end is the string “M200” and a series of bytes. The four bytes after the M200 are a weird byte swapped CRC that is calculated from the CPU ID to tie the boot loader to a batch. If you’re going to run marlin and marlin alone, you can ignore ever patching it - just restore the boot loader. Marlin doesn’t care, and while I knew there was a shared layout section, I never bothered implementing support for it. Also, all the M200 variants really need is the systick turned off before we begin any form of copy over.
So, in short - want Marlin only? Just throw the 070 bsotloader on. It’ll calculate the “wrong” CRC but still run. Want to run their stock crap? I’ll share how to patch it.
… On Jul 2, 2020, at 4:06 PM, Jason Smith ***@***.***> wrote:
Did they release bootloader source by any chance? I accidentally erased mine, and I'm using someone's open-source bootloader I found on github, but I doubt it is capable of updating firmware from USB.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#18496 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AHVGS4LKDPWWLD2IJM2Y2RTRZUHG3ANCNFSM4OOS57QA>.
|
I'll get my MK3S/BTT002 build running on this and run some test prints this weekend if the PR isn't merged before then. |
I certainly hope this is not merged before the 2.0.6 release, and people test some actual prints with it. |
I just instrumented Marlin and the framework's SoftwareSerial for an SKR Pro to verify that the preemption of ISRs is behaving as expected. This was measured by instrumenting each ISR to set output lines high while active, and capturing the behavior on a logic analyzer. |
I've got some hardware changes to do (dual Z stepper and a new lcd) after i get those verified working ill pull this and test on the SKR Pro 1.1 with 5 2209's and BLTouch |
Just dropping this in here as per our discussion. SKR Pro V1.1 no longer passes sanity checks for PWM on extruder auto pans if the speed is set to anything other than 255. This may be related to STM32 missing #ifndef digitalPinHasPWM Which is missing out of STM32 HALL.H, i tried adding it but it still errors so their are deeper issues. Commenting out In Marlin/src/inc/sanitycheck.h is a work around Log Exerpt from VS Code
|
@GhostlyCrowd posted a PR for the SanityCheck issue above, so I won't be spending time on that. |
There are at least two issues on the Rumba32.
I haven't done much else with the Rumba32. The following seem to work:
|
Actually, I take back my comment that I thought I had fan PWM working at 20 kHz earlier on the Rumba32. When I look at my comments on #17519 I am only very clear that I had it working at 1Khz. |
This might be a significant issue for boards such as the Rumba32, which are commonly used inside the Arduino IDE. We can more readily control how things build in PlatformIO. I am no expert at building in Arduino, but I assume people would have to go hand edit board definitions or variants to override the default behavior. The good news is that I have been able to build and upload firmware easily from PlatformIO, at least for my MKS Rumba32. I assume it would work the same for the original Aus3D version. |
I think its about time Marlin drops support for Arduino IDE in my opinion, we have to move forward eventually and it has a laundry list of issues on a good day. their are multiple options to use PIO and VS code is very easy to use for example. |
I merged this branch with my Lerdge + LCD branch. Thermistors are working, motors “run” but I need to get it installed in a real printer to validate. I had to add a -I to put the HALSTM32 directory back in the include list, other than that it mostly just worked on merge. I2C EEPROM now works where before it hung.
… On Jul 4, 2020, at 1:21 PM, GhostlyCrowd ***@***.***> wrote:
SERIAL_TIMER is overridden in the pins file, but that is no longer possible
Will need to be overridden in variants.h or platformio.ini
This might be a significant issue for boards such as the Rumba32, which are commonly used inside the Arduino IDE. We can more readily control how things build in PlatformIO. I am no expert at building in Arduino, but I assume people would have to go hand edit board definitions or variants to override the default behavior.
The good news is that I have been able to build and upload firmware easily from PlatformIO, at least for my MKS Rumba32. I assume it would work the same for the original Aus3D version.
I think its about time Marlin drops support for Arduino IDE in my opinion, we have to move forward eventually and it has a laundry list of issues on a good day. their are multiple options to use PIO and VS code is very easy to use for example.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#18496 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AHVGS4MHA66IRBUJN4WQA53RZ6FNBANCNFSM4OOS57QA>.
|
@xC0000005 what is the include path needed for? I had originally added that for SoftwareSerial (which is now gone). Lerdge must need something else? Feel free to post a PR to my branch if you have any changes that should be included prior to this merging. If it is something that is already broken in the bugfix branch then it could just as easily be a separate PR later. |
It’s because I’m combining three different PRs together. The tft PR uses it to pick up the right instance of the TFT class. All I did was stick -IMarlin/src/HAL/STM32
into the common STM32 environment flags. Once I do a few prints I’ll report back, and anyone who chooses to test the ledge functionality will be using it, too.
… On Jul 4, 2020, at 3:06 PM, Jason Smith ***@***.***> wrote:
@xC0000005 <https://github.com/xC0000005> what is the include path needed for? I had originally added that for SoftwareSerial (which is now gone). Lerdge must need something else?
Feel free to post a PR to my branch if you have any changes that should be included prior to this merging. If it is something that is already broken in the bugfix branch then it could just as easily be a separate PR later.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#18496 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AHVGS4IQIQIZWOKVHZJA6GLRZ6RU3ANCNFSM4OOS57QA>.
|
@thinkyhead how would you like to proceed with this? I'm not sure whether you would plan to squash this in, or merge it with its commit history. If you aren't squashing it I can rebase it and consolidate the changes into a more coherent set of incremental changes. |
After @GhostlyCrowd's report of some BLTouch issues I just did 200 probes without any issues on an SKR Pro. I still suspect perhaps a wiring/connector issue on their printer, unless there is some issue that occurs at power-on that prevents the BLTouch from working? |
It hasn't happened since i replaced the wiring and the pin as it was bent badly after the last crash, to be safe not sure, what happened but its safe to say its nothing related to this pr |
All is well here. Still think this is ready to merge. My issues were my own. Did a repeatability with 200 probes fine. UBL built and verified a mesh fine and I just completed a 16 hour print. Once this is merged ill test your other PR @sjasonsmith, but Ii don't want to have any regressions since this printer on the SKR Pro is running so beautifully now I have to wait for this to be merged into bugfix. |
(cherry picked from commit 43bf41dc5b7dccdc9fa290ec2e0e1144e8e39c30)
354e930
to
46ab37c
Compare
@thinkyhead, I've rebased this on top of the latest I did some sanity checks on a Malyan M200v2 (STM32F070CB) and verified that at least some of the motors, thermistors, and endstops are working. I didn't test everything due to some limitations testing on my bench. |
I cherry-picked the LCD change from #19297 so that CI can run. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems ready to test, and there are not too many relevant changes to sift through if problems do arise.
* commit 'bc7720c0cd3917f44200c0b78e1b635e4c7b6797': (483 commits) Minor HAL cleanup [cron] Bump distribution date (2020-09-09) Update HAL/STM32 platform to 8.0 (MarlinFirmware#18496) Make M600 heat up the nozzle. Reset runout on fail. (MarlinFirmware#19298) [cron] Bump distribution date (2020-09-08) TFT is neither "graphical" nor "character" (MarlinFirmware#19297) Sanity-check BABYSTEP_DISPLAY_TOTAL with ColorUI (MarlinFirmware#19284) Fix M166 Gradient Mix for DELTA (MarlinFirmware#19285) Separate Neopixel followup (MarlinFirmware#19287) Clean up LCD conditionals, DWIN Whitespace cleanup Adjust GTR PeripheralPins to avoid timer conflicts (MarlinFirmware#19183) STM32F1 EP with USB_COMPOSITE (MarlinFirmware#19281) Menu items for Separate NeoPixel (MarlinFirmware#19280) [cron] Bump distribution date (2020-09-07) Clarify disabling StallGuard for axes (MarlinFirmware#19263) Touch UI long filenames fixes (MarlinFirmware#19262) Fix Ender 3 V2 (DWIN) buffer overrun (MarlinFirmware#19268) Fix STM32F1 SPI device init, MKS_LCD12864 (MarlinFirmware#19271) Emergency Parser for STM32F1 (MarlinFirmware#19279) ... # Conflicts: # .github/issue_template.md # Marlin/Configuration.h # Marlin/Configuration_adv.h # README.md
* commit 'bc7720c0cd3917f44200c0b78e1b635e4c7b6797': (483 commits) Minor HAL cleanup [cron] Bump distribution date (2020-09-09) Update HAL/STM32 platform to 8.0 (MarlinFirmware#18496) Make M600 heat up the nozzle. Reset runout on fail. (MarlinFirmware#19298) [cron] Bump distribution date (2020-09-08) TFT is neither "graphical" nor "character" (MarlinFirmware#19297) Sanity-check BABYSTEP_DISPLAY_TOTAL with ColorUI (MarlinFirmware#19284) Fix M166 Gradient Mix for DELTA (MarlinFirmware#19285) Separate Neopixel followup (MarlinFirmware#19287) Clean up LCD conditionals, DWIN Whitespace cleanup Adjust GTR PeripheralPins to avoid timer conflicts (MarlinFirmware#19183) STM32F1 EP with USB_COMPOSITE (MarlinFirmware#19281) Menu items for Separate NeoPixel (MarlinFirmware#19280) [cron] Bump distribution date (2020-09-07) Clarify disabling StallGuard for axes (MarlinFirmware#19263) Touch UI long filenames fixes (MarlinFirmware#19262) Fix Ender 3 V2 (DWIN) buffer overrun (MarlinFirmware#19268) Fix STM32F1 SPI device init, MKS_LCD12864 (MarlinFirmware#19271) Emergency Parser for STM32F1 (MarlinFirmware#19279) ... # Conflicts: # .github/issue_template.md # README.md
* 2.0.x: (483 commits) Minor HAL cleanup [cron] Bump distribution date (2020-09-09) Update HAL/STM32 platform to 8.0 (MarlinFirmware#18496) Make M600 heat up the nozzle. Reset runout on fail. (MarlinFirmware#19298) [cron] Bump distribution date (2020-09-08) TFT is neither "graphical" nor "character" (MarlinFirmware#19297) Sanity-check BABYSTEP_DISPLAY_TOTAL with ColorUI (MarlinFirmware#19284) Fix M166 Gradient Mix for DELTA (MarlinFirmware#19285) Separate Neopixel followup (MarlinFirmware#19287) Clean up LCD conditionals, DWIN Whitespace cleanup Adjust GTR PeripheralPins to avoid timer conflicts (MarlinFirmware#19183) STM32F1 EP with USB_COMPOSITE (MarlinFirmware#19281) Menu items for Separate NeoPixel (MarlinFirmware#19280) [cron] Bump distribution date (2020-09-07) Clarify disabling StallGuard for axes (MarlinFirmware#19263) Touch UI long filenames fixes (MarlinFirmware#19262) Fix Ender 3 V2 (DWIN) buffer overrun (MarlinFirmware#19268) Fix STM32F1 SPI device init, MKS_LCD12864 (MarlinFirmware#19271) Emergency Parser for STM32F1 (MarlinFirmware#19279) ... # Conflicts: # Marlin/Configuration.h # platformio.ini
Description
Update to the latest version of the stm32duino framework, used by HAL/STM32.
Significant Changes
What have I tested?
Benefits
Two key benefits:
Related Issues
N/A