Skip to main content
jo_it
Associate III
March 27, 2015
Question

Unexpected USART TCI

  • March 27, 2015
  • 3 replies
  • 819 views
Posted on March 27, 2015 at 18:05

I'm on a Nucleo-F411RE board and experience strange behaviour. In the USART interrupt pass I have status flag of TCI set. The TCIE bit is never set in the CR1 reg?

I start to get doubts I need to pull this flag high to disable TCI?
    This topic has been closed for replies.

    3 replies

    Tesla DeLorean
    Guru
    March 27, 2015
    Posted on March 27, 2015 at 18:20

    The logic in the peripheral observes a TC event the flag gets to this register, it doesn't generate an interrupt because it's not gated with the enable. Ignore it.

    And RXNE, and TXE, interrupts will also flag, whether enabled or not.

    Figure AND get on the enable, and an OR gate combining all sources, single IRQ feed to the NVIC.

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
    Tesla DeLorean
    Guru
    March 27, 2015
    Posted on March 27, 2015 at 18:28

    Observe there isn't a 'TCI' bit in the status register.

    0690X00000603JoQAI.jpg

    0690X00000603JtQAI.jpg

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
    jo_it
    jo_itAuthor
    Associate III
    March 27, 2015
    Posted on March 27, 2015 at 18:28

    @clive: offcourse, they will flag status anyhow. If the code can't ignore TC flag it must check whether status is set and his compatible bit in CR1 reg. tnx!