This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Can Serial Communication work inside a Interrupt??

Dear Frnds,

Do serial communication like " printf " can work inside interrupt??? Is there any Potential problem with communication with serial communication inside a interrupt????

Rajesh

Parents
  • using printf in an Interrupt routine is a very bad idea!

    It's not reentrant, for a start.

    It's a very big piece of code, so could take significant time to execute - especially with complex formatting and/or large strings

    The default implementation uses polled serial IO - so printf does not return until the final character of the output has been send out of the UART.

Reply
  • using printf in an Interrupt routine is a very bad idea!

    It's not reentrant, for a start.

    It's a very big piece of code, so could take significant time to execute - especially with complex formatting and/or large strings

    The default implementation uses polled serial IO - so printf does not return until the final character of the output has been send out of the UART.

Children