Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Peter Pearson Newsgroups: comp.lang.python Subject: Re: problem with bcd and a number Date: 5 Aug 2011 16:01:48 GMT Lines: 16 Message-ID: <9a2ifcF1k7U1@mid.individual.net> References: <31c8d075-2901-46eb-adcf-1c1803ab7938@a4g2000yqg.googlegroups.com> X-Trace: individual.net fd4ZiNYI6WLCrbdT0Zvkkwz8vr/pYv8LEtDAZIm9XX0+p5B1/T Cancel-Lock: sha1:ZS9xV2f4ib6kjmTtsltiJitMklw= User-Agent: slrn/pre1.0.0-16 (Linux) Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:10911 On Thu, 04 Aug 2011 21:52:45 +0200, Christoph Hansen wrote: > MRAB schrieb: > >> The value is MSB * 100 + (LSB>> 4) * 10 + (LSB& 0xF) > > i would say > > (MSB >> 4)*100 + (MSB & 0xF)*10 + (LSB >> 4) > > but who knows I concur. I think the documentation is trying to say that the low-order nibble of the LSB is garbage. -- To email me, substitute nowhere->spamcop, invalid->net.