Calculator Community > Grammer
Grammer Q&A
Stefan Bauwens:
Now I come to think of it, Grammer should actually have it's own forum.(I don't think it does, right?)
Xeda112358:
No, it doesn't yet XD That is why I have been avoiding making a topic like this >.>
Scipi:
Ok, I guess my biggest question is how do I make an array that I can access?
Yeong:
First, you can create program or appvar like this:
Send(size,"UTEMP->B
This will create appvar TEMP and store it into pointer B.
and then:
B[4,4,4,4,4,4,4,4,4,4
This will store 4 into first 10 bytes of that appvar TEMP.
Xeda112358:
Well if you wanted to create a 128 byte array for temporary storage, I would create a TempProg (the prefix byte is V or 6). Since Send( will let you do this and it returns the pointer to the var, this is what you would want to do:
--- Code: ---Send(128,"6Temp→Z ;Z now points to the Array
--- End code ---
Lowercase is allowed in the name and weird symbols are encouraged to avoid conflicting with preexisting programs
Now you can use Z as a pointer. There are several commands that might be useful:
--- Code: ---int(Z,A will write the lower 8-bits of A to the memory location Z
iPart(Z,A will write A to the memory location Z in little endian
(Z will read the byte at Z
{Z will read the word (little endian) at Z
IS>(Z will read the byte at Z and then increment Z
--- End code ---
There are also various other commands if you need other specific things done...
EDIT:Also what Yeong said ^_^
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version