STM32 and SEGGER RTT for printing debugging messages

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • STM32 and SEGGER RTT for printing debugging messages

      Hi, I'm using NUCLEO-F446RE (STM32F4 ARM® Cortex®-M4 MCU 32-Bit Embedded Evaluation Board), Keil MDK 5.20 on 64-bit Windows 10.
      digikey.com/product-detail/en/…46RE/497-15882-ND/5347712

      Instead of using the ST-Link, which is pre-installed on the NUCLEO-F446RE board, I used "Converting ST-LINK On-Board Into a J-Link".
      segger.com/products/debug-prob…j-links/st-link-on-board/

      Also, I use my custom J-Link Plus to connect the board to the PC.

      When printing debugging messages, I used STM32F4's UART pins.
      I wish to use the RTT to print these messages.

      - Is this STM32F446RE MCU able to use the RTT to print debugging messages?
      - If so, how can I do that when using Keil MDK? Hope to see any references (documents, examples, etc), please.

      Thanks for your help.
      -Best Regards, Matthew
    • Hello Matthew,

      Thank you for your inquiry.
      Any Cortex-M can use RTT.
      But Keil MDK does not provide a RTT terminal to display the messages.
      For this you can either use the J-Link RTT Viewer software that comes with the J-Link software package or use our debug software Ozone instead.
      segger.com/products/development-tools/ozone-j-link-debugger/

      If you are looking for an IDE that supports RTT out of the box Embedded Studio can be used as well.

      Best regards,
      Nino
      Please read the forum rules before posting: Forum Rules

      Keep in mind, this is not a support forum. Its main purpose is user to user interaction.
      Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
      Should you be entitled to support contact us per e-mail.
      Alternatively our support system can be used as well: segger.com/ticket/
    • Hi, Nino.
      Just like this screenshot, do you mean I can call

      C Source Code

      1. SEGGER_RTT_TerminalOut
      when using the STM32 series and see the log message using Ozone, regardless of what IDE (Keil, SEGGER ES, IAR EWARM) I use?
      Also, in order to use the RTT, do I have to set the heap size of the STM32 microcontroller?
      -Best Regards, Matthew