Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: asi14 on March 11, 2014, 11:30:53 pm

Title: Differences in language btwn TIBASIC and AXE
Post by: asi14 on March 11, 2014, 11:30:53 pm
Any differences? When I saw a screenshot of Axe, I couldnt tell much of a difference. Either I am not experienced enough in programming, or I just need to read more.  :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead: :banghead:
Title: Re: Differences in language btwn TIBASIC and AXE
Post by: Hayleia on March 12, 2014, 01:56:38 am
Try running this code in Basic:
Code: [Select]
.AA
Data(|pi|11111111,|pi|01111111,|pi|00111111,|pi|00011111,|pi|00001111,|pi|00000111,|pi|00000011,|pi|00000001,|pi|00000000)->GDB0

L1->°AA
L1+3->°BB
ClrDraw(L1)
While 1
 BB+getKey(3)-getKey(2)+96^96->BB
 AA+getKey(1)-getKey(4)^64->AA
 65535->Q
 For(8 )
  Select({BB^8+GDB0},->{Q+++AA^64*12+(BB/8->r3)+L6->r2}) xor |pi|11111111
  ->{r3-11??r2-11,r2+1}
 End
 DispGraphClrDraw
EndIf getKey(15)

Basic is interpreted and Axe is compiled, so usually, Basic is slower than Axe in games but smaller. However, Basic is more apropriate for maths program.
Title: Re: Differences in language btwn TIBASIC and AXE
Post by: DJ Omnimaga on March 12, 2014, 02:27:13 am
Most Axe 0.03 code is nearly identical to TI-BASIC, but like Hayleia said, Axe is compiled and most newer code is different. Axe runs much faster than TI-BASIC. If you had an Axe program run nearly as slow as a BASIC one, then there is most likely something you did wrong, such as using a DispGraph command after drawing each pixel/line/text char/etc.
Title: Re: Differences in language btwn TIBASIC and AXE
Post by: Sorunome on March 12, 2014, 09:37:36 am
I would rather ask for the similarities:
As already mentioned, Axe is been compiled to machine code, so it doesn't need an external program, an interpreter, to run it. While Axe is good for games and such stuff, Basic is far better for math-intensive programs as the interpreter already has a lot of math functions.