Jump to content
IGNORED

Starting to code for the TI-99/4a


Atarigmr

Recommended Posts

Hello

 

Yesterday I have started to read about this machine, and I find that it is quite interesting.

 

I am not acquainted with the TMS9900 processor but I am with the following ones: 6502, 6809, z80 and the 68000, from what I have read about the processor I don't think I will have major problems with it.

 

I have downloaded the Asm994a Assembler (v. 3.009). I have typed and compiled a very simple test program, and then ran it with classic99 and it worked just as expected. At the moments I am reading about the VDP and the inner workings of the Ti-99/4a but I got worried when I came across in another thread where it was mentioned that there is a bug in this version of the assembler(instruction JMP?!), and it was mentioned also a patch but I couldn't download it, could someone send it to me(pvt me)? Also I couldn't find any documentation on this assembler, it would be nice to have it, in order to know what directives etc I can use.

 

Are the existing emulators (Mess, classic99, and the simulator that comes with the assembler) reliable enough to be used for development/testing?

 

Thanks

Link to comment
Share on other sites

MESS is in a constant state of change. One version may work perfect and the next may break all kinds of things.

I think the active authors have their favorite machines and pretty much ignore anything else when testing revisions.

MESS has decent debugging capabilities for most machines but I've never used the TI emulation

 

classic99 has seemed to be pretty stable for me but I haven't done a lot of development for the TI.

I have seen a few bug postings related to it though so it's something to look for if some code doesn't work as expected.

Link to comment
Share on other sites

I use Classic99 to do all my development work. Love it!

 

The only thing I've recently done is started using A99Exe to do the actual compiling work, because it runs in a DOS prompt and is very fast, much faster than the emulated assembler. I had to get the original author to provide me with a 64-bit version of the executable, though.

 

Also, I only create the object file that way. To create the E/A Option #5 memory-mapped files, I use Classic99's debugger to save them off. All you need to do is load the object file then set the debugger to stop at the first address in high memory. Then you can save it off as files.

 

Adamantyr

Link to comment
Share on other sites

Yesterday I have started to read about this machine, and I find that it is quite interesting.

 

Welcome aboard! ;-)

 

I am not acquainted with the TMS9900 processor but I am with the following ones: 6502, 6809, z80 and the 68000, from what I have read about the processor I don't think I will have major problems with it.

 

The biggest shift in thinking with the TMS9900 is probably the idea of the context switch for switching among 2 or more workspaces (sets of 16 workspace registers) in CPU RAM-space. The CPU has only 3 registers: Program Counter Register (PC), Workspace Pointer Register (WP) and Status Register (ST).

 

I have downloaded the Asm994a Assembler (v. 3.009). I have typed and compiled a very simple test program, and then ran it with classic99 and it worked just as expected. At the moments I am reading about the VDP and the inner workings of the Ti-99/4a but I got worried when I came across in another thread where it was mentioned that there is a bug in this version of the assembler(instruction JMP?!), and it was mentioned also a patch but I couldn't download it, could someone send it to me(pvt me)?

 

Copy the link to a text editor, strip off anything that follows "...zip" at the end and paste the result into your browser's address field. If that doesn't work, PM me.

 

Also I couldn't find any documentation on this assembler, it would be nice to have it, in order to know what directives etc I can use.

 

You may already know this: The TI-99/4A development resources thread on this forum has most of what you'll need. It does not have the manual specific to Asm994a, however. There is documentation with the Win994A installation, but the program is fairly self-explanatory. As long as you follow the TI Editor/Assembler Manual along with help from this forum, you will probably be fine.

 

Are the existing emulators (Mess, classic99, and the simulator that comes with the assembler) reliable enough to be used for development/testing?

 

I much prefer Classic99 for its debugger, but the others should be fine, as well. The latest Classic99 now allows sector writes to DSK TI disk images, though not DSK file I/O. For that, you need to set Classic99 to use the FIAD disk option. I need DSK sector writes for TI Forth; but, I may soon modify TIF to do Forth block processing using file I/O much as @Willsy's TurboForth does.

 

...lee

Link to comment
Share on other sites

Yesterday I have started to read about this machine, and I find that it is quite interesting.

 

