Sunday, February 18th 2018, 8:44pm UTC+1

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

erw

Beginner

Date of registration: Nov 26th 2015

Posts: 4

1

Friday, November 27th 2015, 2:46pm

[SOLVED] print float with RTT viewer

I try to print 'float' number using RTT Viewer.
But I know that SEGGER_RTT_printf only accept 'int'

So what's the solution to print the float numbers?

Thank you

SEGGER - Niklas

Super Moderator

Date of registration: Oct 6th 2014

Posts: 1,691

2

Friday, November 27th 2015, 4:03pm

Hi,


SEGGER_RTT_printf() is a minimal implementation of printf() and only supports the most basic format modifiers.
If advanced functionality is required, use sprintf() into a buffer and output it via SEGGER_RTT_WriteString().

Best regards,
Niklas
Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
Notification for Embedded Studio: Link

erw

Beginner

Date of registration: Nov 26th 2015

Posts: 4

3

Friday, November 27th 2015, 4:17pm

what's the SEGGER_RTT_SendString() function?
I don't have it !!

SEGGER - Niklas

Super Moderator

Date of registration: Oct 6th 2014

Posts: 1,691

4

Friday, November 27th 2015, 4:34pm

Hi,

sorry, it is actually called SEGGER_RTT_WriteString() .

Best regards,
Niklas
Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
Notification for Embedded Studio: Link

Similar threads