Printing real numbers (decimal points) in FRDM-KW36 SDK

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Printing real numbers (decimal points) in FRDM-KW36 SDK

311 Views
SeokJin
Contributor II

Hello.

I am utilizing one of the examples in the KW36 SDK, "Low Power Temperature Sensor and Collector". IDE verson is [MCUXpresso IDE v11.8.1_1197]

In this example, I understand that the server device measures the temperature and transmits it to the client device.

Currently, temperature is expressed in integer form (e.g. 20 degrees Celsius), but I would like a more accurate measurement.

I want to measure temperature in decimals and output it to Putty.

 

What should I do if I want the temperature, which is currently displayed as "20 degrees Celsius", to be displayed as "20.xx degrees Celsius"?

 

Among the BLE temp collector.c codes, "SerialManager.c" seems to be set to only output integer format.

SeokJin_1-1711371289964.png

 

Which part and how should I modify to output the value in real number form?

 

I'm waiting for your reply. Thanks in advance.

Regards,

SeokJin.

Tags (1)
0 Kudos
Reply
1 Reply

280 Views
nxf77486
NXP TechSupport
NXP TechSupport

Hello,

 

Thank you for contacting NXP support.

You are correct currently we only have an API to send this information as an integer format number, and we do not have an API for floating or real number form on the Serial Manager support, but this does not mean this could not be achieved this result.  But in this case we do not have a proper solution to suggest for this.

Please let me know if there is anything else where I can help you, and we apologize for this inconvenient.

0 Kudos
Reply