Author Topic: Axe Q&A  (Read 587438 times)

0 Members and 4 Guests are viewing this topic.

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1560 on: July 09, 2012, 12:57:14 pm »
EDIT: Oh, I see, that way if FOO translated to {V+17}, you could do something like 23→FOO and FOO→X and both would be valid statements.

It would still be no different than using {V+17} everywhere though, since FOO wouldn't actually exist. It'd be more like a macro than anything.
Yes that's it. It would not save space in any way. It is just so I can easily see who is who in my appvar. Because I have wood, stone and apples (among others) and having this
   {V+17}^^r equ wood
   {V+19}^^r equ stone
   {V+21}^^r equ apple
would be of a great help for me to understand my code easier. So would it be possible ?
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: Axe Q&A
« Reply #1561 on: July 09, 2012, 01:03:28 pm »
You can ask for a feature request here.




Offline shmibs

  • しらす丼
  • Administrator
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2132
  • Rating: +281/-3
  • try to be ok, ok?
    • View Profile
    • shmibbles.me
Re: Axe Q&A
« Reply #1562 on: July 09, 2012, 01:05:10 pm »
just use subroutines. {SUB()}:Lbl SUB is perfectly valid, and works for both storing and recalling. in your case it will be slightly slower and the exact same size as writing it inline, though (plus extra for the subroutine itself), so i guess i see your point.

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: Axe Q&A
« Reply #1563 on: July 09, 2012, 01:13:53 pm »
If he uses the subroutine more than twice it'll actually make his program smaller (I think, haven't tested it). Would be slower though (subroutines are always slower than inline code, aren't they?).




Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1564 on: July 09, 2012, 01:14:53 pm »
just use subroutines. {SUB()}:Lbl SUB is perfectly valid, and works for both storing and recalling. in your case it will be slightly slower and the exact same size as writing it inline, though (plus extra for the subroutine itself), so i guess i see your point.
Yeah, I guess I am going to do that. But you have to admit that {Wood()} is more ugly than just Wood ;)
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline shmibs

  • しらす丼
  • Administrator
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2132
  • Rating: +281/-3
  • try to be ok, ok?
    • View Profile
    • shmibbles.me
Re: Axe Q&A
« Reply #1565 on: July 09, 2012, 01:59:45 pm »
deep, adding two numbers and calling a subroutine come out to be the same size. if his subroutine was more complex, it would save size, but in this particular case it just slows things down.
EDIT: nevermind, he's adding a variable and a constant rather than two constants, so it will be -2n+5 butes smaller, meaning anything past two calls saves space
« Last Edit: July 09, 2012, 02:21:02 pm by shmibs »

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1566 on: July 11, 2012, 11:19:33 am »
Pt-Mask draws on the two buffers to get 3 shades of grey.
Is there an equivalent to get 4 shades or is it necessary to use two Pt-Off ?
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline MGOS

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 336
  • Rating: +95/-0
    • View Profile
Re: Axe Q&A
« Reply #1567 on: July 11, 2012, 11:29:26 am »
Pt-Mask draws on the two buffers to get 3 shades of grey.
Is there an equivalent to get 4 shades or is it necessary to use two Pt-Off ?
No there isn't. But the reason Pt-Mask has only 3-level gray is that the fourth color/combination is transparent, so you don't need to have always square shapes.

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1568 on: July 11, 2012, 11:32:33 am »
Pt-Mask draws on the two buffers to get 3 shades of grey.
Is there an equivalent to get 4 shades or is it necessary to use two Pt-Off ?
No there isn't. But the reason Pt-Mask has only 3-level gray is that the fourth color/combination is transparent, so you don't need to have always square shapes.
Ok, thanks.

Wait, for 4 shades, is it like this ?
L3,L6
 0,0 → white
 0,1 → dark grey
 1,0 → light grey
 1,1 → black
« Last Edit: July 11, 2012, 11:43:19 am by Hayleia »
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline leafy

  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1554
  • Rating: +475/-97
  • Seizon senryakuuuu!
    • View Profile
    • keff.me
Re: Axe Q&A
« Reply #1569 on: July 11, 2012, 12:21:31 pm »
Pt-Mask draws on the two buffers to get 3 shades of grey.
Is there an equivalent to get 4 shades or is it necessary to use two Pt-Off ?
No there isn't. But the reason Pt-Mask has only 3-level gray is that the fourth color/combination is transparent, so you don't need to have always square shapes.
Ok, thanks.

Wait, for 4 shades, is it like this ?
L3,L6
 0,0 → white
 0,1 → dark grey
 1,0 → light grey
 1,1 → black
Indeed.
In-progress: Graviter (...)

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1570 on: July 13, 2012, 09:15:25 am »
Now I have a new question and it seems very stupid to me because if the answer was yes, it would probably be in the Commands.
Is there free RAM available elsewhere than in L1,L2,L3,L4,L5,L6 ?
(for example, I heard about "missing RAM pages", so there should be "available RAM pages" too somewhere)
« Last Edit: July 13, 2012, 09:18:42 am by Hayleia »
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline Runer112

  • Project Author
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2289
  • Rating: +639/-31
    • View Profile
Re: Axe Q&A
« Reply #1571 on: July 13, 2012, 10:59:54 am »
thepenguin77 made a very nice list of all static RAM locations that can be used by an assembly program without resulting in an instant crash if OS interrupts or some basic B_CALLs are used. It lists what will not work or what will corrupt your data if each section is used, and how to properly restore each section upon exiting so the OS will function properly.

This list can be found here.

Regarding extra RAM pages, I would imagine a large reason why their access isn't a built-in Axe feature is because they do not exist on the 83+BE, and Axe is quite faithful to ensuring that all programs using the standard commands will work on all 83+ and 84+ calculators.

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1572 on: July 13, 2012, 02:04:17 pm »
thepenguin77 made a very nice list of all static RAM locations that can be used by an assembly program without resulting in an instant crash if OS interrupts or some basic B_CALLs are used. It lists what will not work or what will corrupt your data if each section is used, and how to properly restore each section upon exiting so the OS will function properly.

This list can be found here.

Regarding extra RAM pages, I would imagine a large reason why their access isn't a built-in Axe feature is because they do not exist on the 83+BE, and Axe is quite faithful to ensuring that all programs using the standard commands will work on all 83+ and 84+ calculators.
Ok, thanks, I'll look at it :)
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Axe Q&A
« Reply #1573 on: July 16, 2012, 01:19:49 pm »
Can constants be declared this way ?
  18→°Var1
  +1→°Var3


Or at least like this ?
  18→°Var1+1→°Var3
« Last Edit: July 16, 2012, 01:20:05 pm by Hayleia »
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline Runer112

  • Project Author
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2289
  • Rating: +639/-31
    • View Profile
Re: Axe Q&A
« Reply #1574 on: July 16, 2012, 02:13:23 pm »
Constants cannot be declared the first way because starting a line with an operator results in the assumption that what precedes the line can be anything, not just a constant. Constants also cannot be declared the second way, although because there's no line separating them, I feel like support for that could be added easily enough. Neither of those methods save space in the executable since constant definitions don't consume any physical data, but I can see how the second one would be useful for saving space in the source program. Maybe you should take that on over to the Features Wishlist. :)