RE: poke4 won't accept my 32bit values

new topic     » goto parent     » topic index » view thread      » older message » newer message

Hi again Chris,


Chris Bensler wrote:
> I discovered something else...
> 
> This bug only happens when poking HEX values.
> If I try..
>   poke4(pvCube+16 ,4294967295)
> 
> Guess what? It works!???
> 
> Gotta be an EU problem somehow..
> 
> Chris

Hmmm, now it sounds like whatever converts "#n" formats
into atoms for large hex numbers is screwing up the conversion.
That would also explain how #FFFFFFFF gets converted into
#100000000 as Derek was saying.
Another test would be to create the number by adding
two values together that do convert correctly, such as:
    n=#FFFF0000+#FFFF to create #FFFFFFFF
or build the number up separately:
    n1=#FFFF0000 
    n2=#FFFF
    n=n1+n2
If its always larger numbers, you could try:
    n1=#80000000 --do high bit separate
    n2=#7FFFFFFF
    n=n1+n2

If these last two methods work, i would assume the
"#n" conversion routine was suspect for n greater than
some large value. Of course i have no idea why, without
seeing all the code.

Q. Could it be its trying to convert to a negative signed atom
   instead of a large positive atom, interpreting the high bit
   as a sign bit?
A. Not if it really does convert #FFFFFFFF to #100000000 (which
   im not sure how #100000000 was verified).

In any case, i hope you find the problem, and its solution.
--Al

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu