CodeWalrus

Development => Calculators => Calculator News, Coding, Help & Talk => Topic started by: Epharius on January 14, 2016, 08:41:53 PM

Title: [84+CE] PHASM
Post by: Epharius on January 14, 2016, 08:41:53 PM
Hello everybody!

I was writing a post for TWO bloody hours until I lose it because of a "timeout"! So I'm gonna write something shorter -.-


What is PHASMe?
"Phasmes" (or stick insects if you prefer) are brown most of the time. But don't worry, we aren't going to talk about insect life, even though it may be very interesting...
No, PHASM is a program for your Ti-84+CE (Ti-83 Premium CE), which allows you to run assembly programs, archived or not and to edit archived programs without unarchiving them beforehand. Furthermore, thanks to it, you can navigate in your program easily thanks to the label menu, using the [ALPHA], [XTOn] key combo while editing a program! Finally, it's possible to edit the memory of your calculator, pressing [Alpha]+[VAR]
The goal of PHASM is to be invisible. You run once "Asm(prgmPHASM)" and that's all! And if you are fed up with PHASM (although it seems incredible), you have just to execute "prgmPHASM".

Rubbish transition


Features and To-Do List
Let's sum up what PHASM can do :
Red = To do
Orange = In progress
Green = Done

Crazy transition


Screenshot and links
If you're lazy ('cause life is tiresome), I'm gonna summarize all my post in one gif (thank you Hayleia :D )
(https://tiplanet.org/modules/archives/captures/1476477994PHASM.gif)


And if you're just curious, github is open 24/7! (https://github.com/MathisLav/PHASM)

Download : PHASM (https://tiplanet.org/forum/archives_voir.php?id=318384)


Well, everything seems to be said. Have fun with PHASM!  8)
Title: Re: PHASM
Post by: Dream of Omnimaga on January 15, 2016, 07:53:45 AM
I should look if it's possible to increase session times for SMF. Two hours is definitvely not enough when we have to go away or are writing a long post. In the future, you should write long post in Notepad or something, though, then copy/paste. It's safer (I have timeout issues on TI-PLanet sometimes and lost lots of posts as a result)

Anyway glad to see a new update on this Epharius :). The lbl jumping feature and the ability to edit archived programs will definitively be extremely useful.
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on January 28, 2016, 12:01:50 AM
This is pretty cool! There are so many new things coming out for the CE Series. This is just one of them. I might get the TI-84+ CE instead of a TI-84+ next month.
:walrii:
Title: Re: PHASM
Post by: Unicorn on January 28, 2016, 12:42:41 AM
I wonder if this would be compatible with Cesium... Great job, anyhow
Title: Re: PHASM
Post by: Dream of Omnimaga on January 28, 2016, 01:08:54 AM
Quote from: Dudeman313 on January 28, 2016, 12:01:50 AM
This is pretty cool! There are so many new things coming out for the CE Series. This is just one of them. I might get the TI-84+ CE instead of a TI-84+ next month.
:walrii:
Considering you already have a TI-84+ (seeing your forum signature), I would recommend getting a TI-84+CE instead of a second TI-84+.

