TIP: Click on subject to list as thread! ANSI
echo: c_echo
to: Jasen Betts
from: Neil Heller
date: 2003-11-05 10:25:00
subject: [--- Ebcdic ---]

JB> // convert the bcd to to ascii

JB>   sprintf(buf,"%x",bcd);   // not portable - but something

That's good, except each of the numbers in the byte had different 
applications in the metering system with which I was working.

Also you would then have to run the resulting string (buf) through a 
_really_ non-portable function, like atoi().

To make things more interesting, integer values were little endian but 
were only 12 bits long.  The 13th bit was the start of the next number.  
That way every 3 bytes held 2 integer values.

þ CMPQwk 1.42 999

--- Maximus/2 3.01
* Origin: COMM Port OS/2 juge.com 204.89.247.1 (281) 980-9671 (1:106/2000)
SEEN-BY: 633/267 270
@PATH: 106/2000 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.