905U-G Wireless Gateway
User Manual
Page 161
©September 2004
The conversion characters and their meanings are shown below. If the character after
the % is not a conversion character, the behaviour is undefined.
Char-
acter
Argument
type
Converted to
d, i
byte, word
decimal notation (For signed representation. Use signed argument)
o
byte, word
octal notation (without a leading zero).
x, X
byte, word
hexadecimal notation (without a leading 0x or 0X), using abcdef for
0x or ABCDEF for 0X.
u
byte, word
decimal notation.
c
byte, word
single character, after conversion to unsigned char.
s
char*
characters from the string are printed until a ‘\0’ (i.e. NULL) is
reached or until the number of characters indicated by the precision
have been printed
f
float
decimal notation of the form [-]mmm.ddd, where the number of d’s is
specified by the precision. The default precision is 6; a precision of 0
suppresses the decimal point.
e, E
float
decimal notation of the form [-]m.dddddd e+-xx or [-]m.-xx,
where the number of d’s specified by the precision. The default
precision is 6; a precision of 0 suppresses the decimal point.
g, G
%e or %E is used if the exponent is less than -4 or greater than or
equal to the precision; otherwise %f is used. Trailing zeros and
trailing decimal point are not printed.
%
-
print a %