PDA

View Full Version : Other 8080/z80 operating systems?



Allison
April 17th, 2005, 12:37 PM
I'm curious what other OSs are out there that have available sources for exprimentors to play with.

I have and have used CP/M and NS*dos for over 25 years, occasionally
ran ISIS on Intel MDS but there are others. I'm curious what NON CP/M
OSs are there. Since I'm playing with hardware I may just play with other OSs as well.



Allison

patscc
April 17th, 2005, 02:16 PM
There's a RTOS called Micro C/OS and Micro C/OS II which has been ported to just about every micro controller on the planet. The only place I know to get the source from is a book,

MicroC/OS-II, The Real-Time Kernel, Second Edition’ Labrosse , Jean

which I unfortunately lent out a while ago and it never came back. Should you dig up an electronic copy of the source ported to 8080 or Z80, a link to it would be appreciated. As far as I can remember, it's written in ANSI C.

I also can't remember if it requires any licensing or not, but I figure if the source code is in a book, you can at least play around with as long as you don't sell any products with it.

You could probably use FORTH as a shell sitting on top of a kernal you write, much like machines like the C64 had a few kernal primitives in ROM to load BASIC, and then used interactive interpreted BASIC as a shell.

Supposedly there's source floating aroundI I don't have it) to LDOS 6.3.1, but that would sort of turn your project into a TRS80, which is probably not what you want

I also seem to remember there is( or was) a Minix port available for Z80, but you'd have to dig for it.

Have you tried posting to the comp.os groups, or maybe comp.arch.embedded ?

patsc

Terry Yager
April 17th, 2005, 03:22 PM
I've seen a few monitor programs over the years, but nothing with disk capability, except for CP/M clones. If ya find anything interesting, let us know. Have you checked the Z80 page?

http://www.z80.info/

--T

Thrashbarg
April 17th, 2005, 09:11 PM
which I unfortunately lent out a while ago and it never came back. Should you dig up an electronic copy of the source ported to 8080 or Z80, a link to it would be appreciated. As far as I can remember, it's written in ANSI C.

Does anyone know of an ANSI C compiler with source for the 8080 CPU? I've got some for the Z80 but I'm reluctant to use them incase they generate Z80 specific instructions.

The computer I'm building uses an 8080 simply because I found a few :)

olddataman
April 18th, 2005, 09:02 AM
Have you looked at Cromemco's offerings? They had some interesting stuff. I can't remember any names except "CROMIX" or maybe it was CROMEX. Most of the non-CP/M systems were either clones or flat out rip-offs. This was done by people who did not want to pay Gary Killdall for the use of the real thing.
I don't know what he charged but I remember when you could buy CP/M on an 8" disk, C-BaSIC- ( compilwe BAIC) AND ALL 5 MANUALS for $95.00 or just the disk for under $50.00. I think TDL, in New Jersey, had their own version.
Ray

patscc
April 18th, 2005, 09:47 AM
There's the old BDS C compiler, which is now public domain, at http://www.bdsoft.com/resources/bdsc.html

It runs on CP/M, but generates 8080 opcode. Source is provided for the compiler, it's in assembler, the whole package is only about a 1.5 Mb download.
'
On the page is also a link to an Altair emulator where there's a Altair build of BDS.

patscc

Allison
April 18th, 2005, 02:41 PM
which I unfortunately lent out a while ago and it never came back. Should you dig up an electronic copy of the source ported to 8080 or Z80, a link to it would be appreciated. As far as I can remember, it's written in ANSI C.

Does anyone know of an ANSI C compiler with source for the 8080 CPU? I've got some for the Z80 but I'm reluctant to use them incase they generate Z80 specific instructions.

The computer I'm building uses an 8080 simply because I found a few :)

More than a few. BDS-C, SmallC, There is a Embedded C project and I'm certain I've not listed all. Then there's astec-c, Hitech-c....

Any C-compiler that preduces ASM code for output is easily checked for
Z80 and in somecase it's not a big deal to hand substitute inline 8080code to replace Z80 stuff.

Allison

Allison
April 18th, 2005, 02:49 PM
There's a RTOS called Micro C/OS and Micro C/OS II which has been ported to just about every micro controller on the planet. The only place I know to get the source from is a book,

MicroC/OS-II, The Real-Time Kernel, Second Edition’ Labrosse , Jean


I have C compilers and I've been looking at RTOSs, Very few of them free
and this is just for my hacking.



You could probably use FORTH as a shell sitting on top of a kernal you write, much like machines like the C64 had a few kernal primitives in ROM to load BASIC, and then used interactive interpreted BASIC as a shell.


Forth is ok but after writing Postscript for a while I tired of Forth. The core of postscript is bascially forth like.



Supposedly there's source floating aroundI I don't have it) to LDOS 6.3.1, but that would sort of turn your project into a TRS80, which is probably not what you want


