RE: Running the x18 simulator from Xwindows Colorforth?
John Drake <[email protected]>
| Newsgroups | gmane.comp.lang.forth.colorforth |
|---|---|
| Message-ID | <[email protected]> |
--- Roman Pavlyuk <[email protected]> wrote: > Hi Ray, > > One of key differences between native and Windows > ColorForth memory models > is in the fact that it's impossible (or I just do > not know how?) to allocate > memory below 64K limit under Windows (using > VirtualAlloc). So if there's > code that's using absolute addresses, it won't work > properly. Usually here > are variables where you can just set base address, > but I did not play with > x18, so I cannot tell you any details. > > BR, > Roman > > P.S. I'm glad to see some activity inthis list :) Hello Roman. I actually got this working. I'm sorry. I thought I had reported that to the list. Basically I change how "block" works. Here's the trick. Magenta variables actually point to a memory location inside the block of code where they are defined. So if you put a magenta variable at the beginning of a block, then when you access it the address it returns is 1 plus the block offset. Look at the block definition in "block 30". http://www.dnd.utwente.nl/~tim/colorforth/ether-ip-udp/oninshiko/net.html I changed the code: ( colors etc ) : block 100 * ; : white ffffff color ; . . . To read: var blk 0 ( colors etc ) : block -30 + 100 * blk + -1 + ; : white ffffff color ; . . . After doing this all code that uses "block" works just fine. All of the x18 experimentation / development I've done recently I did using Windows ColorForth, including a new/improved x18 disassembler. Regards, John M. Drake __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com