Quote from: Unicorn on January 28, 2016, 12:42:41 AM
I wonder if this would be compatible with Cesium... Great job, anyhow
I bet it could be made compatible, if not already. But of course it will depend of if the author of respective shells and programs that use hooks are interested in fixing compatibility issues with other shells on their end instead of waiting forever for the other author to fix the issue on his end (which happened in the past on monochrome models).
Title: Re: PHASM
Post by: Hayleia on January 28, 2016, 01:16:31 AM
I have no idea why there is a discussion about potential things going wrong with Cesium. Phasm uses hooks only and Cesium uses no hook (as far as I can tell, it's like MirageOS, interface only), so where could there be a problem ?
And actually, there used to be a problem due to using the same RAM area, but it was the first thing to be fixed, a long time ago, as mentionned on the first post.
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on January 28, 2016, 01:46:27 AM
Quote from: Hayleia on January 28, 2016, 01:16:31 AM
I have no idea why there is a discussion about potential things going wrong with Cesium. Phasm uses hooks only and Cesium uses no hook (as far as I can tell, it's like MirageOS, interface only), so where could there be a problem ?
And actually, there used to be a problem due to using the same RAM area, but it was the first thing to be fixed, a long time ago, as mentionned on the first post.
I know, right? Celsium's pretty awesome; I don't get the whole "You got problems!" thing, especially since it uses no hooks.

Quote from: DJ Omnimaga on January 28, 2016, 01:08:54 AM
Quote from: Dudeman313 on January 28, 2016, 12:01:50 AM
This is pretty cool! There are so many new things coming out for the CE Series. This is just one of them. I might get the TI-84+ CE instead of a TI-84+ next month.
:walrii:
Considering you already have a TI-84+ (seeing your forum signature), I would recommend getting a TI-84+CE instead of a second TI-84+.
What I meant by this was that I have to return my TI-84+ to Walmart(my 90 days are almost up, and it's a long story) and I was looking for another calculator to get, this time for keeps, at a lower price than $118. I was thinking I could either try to find a TI-84+ Silver Ed. on eBay or try to get a color calculator that is awesome.
BTW, can a TI-84+ Silver C run all the same programs as a CE?
Title: Re: PHASM
Post by: Dream of Omnimaga on January 28, 2016, 01:50:51 AM
Quote from: Hayleia on January 28, 2016, 01:16:31 AM
I have no idea why there is a discussion about potential things going wrong with Cesium. Phasm uses hooks only and Cesium uses no hook (as far as I can tell, it's like MirageOS, interface only), so where could there be a problem ?
And actually, there used to be a problem due to using the same RAM area, but it was the first thing to be fixed, a long time ago, as mentionned on the first post.
Ah right, I forgot that Cesium uses no hook. I always think it has homerun features. However, Doors CE will have hooks and a lot of them. My main worry about compatibility is that both ZStart and DCS7 authors kept playing Ping-Pong and blaming each other's shells when compatibility problems between both shells were reported by users, and regardless of what the authors' respective motive was, it would suck if this happened again on the 84+CE.

Quote from: Dudeman313 on January 28, 2016, 01:46:27 AM
BTW, can a TI-84+ Silver C run all the same programs as a CE?
Only pure TI-BASIC programs, for now. There is no cross-compatibility for ASM programs. However, Doors CSE games will most likely work on the CE too eventually, for the most part, since DCE9 is on the horizon.
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on January 28, 2016, 01:52:26 AM
I'm currently trying to handle the 3 disagreeing apps on my calc:
-DCS7
-zStart
-Omnicalc
Title: Re: PHASM
Post by: Dream of Omnimaga on January 28, 2016, 02:01:30 AM
What do you need with Omnicalc? Do you use it only for inline assembly language support or sprites, then you don't need Omnicalc, since Doors CS 7 supports Omnicalc syntax for those commands (which is why the TI-BASIC versions of Reuben Quest run fine in Doors CS 7 even without Omnicalc installed)
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on January 28, 2016, 02:05:17 AM
I actually didn't know Omnicalc could do that stuff. :P
I used it only for RAM Recovery and Memory Protection.
Title: Re: PHASM
Post by: Dream of Omnimaga on January 28, 2016, 02:22:27 AM
RAM recovery only works on TI-84+ models made before April 2007.  If you bought your calc in recent years then this could explain why you lost Slime source code.

Anyway we're getting off-topic now, so we should switch back to PHASM discussion.
Title: Re: PHASM
Post by: Unicorn on January 28, 2016, 03:44:55 AM
Quote from: Hayleia on January 28, 2016, 01:16:31 AM
I have no idea why there is a discussion about potential things going wrong with Cesium. Phasm uses hooks only and Cesium uses no hook (as far as I can tell, it's like MirageOS, interface only), so where could there be a problem ?
And actually, there used to be a problem due to using the same RAM area, but it was the first thing to be fixed, a long time ago, as mentionned on the first post.
In that case, then, I better put this on my calc! I don't know much about ASM things, hence the question, btw
Title: Re: [84+CE] PHASM
Post by: Epharius on January 30, 2016, 01:10:46 PM
Yes, of course Cesium is compatible with PHASM, it was one of my first goals ;)
Thank you for your feedbacks, I think the first version is nearly over (maybe in two or four weeks if I manage to fix some weird bugs before that)
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on February 23, 2016, 01:11:24 AM
OMG. Thanks for making this! A program crashed and all my RAM was erased. Luckily, PHASM restored Celsium(and my other RAM programs) to my archive. It didn't restore my appvars though. Do you plan on including this?
Title: Re: PHASM
Post by: Dream of Omnimaga on February 23, 2016, 06:18:57 AM
Wait, since when does PHASM have a memory restore feature? Are you sure Cesium and the other RAM programs weren't just already archived? Or is it an undocumented PHASM feature? In Epharius latest posts I couldn't find any info about such feature. ???
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on February 23, 2016, 02:40:31 PM
When you've been using PHASM for awhile, three programs appear: PPHASM, TTEMP, and RRESTORE. After reactivating Phasm because it was archived, I ran RRESTORE and got Celsium back. I didn't know if this was documented or not, just that it was extremely helpful. :P
Title: Re: PHASM
Post by: Dream of Omnimaga on February 23, 2016, 08:20:45 PM
Interesting. /me pokes @Epharius for explanations :P

Maybe it's an unfinished feature that he didn't document yet in case it has bugs? I am curious about where it stores its backups, though.
Title: Re: [84+CE] PHASM
Post by: Epharius on February 24, 2016, 08:30:53 PM
Well, it is a mysterious feature, almost an easter egg!
To be honest, I didn't think you could use it in that case  :P

Let's explain : Originally, I should replace the name of RRESTORE, PPHASM and TTEMP by 0RESTORE, 0PHASM and 0TEMP to prevent the user to use them incorrectly, but I forgot and I didn't change anything x)
RRESTORE is used to restore (Thank you Captain Obvious) PHASM, after running a program, in the saferam (for example if you use Cesium, which uses this place, else PHASM would crash).
TTEMP is the copy of the program being executed.
PPHASM is a basic program which contains :
Asm(prgmTTEMP
Asm(prgmRRESTORE


However, you restored Cesium because every archived programs executed are saved in TTEMP, and after prgmRRESTORE, PHASM restore it :
ld hl,TEMPname
call _Mov9ToOP1
call _chkfindsym
inc de
inc de
pop bc
push de
push bc
call _poprealo1
call _chkfindsym
call nc,_DELVARARC
pop hl
push hl
bit isProtected, (iy+asm_Flag3)
jr nz,protectedProgram
call _createprog
suitProtectedProgram:
inc de
inc de
pop bc
pop hl
ldir


But it means you also archived TTEMP, RRESTORE and PPHASM, am I wrong?

For the next version of PHASM, I replaced the first character of each name by a 0.
Title: Re: PHASM
Post by: Dream of Omnimaga on February 24, 2016, 08:57:58 PM
What is the memory limit of what can be saved and restored?
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on February 24, 2016, 10:39:53 PM
Quote from: Epharius on February 24, 2016, 08:30:53 PM
But it means you also archived TTEMP, RRESTORE and PPHASM, am I wrong?
Nope. I left them as-is. Maybe this had something to do with the fact that I used Celsium to hide PHASM after activation. :walrii:
Title: Re: PHASM
Post by: Epharius on February 25, 2016, 07:39:04 PM
There's no "limit", only your free RAM (I cannot do differently because I must save the program in ARC and I can't execute an archived program).

That's pretty weird, they should have been deleted with the RAM CLEARED x) the three programs are independent of PHASM
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on February 25, 2016, 09:09:27 PM
They were. I reactivated PHASM after the RAM clear(I keep it archived and hidden after activation), and they appeared. I thought RRESTORE meant RAM RESTORE, so I ran it.
Then Celsium appeared in my archive, and I unarchived it and ran it. Celsium opened. When I exited, prgmA appeared in my RAM. Happiness. :P
:walrii:
Title: Re: [84+CE] PHASM
Post by: Epharius on March 12, 2016, 07:55:45 PM
(yes this post is a bit similar to the post on cemetech :p)
Hey people!

Today, I'm glad to show you the first real version of PHASM!

Indeed, I worked hard to add one feature, which looks easy at first sight but which is actually pretty difficult to program. What did I do? I added the ability to execute archived/assembly sub-programs! And I also translated the program into english. Programing this, seems to be very fast... "seems"

Anyway, if we sum up, PHASM can :
- execute assembly/archived (sub-)programs
- jump to any Lbl you want by pressing [2nd] [X,T,O,n] while editing a program
- edit every program, even archived
... for now.

I talked of "a first real version of PHASM". Why? Because I also fixed a loooot of bugs! That's why I called this version "1.0". Therefore, you can install PHASM without be worried about a potential RAM CLEARED ;)

Anyway, you can already download PHASM 1.0 here : http://ti-pla.net/a318384
The source code is also on github : https://github.com/MathisLav/PHASM

I hope you'll use it ;)
Title: Re: PHASM
Post by: Dream of Omnimaga on March 12, 2016, 08:41:08 PM
Yay for archived program execution. Can we run them without the Asm() command too, like with Noshell abd Doors CS series?
Title: Re: [84+CE] PHASM
Post by: Epharius on March 12, 2016, 09:00:19 PM
Yes you can, at first I thought it wouldn't be a good idea to allow the user not to use Asm() (that's a bad habit if the developer want to share his program). But actually it's easier to run assembly programs without making the difference :P
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on March 12, 2016, 10:06:54 PM
Oh yay! You fixed this! :) I saw it when you had updated it first on TI-Planet, then looked again and saw the alert.
I'll get the fixed version on my CE soon.
Title: Re: PHASM
Post by: Dream of Omnimaga on March 13, 2016, 02:32:03 AM
Quote from: Epharius on March 12, 2016, 09:00:19 PM
Yes you can, at first I thought it wouldn't be a good idea to allow the user not to use Asm() (that's a bad habit if the developer want to share his program). But actually it's easier to run assembly programs without make the difference :P
Well, one trick could be to disallow running programs without Asm() from inside TI-BASIC code, so it only works from the home screen. That way people won't risk releasing games that are dependent on Homerun shells.
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on March 13, 2016, 02:35:46 PM
Sounds good to me! :)
Title: Re: PHASM
Post by: Epharius on March 13, 2016, 07:20:41 PM
Yea, you may be right, I'm going to disallow running sub-programs without Asm()
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on March 13, 2016, 09:41:26 PM
And by PHASM 1.0, did you mean it's now out of beta?
Title: Re: PHASM
Post by: Epharius on March 14, 2016, 05:20:38 PM
Yep, there is no bug. At least, I fixed all the bugs I knew ;)
Title: Re: [84+CE] PHASM
Post by: Dudeman313 on March 14, 2016, 07:51:33 PM
Well, then I'm sorry to inform you that there may be another one... :(
When I was using PHASM to edit programs, I ran one that used Textlib, and it
gave me an argument error. Also, when I tried to run Celsium's prgmA, it also
gave me an error. It wasn't until I completely rid PHASM of my CE that ASM
things worked.  :-\
Title: Re: PHASM
Post by: Epharius on March 14, 2016, 08:43:20 PM
(There you go! I've prevented the user from running assembly subprograms)

No problem, I'm gonna see what's wrong with PHASM, just wait for a new version ;)
Title: Re: PHASM
Post by: Epharius on October 15, 2016, 08:23:34 PM
Hello from the other side,

