Skip to content
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

TMC220x on-board UART compability #13

Open
Blaster1920 opened this issue Sep 29, 2019 · 3 comments
Open

TMC220x on-board UART compability #13

Blaster1920 opened this issue Sep 29, 2019 · 3 comments

Comments

@Blaster1920
Copy link

Hi,
by having a look at the design I noticed that it is missing an important feature to correctly drive the TMC2208 and TMC2209 drivers directly from the MCU. In fact, it looks like you omitted the possibility of choosing between SPI and UART mode: is there a particular reason why you preferred going this way?
Thank you in advance for your time.

@Blaster1920 Blaster1920 changed the title TMC220x on-board UART compability label:enhancement TMC220x on-board UART compability Sep 29, 2019
@Blaster1920 Blaster1920 changed the title label:enhancement TMC220x on-board UART compability TMC220x on-board UART compability Sep 29, 2019
@chrissbarr
Copy link
Contributor

Hi @Blaster1920,

Short answer: supporting the UART drivers didn't seem feasible within the constraints of this board, but if you can see a way to make it work let me know and we'll take it into consideration.

My understanding is that the UART-based TMC drivers require two communication pins (TX and RX) per driver. Please correct me if this is incorrect. The SPI-based TMC drivers require three pins shared among all drivers (MISO, MOSI, SCK) and 1 pin for each driver (CS). On the current design, there are not enough spare GPIO to support adding an extra pin to each driver (also it would be tough to route an extra signal to each driver socket).

If there's a way that the UART drivers can work with just a simple jumper using the signals that are already routed to each socket, then it's definitely something I'd be interested in exploring. At the moment, each stepper driver has the following pins/signals:

  • STEP
  • DIRECTION
  • ENABLE
  • CHIP SELECT
  • MISO (shared)
  • MOSI (shared)
  • SCK (shared)

So, we don't have two pins per driver (outside the usual STEP/DIR/EN) to act as RX & TX. Is it possible to control the TMC2208 with only TX (i.e. no feedback)? If so, it might be possible to use the CHIP SELECT signal as a soft UART TX for that purpose. I'm not familiar enough with the state of TMC220X firmware support to say.

Let me know what you think, if you have a way of making it work I'd love to get it included in the design.

@Blaster1920
Copy link
Author

Hi @chrissbarr,
thank you for the prompt and detailed response.
I've been looking for possible solutions, but so far nothing seems to be what we need, even though there may be a couple of possibilities:

Let me know.

@sverd
Copy link

sverd commented Aug 3, 2020

Hi,
I noticed that in newer revisions the on-board UART seems to have been fixed/added. I could however not completely figure out how this was done. The thing is that I have a 1.0 version of the board and I'm wondering whether it is possible to "fix" that board to get UART working with the stepper drivers. Is it possible to get UART working with possibly a few small modifications? (mainly asking because I saw the fix to get SPI communication with the stepper drivers working which is very doable)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants