Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: Rollum78 on October 11, 2012, 03:39:21 pm

Title: Unobtainable Characters with AXE
Post by: Rollum78 on October 11, 2012, 03:39:21 pm
I want to store some characters you can't obtain in BASIC (for example the inverted equal) to the OS Str1 with an AXE program, so i can just copy them later into my basic program.
The problem is i don't know how to access Str1 and fill it with those characters in AXE...
thx for your help
Title: Re: Unobtainable Characters with AXE
Post by: Yeong on October 11, 2012, 03:49:17 pm
Code: [Select]
GetCalc("Str1")→A
For(B,0,255)
B→{A+B}
End
This should work. (Str1 must be 255 chars long)
This get all the chars in Str1.
Title: Re: Unobtainable Characters with AXE
Post by: Hayleia on October 11, 2012, 03:50:01 pm
Here is a program that fills Str0 with those characters. It is in Basic so you can easily change it to store them in Str7 ;)
Title: Re: Unobtainable Characters with AXE
Post by: Rollum78 on October 11, 2012, 04:02:59 pm
Code: [Select]
GetCalc("Str1")→A
For(B,0,255)
B→{A+B}
End

When i recall Str1 at the homescreen, it is full of all the tokens in the catalog (and some more...),
but the characters i'm looking for (those:  http://tibasicdev.wikidot.com/83lgfont (http://tibasicdev.wikidot.com/83lgfont) ) are missing...
displaying them directly in AXE works:
Code: [Select]
For(A,0,20)
Disp A>Char      //or >Frac, whatever...
End

Edit:
Quote
Here is a program that fills Str0 with those characters.

i've already seen this program, but my link is broken right now so i was looking for something on calc...
but thx anyway :)
Title: Re: Unobtainable Characters with AXE
Post by: DrDnar on October 11, 2012, 07:54:51 pm
yeongJIN_COOL, you can't do it that way. Axe deals with 8-bit character codes, but TI-BASIC deals with tokens that are either 8 or 16 bits. You have to look up the character's token code and store that into the string. It's a pain to deal with. To do what Rollum78 wants to do, you need to define the string as a set of tokens, entering in their codes using Data(. Sorry, there are no B_CALLs that can perform tokenization of text. You'll have to find a list of token codes. ti83plus.inc has a fairly complete list, but the symbols are a little iffy.

Edit: Here's the list of hex codes from the above BASIC program:
Code: [Select]
BB 9A BB 9B BB 9C BB 9D BB 9E BB 9F BB A0 BB A1 BB A2 BB A3 BB A4 BB A5 BB A6 BB A7 BB A8 BB A9 BB AB BB AC BB AD BB AE BB CB BB CC 7F 80 81 BB D1 BB D2 BB D3 BB D4 BB D5 BB D6 BB D7 BB D8 BB D9 BB DA BB DB BB DC BB DD BB DE BB DF BB E0 BB E1 BB E2 BB E3 BB E4 BB E5 BB E6 BB E7 BB E8 BB E9 BB EA BB EB BB EC BB ED BB EE BB EF BB F0 BB F1 BB F2 BB F3 BB F4 BB F5 63 2B 29 BB CF 83 82 71 70 10 11 08 09 06 07 F0 2B BB 71 BB 73 BB 74 BB 75 BB 6F BB 70 BB 6E BB 72 BB 7A BB 7B BB 7C BB 76 BB 77 BB 78 BB 79 BB 7D BB 81 BB 84 BB 85 BB CD BB 80 BB 7F BB 83 BB 82 BB 8A BB 8C BB 86 BB 87 BB 88 BB 89 BB 8B BB 8D BB 91 BB 93 BB 95 BB 8F BB 90 BB 92 BB 94 BB 8E BB 98 BB 99 BB 96 BB 97
Title: Re: Unobtainable Characters with AXE
Post by: dinosteven on October 11, 2012, 08:51:58 pm
Not sure about Axe, but Xeda's Xtra2 can do this:
http://www.ticalc.org/archives/files/fileinfo/425/42505.html
Title: Re: Unobtainable Characters with AXE
Post by: Yeong on October 11, 2012, 10:05:44 pm
oh I misunderstood his question (and prolly my knowledge) D:
sorry!
Title: Re: Unobtainable Characters with AXE
Post by: Rollum78 on October 12, 2012, 09:48:41 am
Edit: Here's the list of hex codes from the above BASIC program:

Thanks for the hex codes, the lack of pictures in ti83plus.inc makes it hard to look them up :)

My only problem is how to use "Data(":

Code: [Select]
Data([sub]E[/sub]BB,[sub]E[/sub]F7)->GDB1
Copy(GDB1,GetCalc("Str1",2),2)
now theres just "?" in Str1

Code: [Select]
Data([sub]E[/sub]F7[sup]r[/sup])->GDB1
Copy(GDB1,GetCalc("Str1",2),2)
and now theres "PwrReg ?" in Str1

I'm pretty shure i'm inserting the data wrong... any idea?
Title: Re: Unobtainable Characters with AXE
Post by: Hayleia on October 12, 2012, 12:28:48 pm
I don't know why your program doesn't work but mine do :D
(but it wight be a good idea to manually delete Str1 before using it)

Code: [Select]
.AA
[]->GDB1
GetCalc("Str1",226)->A
[BB9ABB9BBB9CBB9DBB9EBB9FBBA0BBA1BBA2BBA3BBA4BBA5BBA6BBA7BBA8BBA9BBABBBACBBADBBAEBBCBBBCC7F8081BBD1BBD2BBD3BBD4BBD5BBD6BBD7BBD8BBD9BBDABBDBBBDCBBDDBBDEBBDFBBE0BBE1BBE2BBE3BBE4BBE5BBE6BBE7BBE8BBE9BBEABBEBBBECBBEDBBEEBBEFBBF0BBF1BBF2BBF3BBF4BBF5632B29BBCF83827170101108090607F02BBB71BB73BB74BB75BB6FBB70BB6EBB72BB7ABB7BBB7CBB76BB77BB78BB79BB7DBB81BB84BB85BBCDBB80BB7FBB83BB82BB8ABB8CBB86BB87BB88BB89BB8BBB8DBB91BB93BB95BB8FBB90BB92BB94BB8EBB98BB99BB96BB97]
Copy(GDB1+4,A,226)
Title: Re: Unobtainable Characters with AXE
Post by: Rollum78 on October 12, 2012, 12:44:38 pm
Great, it's working :D

But  why the "+4" at this line ?
Quote
Code: [Select]
Copy(GDB+4,A,226)
Title: Re: Unobtainable Characters with AXE
Post by: Hayleia on October 12, 2012, 12:53:37 pm
Great, it's working :D

But  why the "+4" at this line ?
Quote
Code: [Select]
Copy(GDB+4,A,226)
I don't know at all :P
I tried it without the +4, thinking that would work, but it added 4 strange characters at the beginning and removed two ones at the end. Then I added the +4 and everything worked perfectly.
Title: Re: Unobtainable Characters with AXE
Post by: MGOS on October 12, 2012, 01:20:48 pm
Please, Hayleia, you disappointed me. The four bytes are the call of GetCalc :)

Code: [Select]
.AA
[]->GDB1
GetCalc("Str1",226)->A
[BB9ABB9BBB9CBB9DBB9EBB9FBBA0BBA1BBA2BBA3BBA4BBA5BBA6BBA7BBA8BBA9BBABBBACBBADBBAEBBCBBBCC7F8081BBD1BBD2BBD3BBD4BBD5BBD6BBD7BBD8BBD9BBDABBDBBBDCBBDDBBDEBBDFBBE0BBE1BBE2BBE3BBE4BBE5BBE6BBE7BBE8BBE9BBEABBEBBBECBBEDBBEEBBEFBBF0BBF1BBF2BBF3BBF4BBF5632B29BBCF83827170101108090607F02BBB71BB73BB74BB75BB6FBB70BB6EBB72BB7ABB7BBB7CBB76BB77BB78BB79BB7DBB81BB84BB85BBCDBB80BB7FBB83BB82BB8ABB8CBB86BB87BB88BB89BB8BBB8DBB91BB93BB95BB8FBB90BB92BB94BB8EBB98BB99BB96BB97]
Copy(GDB1+4,A,226)

Because GBD1 is in the program code, all your commands will be part of the memory. You have to put the []->GBD1 after the GetCalc, otherwise your data starts with "Getcalc" instead of that chunk of Hex!
Title: Re: Unobtainable Characters with AXE
Post by: shmibs on October 12, 2012, 01:23:47 pm
it looks like everything has been sorted out, but here's a little program i wrote that shows the complete token table for the 84+ and allows exporting them for BASIC. the source might be useful.
(http://www.omnimaga.org/index.php?action=dlattach;topic=13834.0;attach=13040)
[Link] (http://ourl.ca/16431/308229)
Title: Re: Unobtainable Characters with AXE
Post by: Hayleia on October 12, 2012, 01:24:08 pm
Please, Hayleia, you disappointed me. The four bytes are the GetCalc-call :)

Code: [Select]
.AA
[]->GDB1
GetCalc("Str1",226)->A
[BB9ABB9BBB9CBB9DBB9EBB9FBBA0BBA1BBA2BBA3BBA4BBA5BBA6BBA7BBA8BBA9BBABBBACBBADBBAEBBCBBBCC7F8081BBD1BBD2BBD3BBD4BBD5BBD6BBD7BBD8BBD9BBDABBDBBBDCBBDDBBDEBBDFBBE0BBE1BBE2BBE3BBE4BBE5BBE6BBE7BBE8BBE9BBEABBEBBBECBBEDBBEEBBEFBBF0BBF1BBF2BBF3BBF4BBF5632B29BBCF83827170101108090607F02BBB71BB73BB74BB75BB6FBB70BB6EBB72BB7ABB7BBB7CBB76BB77BB78BB79BB7DBB81BB84BB85BBCDBB80BB7FBB83BB82BB8ABB8CBB86BB87BB88BB89BB8BBB8DBB91BB93BB95BB8FBB90BB92BB94BB8EBB98BB99BB96BB97]
Copy(GDB1+4,A,226)

Because GBD1 is in the program code, all your commands will be part of the memory. You have to put the []->GBD1 after the GetCalc!
Lol, I am so stupid. I didn't even notice the []→GDB1 was not at the right place o.o°
In fact I remember why: I copy-pasted DrDnar's hex before putting the GetCalc, then I only needed the GDB1 pointer when I placed the Copy command and I placed the pointer at the wrong place :P
Title: Re: Unobtainable Characters with AXE
Post by: Rollum78 on October 12, 2012, 01:50:09 pm
Because GBD1 is in the program code, all your commands will be part of the memory. You have to put the []->GBD1 after the GetCalc, otherwise your data starts with "Getcalc" instead of that chunk of Hex!

That explains a lot.

Thank you all for your help :)
Title: Re: Unobtainable Characters with AXE
Post by: DrDnar on October 12, 2012, 07:45:19 pm
For the record, I got the list of hex codes by opening the .8xp file in the XVI32 hex editor (http://www.chmaas.handshake.de/delphi/freeware/xvi32/xvi32.htm). I looked for the tell-tale byte codes I know represent the untypeable tokens. The start 8xp program data is always somewhere between 0x40 and 0x50, and the last two bytes are always a checksum.