I'm proud to show you a new version of PHASM! Actually, this new version is very important. Let's recap what's new :
- First of all, I added a memory editor that will allow you to edit any AppVar you want, but not only! Indeed you can edit the entire memory with one restriction : you cannot of course edit the ROM (but you can read it). So indulge yourself :P (but please, be careful when editing the memory, I cannot be responsible for any damages you cause due to the way you use this feature).
- Next, many bugs have been fixed since the last version (especially memory leaks). Unfortunately, the program is not yet compatible with Cesium (but it's ongoing).
- You can now use the "Goto" option when an ERR: occurs, even if the program is Archived. It could be very useful when debugging a program.
- I translated PHASM into French (but is of course still avaible in english), and feel free to ask me if you want to add a new language ;)

You can download PHASM here (https://tiplanet.org/forum/archives_voir.php?id=318384).
If you want to know all the features available, visit the first page of the topic ;)
Well, everything seems to be said! Next step : make a "Add your own plugins" which will enable you to create your own plugin to add to PHASM :D
Title: Re: PHASM
Post by: Dream of Omnimaga on November 03, 2016, 05:44:34 PM
Glad to see a new version out. I was worried it was dead. :P Memory editing sounds like Calcsys, am I right? That might be handy.

As for plugins, will they work to change the shell look or will they be more to add sub-routines to ASM/C games?
Title: Re: PHASM
Post by: Epharius on November 13, 2016, 11:26:57 AM
What I plan is a system which would easily allow everybody to add a hook to his calculator, without worrying about the "hook chaining". Obviously they won't be used in order to change something in a game but for something more "global", like displaying new items in a menu etc... ;)

PHASM will never be dead, I swear  :P
Title: Re: PHASM
Post by: Dream of Omnimaga on November 13, 2016, 03:13:49 PM
That would be nice. At least we would not be forced to use one specific shell this way or have to install stuff every few minute.