Re: negative hex
- From: John Larkin <jjlarkin@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 30 Jun 2008 11:55:27 -0700
On Sun, 29 Jun 2008 19:40:54 +0100, richard
<mullens-deleteme-@xxxxxxxxxxxx> wrote:
John Larkin wrote:
Is there a convention for negative hex numbers?
-0xFEEE
or
0x-ABCD
FFFF is either -1 or 65535 according to whether it is a signed or unsigned quantity
Only if you're using 16-bit ints and decide that they are signed. I
consider 0xFEEE to be decimal +65262. My HP 32S calculator agrees.
To say -FFFF is like saying "I'm going to subtract -1".
Generally if I do this it is with a sense of guilt that I can't be bothered to negate it.
I want "-0x40000000" to program a generator to make -16.000 MHz.
John
.
- Follow-Ups:
- Re: negative hex
- From: Jan Panteltje
- Re: negative hex
- References:
- negative hex
- From: John Larkin
- Re: negative hex
- From: richard
- negative hex
- Prev by Date: Re: Mixing AC with DC - Good Idea?
- Next by Date: Re: negative hex
- Previous by thread: Re: negative hex
- Next by thread: Re: negative hex
- Index(es):