Disable the button ok in vs mode
#21
That's not an issue with CodeWrite, that's an issue with your source.

temptemptemp.asm.2 <--- the 2 stands for line 2 of the source. CodeWrite says the reason for the error is that is out of operand range.

Code:
lhz r12, 0x8200 (r12)

lhz is a signed instruction

syntax:
lhz rD, VALUE (rA)

VALUE is in a 16-bit signed range. 0x8200 is not withing the signed range, that's why you got the error.

16-bit signed range is..
0xFFFF8000 --> 0 --> 0x7FFF (-32768 --> -0 --> 32767)

https://mariokartwii.com/showthread.php?tid=830
https://mariokartwii.com/showthread.php?tid=940

Read those two threads if you don't want to read the 'Go from noobs to Veteran ASM coder' thread I linked in my earlier post.
Reply
#22
(11-22-2021, 03:35 PM)Vega Wrote: That's not an issue with CodeWrite, that's an issue with your source.

temptemptemp.asm.2 <--- the 2 stands for line 2 of the source. CodeWrite says the reason for the error is that is out of operand range.

Code:
lhz r12, 0x8200 (r12)

lhz is a signed instruction

syntax:
lhz rD, VALUE (rA)

VALUE is in a 16-bit signed range. 0x8200 is not withing the signed range, that's why you got the error.

16-bit signed range is..
0xFFFF8000 --> 0 --> 0x7FFF  (-32768 --> -0 --> 32767)

https://mariokartwii.com/showthread.php?tid=830
https://mariokartwii.com/showthread.php?tid=940

Read those two threads if you don't want to read the 'Go from noobs to Veteran ASM coder' thread I linked in my earlier post.
oh ok i have the habit to manipule every number whitout problem of lenght or other. And i start to learn i don't know every function/order in asm.
to fix this:
```asm
ori r12, r12, 0x8200

lhz r12, 0 (r12)
```

oh how include code in message ?
we can not include like a Mastering Markdown
Reply
#23
Use the code tags to put stuff in a code box.

This thread has gone off topic quite a bit now, lol. So if you need help on ASM in general, post it on the proper ASM tutorial thread.
Reply
#24
(11-22-2021, 06:59 PM)Vega Wrote: Use the code tags to put stuff in a code box.

This thread has gone off topic quite a bit now, lol. So if you need help on ASM in general, post it on the proper ASM tutorial thread.

ok thanks
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)