Forums - Enabling "%f" or "%g" on snprintf

2 posts / 0 new
Last post
Enabling "%f" or "%g" on snprintf
Join Date: 8 Nov 19
Posts: 2
Posted: Thu, 2020-01-16 00:54


I am using the Snapdragon LLVM ARM C/C++ toolchain version 4.0.3. The hardware is a Quectel BG96 chip. 

Is there anyway to enable support of using "%f" or "%g" to convert floats to string?




  • Up0
  • Down0
Join Date: 4 Nov 18
Posts: 184
Posted: Wed, 2020-08-19 04:08


currently snprintf supports integer and string arguments only. Try ftoa if its available. Else try to write own function, this link may help:


  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.