Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - calcdude84se

Pages: 1 ... 12 13 [14] 15 16 ... 161
196
TI Z80 / Screenshot Hook
« on: August 19, 2011, 07:23:48 pm »
I saw this post and decided to write a keyhook that puts the current LCD contents into a pic variable.
You install it by running prgmASAVEPIC and take a screenshot by holding [ON] and pressing a key from 0 to 9.
Currently it has basic functionality and is useful, but be aware of the following limitations (some of which I can fix and will probably get around to fixing):
Although you can start it, there is currently no specific way to get rid of the hook. If you have CalcSys, you can manually reset bit 0 of (iy+$34), but other than that the only way to get rid of it is a RAM reset. (Though it works fine and there's no reason to remove it :P)
It doesn't chain the current keyhook. It can probably be successfully chained, though, so for apps that have keyhooks and do chain them, you just have to install my hook first.
It overwrites picvars in RAM, and will not take a screenshot if the picvar is in flash. These are both intended.
It will create picture variables as necessary, but will not if there is no free RAM. This is only a problem when free RAM could be gotten, i.e. when the edit buffer is open (e.g. on the home screen). I'll look into making it work when the edit buffer is open.
It saves 768 bytes. If the picvar chosen already exists, but is only 767 bytes (as viewed from the memory menu), it will overwrite 12 bytes of RAM. Make sure they are 779 bytes.
It only works within bcall(_GetKey). This is a result of using the GetCSC hook. You probably won't be able to use it in most of your favorite ASM programs.
In the ASM programs in which it does work, it carries the potential to break them if they expect OP1 to remain intact across a bcall(_GetKey)

Other than that, have fun! (The .8xp is a binary, .8xv is Mimas-format source (yay!), and .z80 is said .8xv converted)
(Note that you can use it on the homescreen or in the program editor, you just need to have a 779-byte picvar in RAM first.)

197
TI Z80 / Re: On-the-fly screenshots (homescreen only)
« on: August 19, 2011, 02:21:48 pm »
To complement ephan's UI, and whatever Deep Thought has in the works, I made a very simple UI that doesn't even require any JavaScript and can be found at http://calcdude84se.tk/homer.html

198
Miscellaneous / MOVED: spambot topics
« on: August 19, 2011, 12:07:32 pm »
This topic has been moved to Spam.

http://ourl.ca/12618

199
TI-BASIC / Re: TI-BASIC equi challenge
« on: August 19, 2011, 10:21:11 am »
Now it returns a list of various numbers and 0's :P
I'd think that, if you're returning a list, you should get rid of the 0's.

200
Miscellaneous / Re: What is your avatar?
« on: August 19, 2011, 10:16:04 am »
Why, so we confuse you with dman2073? :P

201
TI-BASIC / Re: TI-BASIC equi challenge
« on: August 19, 2011, 10:14:00 am »
Code: [Select]
sum(L1->S
0
For(A,1,N
Ans+L1(A
If 2Ans=S
Disp A
End
This acts like ztrumpet's, but is better, I think. For a version that meets your requirements (assuming that "return" means put into Ans, and you only want one equilibrium index):
Code: [Select]
sum(L1->S
0
For(A,1,N
Ans+L1(A
If 2Ans=S
A+N->A
End
A-N-1
Ans-not(Ans
Since TI-BASIC lists are 1-indexed, though, wouldn't it make more sense to have it return 0 if nothing is found? (For my program, just cut off the last line to have it return 0 if nothing's found)
Edit: Deep Thought: that returns a list of 1's and 0's...

202
News / Re: OmnomIRC moved to new server
« on: August 18, 2011, 10:43:02 am »
Oh my... That was a bit much on SirCmpwn's part :crazy:
The permban is definitely deserved, I think.
Spoiler For Question:
On the off chance that at some point in the distant future SirCmpwn changes his behavior, can permbans be appealed?
As for the channel, I think it's fine if it remains on EFNet for the most part. We haven't had any real impersonation issues or anything, so it doesn't seem necessary.
Edit: annoyingorange, most likely.

203
TI Z80 / Re: Online Z80 tables
« on: August 16, 2011, 02:53:41 pm »
Can you detect simply whether the cursor is in a table or not?
If so, the trigger to remove the pop-up would either be moving out of the table or onto a cell without a pop-up. Being in the table but not being on any cell would just keep the state of the pop-up as before.
It wouldn't be perfect, admittedly; you could stay in the space between cells and, say, have the pop-up for nop up next to rst 38h, but if it's possible, it could work.

204
TI Z80 / Re: Online Z80 tables
« on: August 16, 2011, 02:28:07 pm »
Of course it is, but I was hoping one could search for something like 01?????? and get all the 8bit LDs and a couple of other things
You can just look at rows 4, 5, 6, and 7 to get the same effect, couldn't you?
Deep Thought, can the space be put into the table cells themselves?

205
TI Z80 / Re: Online Z80 tables
« on: August 16, 2011, 07:32:29 am »
Thanks to Runer112 for letting me nuke his bot with queries for every single opcode, so I could steal his descriptions :D
[emphasis mine]
Ah, so that was why it was called NukeBot. ;D
It looks very nice; the only issue I have with it is that the information pop-up vanishes briefly when the mouse is moved into the empty spaces between the table elements, which makes it look rather awful.

206
Axe / Re: Reading from Archive
« on: August 15, 2011, 02:36:07 pm »
Runer112 offers another solution for running archived code, in contrast to my earlier idea:
Say that the largest subprogram is 256 bytes. At the very beginning of the program, put Asm(0000...0000), where there are 256 00s.
Then, your subprograms can be run like this:
GetCalc("prgmSUBPRGM",Y1)
Copy(Y1+2,E9D95,256)
(E9D95)()

There are some limitations to this method, though.
Axe's more complicated built-in routines only get included in the compiled program once when they are used. This way, they'd be included once in every subprogram.
You'll have to treat each subprogram as a blob. That is, you can only run it from the beginning, not use any routines in it. Same for trying to run routines in the main program from a subprogram. No can do. The first problem is actually a specific instance of this one.
If you want more capability/flexibility, you'll have to use assembly. That, or manually calculate addresses. x.x

207
Axe / Re: Reading from Archive
« on: August 15, 2011, 01:53:10 pm »
Oh, you mean storing the source code in multiple programs. The source can be either unarchived or archived, it doesn't matter.

208
Axe / Re: Reading from Archive
« on: August 15, 2011, 01:43:00 pm »
Archived code...
Well, you have two options for that, if you really need to do it.
The first option is to make your program an app. That gives you almost 16KiB total space for in-program code and data.
You can store code in appvars if you really want to. You wouldn't be able to run it directly from flash; you'd have to copy it to RAM first. Since Axe doesn't have the ability to compile to a base address other than $9D95 (programs) or $4080 (apps), any code would have to be in assembly. That said, such an appvar could be run like so:
Return!If GetCalc("appvCODE",Y1)
Copy(Y1,L3,{Y1-2}r)
(L3)()

I highly recommend that you use an app, though.

209
Axe / Re: Reading from Archive
« on: August 15, 2011, 12:16:22 pm »
Code: (Axe) [Select]
"prgmPROG"→Str0
Archive Str0
That's how you can archive a program/appvar/etc. Unarchiving is similar.
Moreover, Axe has a feature known as "files" that allows you to read directly from ROM. It's a bit slower, but it might be fast enough, and you could always copy the data to a saferam location.
For example, this code prints (or at least tries to) the string in the archived appvar STRING, which should be at most 768 bytes lest this overwrite something important, and which should end in a null so it doesn't display more than it should:
Return!If GetCalc("appvSTRING",Y1)
Copy(Y1,L3,{Y1-2}r)
Disp L3

To my knowledge files support Copy( and dereferencing ("{}")

210
ASM / Re: LCD Delay Ports
« on: August 15, 2011, 10:52:43 am »
It just waits the number of T-states that are 1/4 the port's value.
So, to answer your questions, no, it will not continue executing, and no, it will not wait for the byte to be successfully sent. It will just wait a certain amount of time.

Pages: 1 ... 12 13 [14] 15 16 ... 161