about rdword
caskaz
Posts: 957
Hi.
I solved sine-wave by gived advise.
But I have one more question.
I use sin_table_end($F001) to get data for [noparse][[/noparse]90 - 179.95] and [noparse][[/noparse]270 - 359.95]degree.
But it also fine works for $F000).
I checked by using PASM
For example
sin_table($E000)
[noparse][[/noparse]0 - 89.95] $E002 --> $32
$E004 --> $65
sin_table_end($F001)
[noparse][[/noparse]90 - 179.95] $E003 --> $32
$E005 --> $65
Instruction "rdword" is automatically search top addres(even) of word data?
I solved sine-wave by gived advise.
But I have one more question.
I use sin_table_end($F001) to get data for [noparse][[/noparse]90 - 179.95] and [noparse][[/noparse]270 - 359.95]degree.
But it also fine works for $F000).
I checked by using PASM
For example
sin_table($E000)
[noparse][[/noparse]0 - 89.95] $E002 --> $32
$E004 --> $65
sin_table_end($F001)
[noparse][[/noparse]90 - 179.95] $E003 --> $32
$E005 --> $65
Instruction "rdword" is automatically search top addres(even) of word data?
Comments
Yes. I stumbled across this today in my own code. The manual says the address' lower bit will be cleared to zero resulting in an address pointing to a word boundary and this means you can load words from addresses divisible by two only. I don't know if perhaps you have to use $f002. The manual's examples say $f001...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
He died at the console of hunger and thirst.
Next day he was buried. Face down, nine edge first.
Just do [noparse][[/noparse]address] & %00, or %0 to get the effective address for a given fetch from the HUB, and that's how it will work. $F001 will just be $F000. $F002 will be $F002, for words.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Propeller Wiki: Share the coolness!
8x8 color 80 Column NTSC Text Object
Safety Tip: Life is as good as YOU think it is!
Yes, it's my bad. I gave the OP a hint from the top of my head, without looking into the manual again. Of course $f001 is used, but it's just the MSB of the word at $f000. D'OH!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
He died at the console of hunger and thirst.
Next day he was buried. Face down, nine edge first.