Do you think that it is feasable and/or possible to port CP/M to the TI-8x series?
Yes
 50%  [ 4 ]
No
 50%  [ 4 ]
Total Votes : 8

And about periph8x, you will need all except periph8x.* and msd.asm (and maybe others). The rest are required files for the driver. There are no docs as periph8x isn't really coded nicely? (I don't remember the reasons on why not to use that particular one other than it is old and not updated) Ask BrandonW, OR, use the ti89 version at http://brandonw.net/svn/calcstuff/Linky/trunk/USB/. The USB controller for the ti84___ is the same as the TI89 (except that the ports aren't memory-mapped). I know it works as GlassOS uses it with only SDCC-port conversions, no concept changes needed.

I am sure that reading the C version will make the process for writing the asm version easier... or, you could grab the asm output from SDCC (That works, too, about 2KB for the hook, helping functions, and all).
This is the user manual (I think): http://www.retroarchive.org/docs/cpm68_sysguide.pdf Everything is worth reading, but especially section 5.

Also, I created a sourceforge project for this called TI/M.

***EDIT***

Use this one instead: http://www.audiography.com.au/Software/CPM3%20System%20Guide.pdf

This page also has good stuff: http://www.audiography.com.au/Software/Downloads.htm
I think there should be actual progress before starting a SourceForge project page. Razz
Oh, well. Give me a week. I might have something primitive up by then.
souvik1997 wrote:
I think there should be actual progress before starting a SourceForge project page. Razz


Indeed. From my past, I can tell for a fact when a developer make a .webs forum, a sourceforge/google code page, and even an email account just for the project before any work is done, the project won't ever even be started. Overplay of something you will do is a fault of human nature and when it comes into effect, you don't want to do any real work on the project Wink
Hey everyone, I uploaded something to sourceforge.net! It's primitive, but better than nothing. It's in 8080 asm, so if anyone wants to convert it...

The link: https://sourceforge.net/projects/ti-m/files/
seana11 wrote:
It's in 8080 asm, so if anyone wants to convert it...

That is your job. Wink


Quote:


Also, how did you license the project, and is it compatible with the licensing of the CP/M source you are starting from?
elfprince13 wrote:

Quote:


Also, how did you license the project, and is it compatible with the licensing of the CP/M source you are starting from?

SourceForge Project page wrote:
2. Liscense: As far as I can tell, CP/M 3 (What I got the source from) is released into the public domain. As I am creating a completely seperate prodject, I am releasing under the GNU General Public Liscence so that all of my friends can mess around with it.


It doesn't seem like it would be too hard to convert it from 8080 to z80. This might be useful: http://nemesis.lonestar.org/computers/tandy/software/apps/m4/qd/opcodes.html
I have two tables of opcodes, one z80, one 8080, (Included with the source) to help convert. The tricky thing will be dealing with the 8080 directives
seana11 wrote:
I have two tables of opcodes, one z80, one 8080, (Included with the source) to help convert. The tricky thing will be dealing with the 8080 directives
Hopefully it won't be too bad, since the two CPUs were meant to run almost the same code.
iirc, it shouldn't be a killer. I once was stupid and heard the 84+ ran on an 8080, so I tried to learn 8080 assembly. I'm not sure about the hex opcode equivalents, but overall the 8080 is quite a bit simpler with its instructions, and anything in 8080 code would transfer to highly rudimentary z80 code. That could lead room for optimization, or obfuscation in translation. With that being said, it is extremely easy to translate from 8080 to z80 directly, as you can directly compare opcodes of the two entities. As you can see, the z80 adds highly useful 16 bit math and indexing commands.

Good luck! I suggest to use TASM for assembling your 8080 code if you for some reason need to compare hex files, it has good support for that; same with the z80 though, I would normally suggest someone like brass or SPASM for z80 coding but for this job I think TASM would require the least work.
What I really need help with is making sense of all the directives. There's $s and %s and @s all over.
Well, I'm not familiar with '@' directives besides anonymous labels, but I'm assuming most cases where you'll find $ or % is to denote hex or binary numbers, respectively. If you post some code here with them (onlya few lines though Wink) I'm sure we can confirm these guesses.
Sorry, @ and ?. And they're in the directives. For example:

Code:

; memory control

   public @cbnk         ; current bank
   extrn ?xmove,?move      ; select move bank, and block move
   extrn ?bank         ; select CPU bank
While I'm not certain what those do, they most likely just affect how the processor uses memory. It would be very profitable to find out what assembler was used to compile the 8080 version of CP/M.
I think that public and extern provide include functionality. Public declares those labels veiwable to the outside world, and extern imports the functions.
Quote:
This ZIP file contains the original source code to CP/M 3.0. It was written
in PL/M. Check out the Intel web site for what is supposed to be the original
PL/M compiler used on this source code. It is intended for the ISIS operating
system, and the package includes an ISIS emulator for the PC.

Let us know if anybody succedes in translating the PLM into something more
useful.


There were a lot of PL/M source files in the zip, but I didn't include them.
public and extern are indeed used when linking modules together (LINK will do the job).

You will need to use the CP/M (or compatible) developer tools to build a CP/M 3 BIOS. Z80MU will provide a decent emulated environment to run these tools. I personally used M80 (Microsoft's assembler) to compile the source and the standard CP/M LINK to link the files into the requisite relocatable module for use with GENCPM. Your command-line will likely look something like this:


Code:
M80 =SCB
M80 =BIOSKRNL
M80 =BIOS3
LINK BIOS3[OS]=BIOSKRNL,BIOS3,SCB


The only file you should need to modify is BIOS3.MAC for your custom machine.

Once completed you will need to use GENCPM to produce the CPM3.SYS file that you can boot the computer from. The CP/M documentation describes the format of this file in detail.

Here is the source for my BIOS and M80-compatible BIOSKRNL.MAC, SCB.MAC and MODEBAUD.LIB. For the sake of completeness I have included my GENCPM.DAT though the answers will likely not be relevant for the calculator version of CP/M.

There is absolutely no need to port any 8080 code to the Z80 as the Z80 is binary compatible with the 8080.

You have been reading the CP/M manual, I presume? It goes into some detail on how you should build your BIOS.
Thanks, I have all of the files, except for the BIOS3 one- what's the diff between that and the BIOSKERNAL one?
BIOSKRNL performs a number of boilerplate tasks for you (e.g. I/O redirection and automatically initialising drives when CP/M boots).

BIOSKRNL calls machine-specific instructions in the BIOS3 module - that's why you need to tailor BIOS3 for your particular machine.

If you don't have them yet, download the four manuals under "CP/M 3 manuals in PDF format". The System Guide is especially relevant, as it contains useful information that you've asked about above, such as:

Quote:
4.2 Conventions Used in BIOS Modules

[...]

External names can refer to either code or data. All predefined external names in the modular BIOS prefixed with a @ character refer to data items. All external names prefixed with a ? character refer to a code label. To prevent conflicts with future extensions, user-defined external names should not contain these characters.
Ooooh, that makes so much more sense. Thanks.
  
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 3 of 3
» 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