首页|嵌入式系统|显示技术|模拟IC/电源|元件与制造|其他IC/制程|消费类电子|无线/通信|汽车电子|工业控制|医疗电子|测试测量
首页 > 分享下载 > 嵌入式系统 > 浮点到ASCII转换

浮点到ASCII转换

资料介绍
It is often necessary to output a floating point number
to a display. For example, to check calculations, one
might want to output floating point numbers using the
PICmicro
®
microcontrollers serial port, or use general
purpose I/O to output to a liquid crystal display (LCD).
Either way, the floating point number must be con-
verted to its ASCII equivalent. This document shows a
specific example of converting a 32-bit floating point
number to ASCII. Application note AN575 contains
24-bit and 32-bit floating point routines. A subroutine is
provided here that does the conversion and returns the
ASCII equivalent in RAM. An example “main” program
is provided to show how to use the subroutine.
M Floating Point to ASCII Conversion
AN670
Table 2 depicts Microchip’s 32-bit floating point register
Authors: Rick Evans RAM usage. The bit labeled “S” is the sign bit. These
Microchip Technology, Inc. registers are collectively called AARG. The floating
point routines require that the arguments be put in
AARG and BARG (BARG is the second argument,
same format as
标签:浮点ASCIIASCII转换
浮点到ASCII转换
本地下载

评论