I have a question. I know that there is data in the VAT relating to a program that is not really used and can be modified without causing issues, as evidenced by Kerm's folder creation in DCS7. I need to set up a flag for something using one of those pieces of info, but it cannot interfere with DCS, obviously. Any ideas?
If I recall correctly, there are two bytes of data that are able to be used. DCS uses one, the other is not used by anything important.
Can someone who knows, or perhaps Kerm, indicate which?
You can use CalcSys to find out.
SirCmpwn wrote:
You can use CalcSys to find out.


I suppose, but I don't trust myself with this stuff yet. I'm still learning. I think that there is a post somewhere about it.
The worst you can do with CalcSys at your skill level is clear RAM.
Ok, I will try. How do I locate a program with CalcSys?
There's a file in there called "readme.txt", you should follow the instructions in the filename.
Ok, found my program. Now what? Never used CalcSys for this before.
CalcSys is a low-level tool for investigating how your calculator works. Read the readme, please, then play around with it and ask specific questions. To view the VAT entry from a program screen, press Alpha+V.
SirCmpwn wrote:
CalcSys is a low-level tool for investigating how your calculator works. Read the readme, please, then play around with it and ask specific questions. To view the VAT entry from a program screen, press Alpha+V.


Ok, so the bytes that aren't really used I found are this...

the type byte (I can't really touch this)
the type-2 byte (DoorsCS uses this)
the version byte (can I use this? I think not?)
You can't touch any of them, sadly. Type is obviously important, MirageOS and Doors CS each use the T2 byte to indicate parent folder for things, and the version byte is only modifiable if you want your calculator to refuse to send that program to any other calculator.
You could set the high bit of T2 and mess around with DCS to try and get around it.
KermMartian wrote:
You can't touch any of them, sadly. Type is obviously important, MirageOS and Doors CS each use the T2 byte to indicate parent folder for things, and the version byte is only modifiable if you want your calculator to refuse to send that program to any other calculator.

That is terrible. Any other suggestions? Could I add a flag byte to the end of the program without causing trouble?

SirCmpwn wrote:
You could set the high bit of T2 and mess around with DCS to try and get around it.

A worthy idea, but I'd need to learn bit masking. Would that not change the value of T2, tho?
It would change the value, but then you might be able to update the folder IDs in the DCS appvar.
SirCmpwn wrote:
It would change the value, but then you might be able to update the folder IDs in the DCS appvar.

I'd rather not mess with the DCS appvar. What of my other idea. Adding a flag byte to the end of the program.
That idea sounds iffy. If you are uncomfortable using CalcSys, then I think I can say pretty confidently that your asm skills are not yet up to the job.
It seems to be easy in concept. hl points to the start of the program. Increase hl by the size of the appvar, then do a bcall(insertmem). Update the size field, then I'm done. Am I mistaken?
What about archived programs?
For my purposes, a program that would be being modified would be in RAM when I'm doing this. If not, I will move it to RAM first.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 2
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement