MarlinFirmware / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
https://marlinfw.org
GNU General Public License v3.0
16.3k stars 19.25k forks source link

[BUG] TMC2208 UART pin strange signal levels and freeze pulling low #17914

Closed chunter1 closed 4 years ago

chunter1 commented 4 years ago

I connected the TMC2208 of the extruder on my Creality v2.4 board (CR10S Pro) to the following soft-UART pins via the standard 1k connection sceme: RxD = 87 TxD = 59 Communication is successful, however the signal levels look very strange and when i print the linear advance test pattern, the TMC2208 immediately pulls the PDN_UART pin to low and outputs a view high-pulses somehow synchronouse to the motor movements it performs. It does not get out of that low-pulling state anymore and communication is ofcourse impossible until a power-cycle is performed. Can someone confom that the attached communication levels are normal and maybe also someone has an explanation to the LOW-stuck ouput of the TMC2208. I tried variouse soft-serial pin combinations but problem stays the same. I also checked if the LOW-level is coming from the TMC2208 pin by disconnecting everything else.

TMC2208_UART_signals

sjasonsmith commented 4 years ago

What firmware are you running? This looks like an issue that was fixed about 6 months ago.

chunter1 commented 4 years ago

Do you remember what the bug was called or got a link? I am running the "CrealityDwin2.0_Bleeding" branch of the Insanity Automation (Tiny Machines 3D) version on github. https://github.com/InsanityAutomation/Marlin/tree/CrealityDwin2.0_Bleeding

sjasonsmith commented 4 years ago

Here is one of the pull requests I made for it: https://github.com/teemuatlut/TMCStepper/pull/98

There were several related issues for different platforms. I believe that one applied to AVR controllers.

I don't really know the state of the firmware @InsanityAutomation maintains. It seems like it probably has a recent TMCStepper so this might be different than the issues you are seeing.

Do the signals look good if you capture the initial serial traffic after power-on? The problems I was seeing usually resulted in more problems with early communication, and it sounds like maybe yours is happening later.

chunter1 commented 4 years ago

Problem solved! After doing some layout reverse engineering i found out that on the Creality V2.4 motherboard, the TMC2208 pins PDN_UART, INDEX and DIAG are all connected together and simply pulled up to +5V by a 100k resistor. After doing some mod, i got a perfectly clean signal now and can go on trying to get linear advance to work. TMC2208_UART_after_mod

sjasonsmith commented 4 years ago

Thanks for the update @chunter1! That is a pretty annoying design decision on their part. Could you go ahead and close this issue, since it isn't anything Marlin related?

github-actions[bot] commented 4 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.