I have it and am looking at it. One concern is if there are dependencies on the TRS80 roms.



I also seem to remember there is( or was) a Minix port available for Z80, but you'd have to dig for it.


I have MINIX, Also have the book and most versions I know of but I've never seen it for Z80. The MINIX core isn't that small.



Have you tried posting to the comp.os groups, or maybe comp.arch.embedded ?
patsc

No, I figure they'd take me for a troll asking about Z80.

Allison

Lisa
September 1st, 2005, 07:30 PM
there's MP/M, a multi user version of CPM.

CP/M User
September 5th, 2005, 01:41 AM
"Allison" wrote:

> I'm curious what other OSs are out there that have available sources for
> exprimentors to play with.

> I have and have used CP/M and NS*dos for over 25 years, occasionally
> ran ISIS on Intel MDS but there are others. I'm curious what NON CP/M
> OSs are there. Since I'm playing with hardware I may just play with
> other OSs as well.

I'm suprised I'm seeing this comming from you Allison - with all of those CP/M based machines, many discussions in comp.os.cpm. Course you could get some sort of frount-line GUI thingy going in CP/M, but it's not really an OS & trying to find one which works on your machine (well it's slightly narrower - since you have several - unless you've binned/sold the lot), AFAIK very little for 8080/Z80 based system.

If your into Amstrad CPCs, there's a project aimed at making an OS, think it's called FutureOS, I believe the source maybe public, but it's very machine specific (they may want others to port the code). There's another one which someone's trying to port to the CPC & I think it's running on a number of other machines (8bits), so it's more portable - unfortunately I don't know the name of this system. I'm certain that it's been made on a C64.

Apart from that, I'm drawing blanks.

CP/M User.

carlsson
September 5th, 2005, 01:02 PM
There's another one which someone's trying to port to the CPC & I think it's running on a number of other machines (8bits), so it's more portable - unfortunately I don't know the name of this system. I'm certain that it's been made on a C64.
ITYM Contiki (http://www.sics.se/~adam/contiki/) by Adam Dunkels et.al. Kevin Thacker finally managed to port/compile Contiki on a Z80 platform (Amstrad CPC) in June this year, only a little more than two years after the first version was announced. The main reason it took so long was that the code written and optimized for the cc65 compiler was not so compatible with sdcc or z88dk compilers, although all three are C compilers. So far, it seems noone has finished a working port on another Z80 computer.

Terry Yager
September 5th, 2005, 01:14 PM
Is that a 64K Contiki, or does it require banked CP/M Plus?

--T

carlsson
September 5th, 2005, 02:15 PM
Not sure what it means, but Kevin writes* that you insert the disk and type RUN"CONTIKI to load it. Does the CPC have some CP/M, Basic or other OS built into ROM?

http://andercheran.aiind.upv.es/~amstrad/download.html

*) in his message to comp.sys.amstrad.8bit on June 13th; google for Contiki in the group

Terry Yager
September 5th, 2005, 02:46 PM
IIRC, the CPC uses a non-standard version of CP/M, (in ROM?), with graphics & color capabilities that would not be understood by most CP/M systems. It also used CP/M 3.0, which is not 100%-compatible with older CP/M 2.2 systems. (CP/M Plus, aka, CP/M 3, allowed the use of extra memory, by employing a bank-switchig scheme).

--T

carlsson
September 5th, 2005, 03:26 PM
Ah. Since it is supposed to be a replacement operating system, I suppose a binary compiled for the CPC would run on another Z80 machine just as little as any auto booting game or other application that is not written to run under CP/M. :) But once there is a working port and compiler, it seems less work to adapt it to the capacities and hardware of another similar computer. Maybe several CP/M machines would even share the same video chip, memory map and low level (or trapped) I/O.

CP/M User
September 6th, 2005, 04:39 AM
"carlsson" wrote:

> Not sure what it means, but Kevin writes* that you insert the disk and
> type RUN"CONTIKI to load it. Does the CPC have some CP/M, Basic or
> other OS built into ROM?

The CPC's have an OS on ROM as soon as you switch the machine on, it also gives you access to BASIC. To load programs from DISC or Tape, RUN"filename would load the program (which can either be a BASIC program or Binary - with Execution address stamped onto the header - not all Binary programs need this address, but for Loaders & stuff it's essential).

"Terry Yager" wrote:

> IIRC, the CPC uses a non-standard version of CP/M, (in ROM?), with
> graphics & color capabilities that would not be understood by most CP/M > systems.

CP/M doesn't reside on the ROM itself (even though you -could- buy CP/M on a ROM board for the CPC & simply type in a command to take you to CP/M command line - it was 3rd party software). Generally CP/M resides on Disc, a System Disc specific to those line of machines which reserved 9k for the CP/M system itself. To load it |CPM at the BASIC prompt would load the contents of this track - hence CP/M. What you did get on ROM though was the DR Logo program - which you'd used in CP/M Plus or 2.2, which resided on the same ROM as the other OS - AMSDOS.

I don't know what you mean by the "CPC uses Graphics & Color which wouldn't be understood by most CP/M systems, unless your talking about the Video Chip (CGA based) 16k of memory. It's also Z80 based - so any programs written using Z80 opcodes wouldn't be too nice for a 8080 - that kind of thing. The CPC also has what's also in ROM is a list of Firmware calls (simular to IBMs Interrupts I spose you could say or in addition to the CP/M Interrupts), though in CP/M operation was different in the assembly between the AMSDOS system & CP/M 2.2 & CP/M Plus. CP/M Plus being very different because of the way memory is arranged. CP/M 2.2 is better, but uses one call with the operational firmware call imediately poked as bytes after that call. In AMSDOS the Call could be made direct, some worked at the BASIC prompt, though not all - RSXe's could be written leading to that operation for use at the BASIC prompt!

CP/M User.

Terry Yager
September 6th, 2005, 06:48 AM
So what happens if you try to run a program written specific for the Amstrad on another CP/M machine? When it comes to one of those "special" system calls, does the program crash, or does it just treat it as a NOP, and continue executing?

--T

carlsson
September 6th, 2005, 10:06 AM
And, will the CP/M (in RAM) overlay the ROMs, and internally switch in and out the Amstrad ROM to access firmware functions? I suppose a C128 could be scrutinized in a similar fashion which Z80 and CP/M programs could be executed, and whether it is possible to make calls into the native C128 ROMs (and even switch CPU) while running a CP/M program.

Anyway, on the topic of compiler issues: sdcc seems to be quite different to cc65 not only as a compiler but also the assembler and linker package. Gábor Lénárt wrote on his blog about recent linker observations (http://blog.lgb.hu/page95). Since things work the way they do, it seems no-one from the Z80 collective seems to share his issues, or they would find another compiler just as different from the other view.

CP/M User
September 7th, 2005, 02:16 AM
"Terry Yager" wrote:

> So what happens if you try to run a program written specific for the
> Amstrad on another CP/M machine?

For memory when you asked what the deal was with one of my Turbo Pascal programs which had CPC firmware in connection with using it for your Epsom Z80 based machine you were telling me the program was Crashing. I changed the name of this file to reflect what the program actually does & not just telling the difference between it for CPC CP/M 2.2 & CP/M Plus. I wrote some universal TP source which -should- work on all CP/M Based machines (except you were telling me this Epsom computer had an unique display - CP/M custom made for it or something!).


> And, will the CP/M (in RAM) overlay the ROMs, and internally switch in
> and out the Amstrad ROM to access firmware functions? I suppose a
> C128 could be scrutinized in a similar fashion which Z80 and CP/M
> programs could be executed, and whether it is possible to make calls
> into the native C128 ROMs (and even switch CPU) while running a CP/M
> program.

I don't know about it overlaying the ROMs, I personally don't think it would, CP/M Plus has been made for a machine with 128k of memory & I believe it's the extra 64k for which it resides on a CPC6128 for instance. The 64k based CPCs such as the Tape Based CPC464 (with External Disc Drive) & CPC664 (with Disc Drive & 64k of Memory) funnily enough cannot run CP/M Plus even when a RAM Pack has been added (giving these systems 128k) - though Patches have been created so it can be used in Conjuction with this machine - as well as the CPC6128.

The Firmware thing hasn't been very well documented & only found out about it from Kevin Thacker, when I was doing some enquirying about using it in connection with this (even John Elliott wasn't sure). I've restricted myself to only using Visual stuff (specifics to the CPC) - tried some firmware based Disc operations stuff which was a big mistake - it's actually better to use the CP/M interrupts (became easier to handle AMSOFT based files for instance once I understood the header bit it uses - in conjuction with writing a visual program in CP/M to load a screen done in an AMSOFT art program - or one from a game). And save it too - with INK colour information (so it doesn't have to be defined everytime a screen is loaded).

CP/M v2.2 is 64k based, from what I can see resides up high in memory &8000+. In AMSDOS mode (BASIC) it take a portion of memory (around &A4xx) which isn't needed in CP/M - so it can use that space (no need to have two OSes residing in memory). When the computer is resetted, some of the upper memory is cleared with AMSDOS based code (past that I believe some of the code used in CP/M v2.2 is still there - &BE80 for instance, which can be used by anyone - including Programmers or Hackers - which allows some small code (approx &30-&40 bytes) going there (I used to put lots of my Loaders into that memory - saved it being corrupt by being elsewhere in memory for a game to load) - this memory isn't cleared until the machine is powered off.

CP/M User.