I am not acquainted with the TMS9900 processor but I am with the following ones: 6502, 6809, z80 and the 68000, from what I have read about the processor I don't think I will have major problems with it.

 

The 9900 is very easy to learn and has a "nice" assembly language. I never really understood what that meant until I learned x86 assembly, and recently after looking into some of the 8-bit CPUs...

 

I have downloaded the Asm994a Assembler (v. 3.009). I have typed and compiled a very simple test program, and then ran it with classic99 and it worked just as expected. At the moments I am reading about the VDP and the inner workings of the Ti-99/4a

 

Same VDP as the ColecoVision, ADAM, MSX1, and others. You might want to search for "assembly" in this forum. Tons of threads. A good one for getting a nice workflow set up is:

 

http://www.atariage.com/forums/topic/179103-assembly-under-emulation/

 

 

but I got worried when I came across in another thread where it was mentioned that there is a bug in this version of the assembler(instruction JMP?!), and it was mentioned also a patch but I couldn't download it

 

It has been posted in the forum a few times, "search" is your friend. Here is a link to one of the threads that has the .zip file. It contains V3.010 of the assembler and is a complete .exe, not a patch. You can run it stand alone, or install Win994a V3.009 and then overwrite the asm994a .exe with the one from the .zip file.

 

http://www.atariage.com/forums/topic/189618-bug-in-asm994a-v-3009/

 

The bug in V3.009 is with JH (jump high) I think. The V3.009 assembler produces the wrong opcode.

 

Also I couldn't find any documentation on this assembler, it would be nice to have it, in order to know what directives etc I can use.

 

The docs for the assembler itself are installed with Win994a, but it won't teach your 9900-assembly. For that, see the resource thread (sticky at the top of this forum), or search the forum. There is a ton of assembly info here for people getting started with 9900 assembly.

 

Are the existing emulators (Mess, classic99, and the simulator that comes with the assembler) reliable enough to be used for development/testing?

 

IMO, Classic99. Tursi put a lot of time (years) into Classic99, he actively works on it, and he is very active in this forum.

Link to comment
Share on other sites

There is no specific documentation for the assembler. It supports all the directives/commands that the original TI Editor/Assembler system does. I have examined the executable in a hex editor, and there is some sort of macro system in the ASM994A executable, but try as I might I could not get them to work. I tried various syntax combinations but had no luck. I eventually concluded that macros are perhaps not fully implemented, hence they were never documented by Cory Burr, the author of AMS994A. Cory Burr has, as far as I know, fully withdrawn from the TI community and the Win994A suite is no longer in development.

 

I developed TurboForth, a fully featured Forth system on a cartridge using Classic99, ASM994A and notepad++. I used MESS for testing the disk IO because it's disk emulation is excellent. It's debugging features basically suck ass. My advice is to use Classi99 for 99.9% of your development, and use MESS to sanity check; if you're just doing things like video and sound then you won't need to use MESS at all.

 

Anyway, welcome! You'll find the 9900 a *really* nice and simple processor to code for. As Lee mentioned, the only strange thing is the concept of workspace registers. The 9900 has 16 worksapce registers, R0 to R15. However, they are hosted in RAM, not on the chip. This means you can have as many register "banks" as you have memory for, by simply changing the workspace pointer register (one of the only 3 on-chip registers). Some instructions (BLWP and RTWP) allow you to chain workspaces together, so that a subroutine can have its own set of independant registers, do its work, and return to the calling routine, restoring the calling routine's workspace as it does so. The concept basically replaces a stack and the need to push and then pop selected registers in software (though I remember the 68K had some very neat instructions to do that, allowing 8 data registers to be pushed/popped with a single instruction!).

 

Like the 68K, the 9900 is very orthogonal, you can do most operations on most registers. Beware the shift instructions, they don't like working with R0. Always catches me out. It has hardare MPY and DIV instructions. A really lovely little (actually, rather big!) chip. It's a shame it never caught on.

 

Welcome to the group. Please do feel free to post any questions. There's plenty of folk on here who would be very happy to help.

 

Mark

Link to comment
Share on other sites

Thank you guys,

 

Yesterday I was reading 'beginning-assembly-language-for-the-ti-home-computer-second-edition' and it answered many questions I had about directives and 9900 asm :)

 

Anyone know how the TMS7020 compares to the 9900? Ta.

Edited by Atarigmr
Link to comment
Share on other sites

Thank you guys,

 

Yesterday I was reading 'beginning-assembly-language-for-the-ti-home-computer-second-edition' and it answered many questions I had about directives and 9900 asm :)

 

Anyone know the TMS7020 compares to the 9900? Ta.

 

I don't know very much about the TMS7020 except that it is an 8-bit CPU with stack logic. The TMS9900 is a 16-bit CPU with no stack logic---it uses context switching among workspaces in CPU RAM-space, with each workspace comprised of 16 16-bit registers numbered 0-15. There are, consequently, several differences between the two with respect to assembly language codes.

 

...lee

Link to comment
Share on other sites

I don't know very much about the TMS7020 except that it is an 8-bit CPU with stack logic. The TMS9900 is a 16-bit CPU with no stack logic---it uses context switching among workspaces in CPU RAM-space, with each workspace comprised of 16 16-bit registers numbered 0-15. There are, consequently, several differences between the two with respect to assembly language codes.

 

...lee

 

Thanks Lee.

 

Indeed it will be interesting coding for a processor without stack logic

Link to comment
Share on other sites

Hi there,

 

thought I should finally get me an atariage account ...

 

I used to stay with the Yahoo groups, so you may know me from there, but for all others: I'm Michael Zapf, TI user since 1982, Geneve owner since 1990, ...

 

MESS is in a constant state of change. One version may work perfect and the next may break all kinds of things.

I think the active authors have their favorite machines and pretty much ignore anything else when testing revisions.

MESS has decent debugging capabilities for most machines but I've never used the TI emulation

 

... and mainly responsible for the flawless working of the TI/Geneve emulations in MESS. :)

 

For the last couple of years, the TI and Geneve emulations in MESS have proved to be very stable. They are reliable enough to do any kind of development on them as you would do on the real machine. Some months ago I wrote an XModem tool for MDOS completely within the emulation and later used it on the real machine.

 

If anyone of you using MESS has any questions or problems when using please contact me. More information on that is on ninerpedia (http://www.ninerpedia.org/index.php/MESS)

 

Michael

  • Like 2
Link to comment
Share on other sites

I second Lee's welcoming! Glad you're here Michael!

 

I don't think I ever officially introduced myself to either; the Yahoo Groups or AtariAge. I just "showed up". Been a lurker on the Yahoo Groups for at least five years before I even posted there.

 

I've been a TI'er since 1982 or so as well. Lost interest in the TI world when my Geneve blew up in the early 90's. But couldn't help but return a couple years ago when I ran across some of my old TI stuff at my parents place.

 

Ironically my mom sent me this picture yesterday. It was a cake for my birthday, back in '84! Kinda fuzzy but I think you'll get the "picture". :rolling:

 

Dan%27s%20Birthday%20Cake%20(1984).jpg

 

Anyhow, welcome aboard Michael!

 

(sorry for going off topic on this thread...)

 

-Dano

  • Like 3
Link to comment
Share on other sites

Aha! The legendary Mr. Zapf! WELCOME to Atariage!

 

It's about time we saw you here. Where have you been? :-D

 

LOL, legendary ...

 

Where I was? Well, who's hiding behind "atari"? :-) I only knew about this group because it has sometimes been mentioned in the Yahoo groups. As it seems, there are indeed some interesting topics here. (Oh my, gonna have to read one more forum now...)

 

Michael

Link to comment
Share on other sites

  • 2 months later...

Hey Atarigmr--- have you had much time to work on TMS9900? Would love to see another good assembly programmer on here. =) We have many, but any new addition to our community is most welcome. =)

 

In the development resources thread (sticky thread, top of forum) there are some excellent books (in pdf form) and manuals which help get a newcomer to the TI familiarized with the inner (and outer) workings of the system.

 

And if you have any questions, there are some gurus on here who are always more than willing to share their knowledge! (I'm not one of them, by the way) ;)

 

 

Owen

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...