Re: A83: Self Executing Programs


[Prev][Next][Index][Thread]

Re: A83: Self Executing Programs




You're right.  I really thought I had this figured out, but then, for some
reason, prgmZASMLOAD wouldn't run any of my squished programs, except for
ZTetris.  Anyway, since it can't contain tokens besides 0-F, here was my
idea:

PROGRAM:ABC
:"tanh-1(EndQ*row+((squared symbol)
:"ABC
:Send(9prgmZASMLOAD
:sinh-1(

I thought about this a lot.  The first part of that is ignored by basic
because of the ".  I understand the " to be ld hl,(00).  That's pointless,
so it works in both basic AND asm.  It then executes itself squished using
ZASMLOAD.  All of that is copied to 9327h, where the first part of the code
is ld hl,(00), then jr 9336h, which skips the running part, and goes
straight to a "ret."  I don't know if this works or not, because ZASMLOAD
messes up for me, but maybe one of you could try it out and tell me how it
works.  Thanks.


----- Original Message -----
From: "Sebastiaan Roodenburg" <sebastiaan@rimsystems.nl>
To: <assembly-83@lists.ticalc.org>
Sent: Tuesday, June 27, 2000 8:31 AM
Subject: RE: A83: Self Executing Programs



I've tried a few things...

first i tried:

--- prgmB
:prmgB
---
and this worked "fine" (got a "Memory" error after a while)

then i tried to exec prgmA form the tios ("Send(9prgmA"), and i got an
syntax-error...

I think that unsquished asmprograms cannot contain tokens other than 0..F

-----Oorspronkelijk bericht-----
Van: Jimmy Conner [mailto:timagic@yahoo.com]
Verzonden: dinsdag 27 juni 2000 7:21
Aan: assembly-83@lists.ticalc.org
Onderwerp: A83: Self Executing Programs



I have been toying with a few ideas lately.  One of
which was an assembly program (unsquished but possibly
squished if you write a small loader) that executes
itself, without having to have a seperate file to do a
Send(9prgmB.

  I played with it for a while and couldnt get it
right, so I though I would throw it out to the list to
see what ya'll could come up with.

Anyways, here is the jest of the Basic Code...

---prgmA


1809  ; Basic ignores this, but it is a jr
Send(9prgmA    ; Execute itself
Return
C9    (this is the start of your program)
End  (standard ending)
0000
End

-----
The amount of bytes that it is jumping may be wrong, I
just glanced over it, remember you have to count the
returns too (3fh)

I couldn't get it to work properly, but I don't know
if the problem is that it doesnt like to execute
itself, or that it has a wrong # of bytes (most
likely), or what ever...  I tried a hell of alot of
things, and nothing seemed to work.

Well let me know if anyone has an ideas on how to get
this to work.

Jimmy Conner

=====
»»»»»»»»»»»»»»»«««««««««««««««
»      TIMagic@goatse.cx     «
»  http://www.zed80asm.org   «
» http://www.timagic.cjb.net «
»»»»»»»»»»»»»»»«««««««««««««««

__________________________________________________
Do You Yahoo!?
Get Yahoo! Mail - Free email you can access from anywhere!
http://mail.yahoo.com/





References: