• Please review our updated Terms and Rules here

TRSDOS/LSDOS 7x

danielbooneamerica

Experienced Member
Joined
Mar 3, 2020
Messages
408
Location
Wayne National Forest
I wanted to ask here in this forum if there would be any interest in a new version of DOS for eZ80 that makes use of available legacy software.

Many long hours led to a kernel similar to LOWCORE/SYSRES/SYS0 for TRS80 series of computers which I hope will allow SYS1-13 to execute unchanged using a eZ80 (or with minor patching).

It is my goal of no reassembly of SYS1-13 but yet execute unchanged as much TRSDOS 6.x software as possible. This is accomplished thru very careful design details of this low memory kernel.

I want to open up as much new modern hardware to older legacy software as possible. At the same time we must realize that we need to be open to new hardware that has not even been developed yet (like could they imagined CF storage cards in 1970's?).

TRSDOS/LSDOS version 6 was to my knowledge the 1st time on TRS80 line they achieved near 100% hardware independence (or very near 100% was goal) between hardware and software.

As it tells you in TRS80 programming manuals for version 6, use only OS service calls to communicate with hardware, never communicate directly between application and hardware.

Programs and even sections of O/S code that followed this rule is then more easily portable to new hardware platforms.

Remember, I don't care what computer it is or what language or compiler you have on this planet, you only see two things, memory & I/O.

I said version 7x in subject line because well 6 is already taken and x for experimental. At this point I am experimenting and testing code I wrote for FLASH DRIVES, RAM DRIVES and what will and will not run. Video memory is simulated and pumped out serial port to a terminal. Networking software was developed and being developed which allows multiple CPU's executing LSDOS to share disk drives.

Myself, I call this NeXTDOS. I feel its the 'next step' in all this evolution, an attempt to take TRSXXX to 24bit level.

Only software developed using device independence will easily port over, no attempt to run model III software has been attempted in this project. It is my hope that all compilers and compiler generated code will execute unchanged.

What ideas does this spark if any?
 
Well behaving TRSDOS 6 applications should be portable across Model 4 and Model II, so this seems to be an attainable goal.

In short, you are proposing a way of running legacy TRSDOS 6 applications on new modern Z80 based platforms. And also providing new APIs used to access modern accessories like flash drives and network adapters. Correct?

This is very cool. Will you be open sourcing the software?
 
Pete, generally what you are saying is correct.

When I started out I wanted to be able to run my legacy software on a new modern eZ80 SBC. Looking around there was not one that was well suited for LS/TRSDOS 6.

I started a rewrite anyway and at some point I realized LS/TRSDOS is very modular. Sys1-13 has very little connection directly to hardware but does have a direct connection to lowcore by calling absolute addresses in lowcore.

At this point I am trying to develop a new BIOS/LOWCORE that has same entry points hoping perhaps we can run sys1-13 unchanged or minor patches. If it will not work out then it will only be a simple matter of reassembly of sys1-13 using updated lowcore entry points.

Most all applications are already hardware independent. I was reading on one website where they recommended LS/TRSDOS 6 programmers to avoid using system supervisor calls (SVC) and just call routines directly in lowcore. This is not only the worst advise I have ever read about TRS80s but perhaps worst programming advice on web.

I wonder if they have ever wrote what Roy Soltoff wrote about programming this machine or if they understand what it means?

Follow rules for portability and all that hard work those folks put into it. Write portable software and we will try to see that it has something to run on in future.

LSDOS 6 was superior to all other home O/S (CP/M MSDOS etc), so good in fact they killed it.

Now that O/Ss such as Lunix is popular and more people are exposed/educated in Unix type O/S, they can see compressions of LS/TRSDOS to Unix (routing, linking, device independent etc). With their advanced overlay feature LS/TRSDOS was getting a lot of work out of an 8 bit machine.

Yes with time I will publish source. Testing now of what works and don't work. I am looking for someone who is developing a eZ80 based SBC with banked memory.

I simulate bank memory now with block moves which is slow but does allow bank memory.
Video memory is simulated and blocked moved, all old video routines run and draws screens in this simulated memory.
Adding a scheduler that allows you to run jobs unattended on a schedule.

Mainly just trying to get a model working that allows for as much legacy code as possible to run.
 
My experiments shows I can start up more that one instance of LS/TRSDOS running in multiple eZ80 64k memory banks. Each one thinks it is a dos running on its own machine.
I want to now write code that allows them to network together.

Like we did in old days on MVS. We had VM partitions and each partition was its own machine networked with others all inside same CPU.
 
Many or several library commands will be purged from sys6, 7 and 8.

New commands will need developed and replace these commands.

New commands can be written in and language that compiles to a load module [fortran, compiled basic, C, etc]. Hopefully some of our C community will give us things like grep.

In addition i am exploring adding ability to add additional user customizable library. This will allow special commands to be added depending on job dos is being used for [in a soda machine, gas pump, solar farm controller etc].

Possibilities are endless....like everything with lsdos.
 
I really like this idea. I've wanted to see an LS-DOS at the next level for a long time; I'm looking forward to this developing and to help out as I can. I'm more of a hardware guy, and so I'm going to put on the front burner an eZ80 design that will be a bit more LS-DOS friendly.

The banked RAM isn't too hard, and, as long as we're willing to leave some of the older parts of the Model 4 design behind (memory-mapped keyboard, for instance, although mapping a USB keyboard to the TRS-80 memory map has been done, and done well) we could have a killer LS-DOS machine. I wouldn't even bother supporting floppies, but floppy and hard drive images on SD card would be something that I would think would be required. eZ80 has SPI in hardware, and there's a CP/M port for eZ80 that can drive an SD card on SPI.

The eZ80's chip selects could be used to map the memory two ways, with linear memory on one chip select and 32K shadowed banked RAM on another chip select, with the hardware that does the mapping of the 32K lower bank paying attention to which chip select is in use, making it possible to run in ADL mode without polluting the memory space with extra 32K lower banks every 64K.... I've got some ideas on that....now to get them into KiCAD.

I guess the question is simply 'how much backwards compatibility is required' of such an eZ80 device. Hmmm, sounds like a poll in the making....
 
I was very happy to find this site because some time ago I started downsizing do to medical issues. Not only downsize but I have had an itch to finish some lifelong project dreams.

Not to diverge from computers but in last few years I have had many surgeries and I do OK but, anesthesia always messes with me and sometimes I mix things up. For example I am afraid until I joined this forum I gave Tim Mann credit for wrong emulator. I even wrote him an email thanking him for job well done. I wondered why I didn't hear back LOL, I am sure he thought what a mixed up guy. OK, now I have it straight.

What I wanted to say is that I see great interest here in retro side of trs80 but in as far as picking up and going forward from model 4 left off, its not a big interest. I have my reasons for wanting to go forward such as embedded controllers and educational etc.

That being said I am preparing to publish source files so you yourself can boot my lowcore and run a partial LSDOS.

What do I mean by partial? It loads lowcore and does all functions not needing overlays at this point. It then loads and runs a diagnostic to test RAM resident SVC functions. If they all pass it then tries to load sys1 from FLASH DRIVE starting at a specific location of flash memory but there is nothing in memory to load. From that point OS is scrolling disk error which it should and further proves its running correctly.

Idea will be I only provide lowcore, you provide your own sys1-13.

But for now its just a demonstration of how this could work. I can release a version of source files of when it worked as I described above and people can play with it and think about it.

It is source revision that is several revisions back from where I am currently, but it is a good demonstration level.

Also at this revision it runs using Zilog simulator software so you don't need actual hardware. This way everyone can try it no hardware needed but your own PC!

Video is dumped to console screen and you can also examine video memory with debug monitor.

Will update this post when it is ready and I think best way to distribute will be for me to email you project file after you download development software from Zilog.

I need to get a technical description/ read me file made to go with source so I need some time. To complicate my medical life further I fell and fractured two bones in left wrist requiring surgery, 11 screws and plate. Sure makes typing hard.

I will post again when I make some progress on read me for source. In mean time if you plan to run this project, download from Zilog their latest free software development system.

Thanks for all the great conversations on this site, I have really enjoyed it.

Daniel Martin
 
Is TRSDOS source in some form available now?

I was searching for "TRSDOS source" and came across this post. I'm encouraged that there are current works to interface to more modern storage device like CF disk. My own work has shown that 20MHz Z80 SBC with CF disk and VGA video can very reliably run to VGA's 25.275MHz (I haven't found any CMOS 20MHz Z80 that CAN NOT run to 25.275MHz). By porting TRSDOS to such system, I can see a fast & inexpensive Model 4 SBC.
Bill
 
Is TRSDOS source in some form available now?

I was searching for "TRSDOS source" and came across this post. I'm encouraged that there are current works to interface to more modern storage device like CF disk. My own work has shown that 20MHz Z80 SBC with CF disk and VGA video can very reliably run to VGA's 25.275MHz (I haven't found any CMOS 20MHz Z80 that CAN NOT run to 25.275MHz). By porting TRSDOS to such system, I can see a fast & inexpensive Model 4 SBC.
Bill

Hello Bill from New Mexico. Hope its warm there. I miss time i lived in Arizona when its cold in east like now. In fact maybe I need a 2nd place for short winter trips.

If you have real estate I can make a DOS version for it. Tell me more about your project. I have two versions or paths of development. One tries to emulate legacy systems as closely as possible in BIOS not hardware. Thus programs written and programmers following the rules and did not talk to hardware directly should port over with little changes if any. This includes executing things like BASIC or C, most of those seem developed to run using system calls and not writing or reading hardware directly.

Second is a more 24 bit version that keeps the flavor and syntax of legacy systems but backward compatibility is not priority; new ideas and innovative as well as trying to make use of features of new hardware available is more the priority.

Using eZ80 as one of many examples to port this too, it is like a 24 bit version. Long long ago military calculated that computers with 24 bit memory and 24 bit math functions could put nuclear weapons anywhere on planet within a couple feet or so. Thats good enough for me. As in example of eZ80 it has 24 bit address bus thus I will call it 24b.

In addition, new overlays, extended overlays, system commands and library commands needs rewritten in a higher level language. I made provisions that any number of different languages could be used to develop new or rewrite existing modules. Any language that can produce programs in load format (compiled BASIC, C, FORTRAN etc). I feel key to new development of software for legacy systems is using higher level languages. In some cases existing programs can be ported over or in case of new development it is a proven fact higher level languages get results fastest.

I do have another version that is sort of like a ROM based OS without ROM. It loads and does not see external drives or overlays etc. It provides basic video screen, SVCs to talk with console input and output etc. I could for example add BASIC to this and it would be very similar to a model 1 or 3 that just booted to BASIC in ROM.

I am sure I am missing somethings here but that is general idea.

Then there is 3rd design we worked up that should execute all software and OS for models 1/3/4 but stalled for board development.

I wish everyone best of luck with projects. For me its not about money but more about helping TRS80 legacy along a little. Injecting a little new life in it and support the old.

Thanks for the interest....

Daniel
 
Thanks for getting back to me quickly.

The specific hardware I have in mind is Z80all, https://www.retrobrewcomputers.org/doku.php?id=builderpages:plasmo:z80all:z80all_rev1

It is a simple standalone Z80 SBC overclocked to 25.275MHz with text-based monochrome 64 column x 48 rows and PS/2 keyboard. It has no ROM other than a small bootstrap ROM in CPLD that loads program into RAM which is 128KB in 4 banks of 32KB. CP/M 2.2 has been ported to it. Video is 4K I/O mapped over a dual port RAM. It is very responsive because Z80 can read/write the video RAM completely independent of video timing. The CPLD is obsoleted Altera EPM7128S but it is compatible to Atmel's ATF1508AS currently still in production. I used EPM7128S because I have hundreds of them instead of paying $8 each for Atmel ATF1508AS. The CPLD is flexible so I can easily change hardware map to accommodate different I/O addresses.

New Mexico is warming up. Daytime high is 50+, but night time is still in high 10's or low 20's (40 degrees temperature swing is not unusual).

Bill
 
Is TRSDOS source in some form available now?....
By porting TRSDOS to such system (as Z80all), I can see a fast & inexpensive Model 4 SBC.

Bill, good to see you here. Yes, TRSDOS/LS-DOS source is available, thanks to the generosity of the copyright owners Bill Schroeder and Roy Soltoff, and I'm gathering what I have that I can share with you to send your way. Specifically, I know of the following places where TRSDOS source can be obtained:
  1. The published set of three books called "The Source" contain the TRSDOS/LS-DOS 6.2 source code for the Model 4. The PDFs of these books can be obtained from several archive sites, one is the cpmarchives.classiccmp.org site's TRS-80 archives.
  2. A disk image of the LS-DOS 6.2 sources for Model 4 and Model II/12, also available on several archive sites, including the cpmarchives.classiccmp.org site mentioned above. This is a pre-release beta copy of the sources;
  3. The LS-DOS 6.3.0 sources archived by Frank Durda IV. These sources have been found. This tree is fully redistributable, since Bill Schroeder, owner of the 6.3.0 copyrights, has released LS-DOS to the public domain.
  4. Pete Cervasio's amazing LS-DOS 6.3.1 reconstruction from typing in the code from "The Source" and then by way of disassembling LS-DOS 6.3.1 he filled in the gaps and updated the sources to 6.3.1; Pete did an incredible amount of work on this. This source is redistributable, and has been on Tim Mann's website for years: TRS-80 disk images and individual files.
  5. A Github project that duplicates and extends the Pete Cervasio reconstruction.
  6. MADSoft's LS-DOS 6.3.1 source code product, by Frank Durda IV, which was also distributed on the now offline nemesis.lonestar.org website. Redistribution of this source tree is restricted; see the copyright statement below. The MS-DOS formatted floppy images of this tree have been rescued and are available, just not via a website or ftp site (A ZIP of this distribution is only 2MB, so it's small enough to be emailed. HOWEVER, several email filters will mark it as malware because of TRS-80 executables being embedded in the ZIP, so it has to be sent in a renamed or repackaged form). The Wayback machine has several snapshots of Frank's site; here is a link to one of the archived copies of Frank's LS-DOS 6.3.1 Source Code Restoration Project but not all of the build tools can be found on the website version; all of the source code itself is present, though. Frank's copyright terms:
    The entire project took about seven months with spurts of work, with approximately 450 hours going into the project. Despite the effort involved, Frank Durda IV hereby releases the output of this restoration project for any use with only two restrictions:

    The /TXT version of this file must remain intact in any electronic
    or other distribution of any part of this release, and

    No part of the distribution or a derivative work may be placed on
    any other web or FTP site without prior written permission. The
    files created as part of this reconstruction and of the official
    web site are copyrighted.
  7. The LSI-DOS 7x project mentioned in this thread. While I have seen an early version of this code, I don't have a copy of it any more (I had agreed to not redistribute anyway, so even if I had it I couldn't hand out a copy), but danielbooneamerica has it and did that port, which on the surface looked like good solid work. But I've had COVID since I saw it, and let me tell you COVID brain fog is no joke.


I always have liked your designs, Bill. Clean and simple; ZZRCC is just an elegant design, and this Z80all looks similarly clean.

Now, LS-DOS wasn't designed to be quite as simple or clean to port as CP/M was; with CP/M you have a clean transition point for the hardware-dependent BIOS to the hardware-independent BDOS and CCP, but this is not true for LS-DOS. I know of the following ports:
  1. danielbooneamerica's eZ80F91 port, which is in need of hardware to continue;
  2. The TRS-80 Model 4 native version;
  3. The TRS-80 Model II/12 port, originally done by Kim Watt and worked on by Roy Soltoff when he updated it to 6.3.1 (there was never a 6.3.0 fullly-baked for the II/12 as far as I know);
  4. The MAX-80 port, called MAXDOS; binary disks of this have been recovered but not the sources;
  5. Z80-MBC2. I have seen screenshots and photos of this port, but haven't seen any code, and as far as I know it's still a work in progress.

I wish you the best of luck, and I'll try to answer any questions you might have about LS-DOS and the source tree's organization. You'll have no difficulty, I believe.
 
Wow, thank you for the extensive reference to LS-DOS6! I will, no doubt, have many questions. Since the target hardware is built around a CPLD, I do have the option of changing hardware to fit the existing software. I'm actually not familiar with the inner working of TRS model 4, so I'll need to read up on its memory map, expansion bus, and how it does memory bank switching. So there are good bits of homework to do.

I've also discovered a batch of Altera EPM7192S which is 50% larger than the EPM7128S that is in Z80all, so I should have enough logic fabric to handle the unexpected.

Z80 at 25MHz is quite responsive. The more modern CF disk should also simplify & speedup the mass storage problem. Looking forward to tackle a new OS.
Bill
 
Wow, thank you for the extensive reference to LS-DOS6! I will, no doubt, have many questions.

Ask away!

Since the target hardware is built around a CPLD, I do have the option of changing hardware to fit the existing software. I'm actually not familiar with the inner working of TRS model 4, so I'll need to read up on its memory map, expansion bus, and how it does memory bank switching. So there are good bits of homework to do.

So, find a copy of the TRS-80 Model 4 Technical Reference manual, AND a copy of the TRS-80 Model 4/4P Technical Reference manual on the cpmarchives.classiccmp.org site; they do have slightly different content. Also grab the "Programmer's Guide to TRSDOS/LS-DOS 6" from www.tim-mann.org as well. The Model 4 is a pretty simple machine. The Model 4P Service Manual is available on archive.org, as well, with full schematics and theory of operation.

I look forward to seeing your results.
 
Just an update on this thread since it was started March 2020. I had developed a new BIOS/LOWCORE that allows sys1-13 to execute pretty much unchanged. Since inception of TRSDOS 6 it was intended to be hardware independent. You can really see where they were headed with this. When your way deep deep down in bits figuring out what was done here you can see where they were headed. Tandy would have one dos that worked across models 1/2/3/4/?/12 etc with little changes except BIOS. Maybe a office and home version like we have today for windows.

eZ80 is considered a system on a chip [SOC]. It has i/o and lots features all on one chip. Add a few support circuits and bake on low temp and you have a complete simple computer. I have seen eZ80 projects that were size of sugar packet.

All that said eZ80 is not going to make a TRSDOS compatible due to i/o conflicts. This problem will keep it from running a binary copy of TRSDOS. That being said almost any new computer trying to execute TRSDOS will have or need some changes. Even with xlr8 you could run into problems sometimes with i/o happening too fast. Some motherboards were more sensitive than others and even at exactly same clock speed eZ80 or most any other CPU than Z80 is executing things faster.

Z180 version by Zilog not Rabbit seems to be most binary compatible TRS80 Z80 CPU. It is tried and proven by xlr8 for many years with few problems but again, you can have to make adjustments even for this chip slowed down.

Where I started with all this is I needed a eZ80 with bank memory like Model IV has. I used to sit on hackday and count projects that said they were going to have bank memory but were never completed and just go unmaintained or updated. I had no interest in being backward compatible with models 3 and 1.

TRSDOS 6 plainly tells you up front never talk to hardware directly but rather through SVC calls that directed i/o to BIOS routines. This BIOS is main place needing rewrote for a new CPU.

Most all the compilers and things like BASIC under TRSDOS 6 communicated with hardware via SVC and they kept it pretty simple thus things like this should work on a newer DOS version that tries to take advantage of newer chip features. You have to have more than one version of software to make use of different CPUs. No one piece of software is going to work with all CPUs but with conditional assembly and compiles you can keep source versions to a minimum.

All this said you need versions for Z80, Z180 and eZ80 at a minimum. eZ80 makes web connection easier or better to say connection between machines via networking easier. Actually connecting to web is a bigger project.

Last March when I polled this community there was zero interest in my interest. Again my interest is pickup up where Model 4/LSDOS 6 left off and go forward. Software that is well behaved and will port over so be it but otherwise it is left behind.

As I recall it was 100% who said it it was not backward compatible with models 1 & 3 they were not interested.

I ended up making at least 3 versions, cassette based (FLASH held cassette file), DOS 16 bit (meaning compatible with TRSDOS as close as possible) and DOS 24 bit. 24 bit means it uses newer eZ80 features and what will come over and run from older versions so be it.

I did lots of research and even consulted with several engineers which ended up being in multiple countries. From my retired background of simulation I think I have design for hardware now that will simulate TRS80 platform with near 100% fidelity.

I am sorry but due to some medical issues it is hard for me to type all this and now you are in luck I will have to take a break from posting. I am sorry if I have bored you all with my ramblings.

But I will give all you designers a piece of advice, I am sure you already know it but just a reminder. No program or programmer in world sees anything but I/O and memory. If simulation is correct I will make lunar lander computer think its really in a lunar lander on the moon. I think I can make a program think its in a TRS80.

Daniel Boone America

ps. Oh crap Pete, sorry. Above when I said add circuits and bake with eZ80 it was a joke and should have had a :) after it. Please do not take me serious and bake any hardware....or software for that matter.
 
and one other small note. I have seen lots of posts giving credit for work on TRS/LSDOS OS source code etc. To my knowledge Douglass Beattie was first person to have a version of TRSDOS source.

He has been mentioned in several websites and back in day was given credit for what they called a 'yeoman effort' of typing in source of DOS. Douglass resides in Salt Lake and I once flew to visit with him about hardware. We spent weekend brainstorming on what and what is not needed to make a working model.

Douglass is a very sharp engineer and gracious host and I enjoyed our working weekend. I have heard from him over last year and due to some personal issues he has not been able to apply the time to this he would like to. I hope Douglass rejoins us soon and get well Douglass.

He did make a big contribution and to my knowledge he was first one outside RS/Misosys/Logical system that had a copy of source simply because he sat down and typed it all in.

D
 
I think I've read enough of "The Source" to formulate a strategy from bring up TRSDOS (maybe I should refer it as LS-DOS instead?) on new hardware platform. The goal is not full compatibility on the first iteration, but to learn about the structure of the software and most importantly, the sys1-13 command overlays.

I'll start a new topic so not to hi-jack this one.
Bill
 
and one other small note. I have seen lots of posts giving credit for work on TRS/LSDOS OS source code etc. To my knowledge Douglass Beattie was first person to have a version of TRSDOS source. ...

Yes, thank you for the reminder. He hand-typed volume I of 'The Source' as published; Tim Mann made the statement you quoted about it being a yeoman effort. He also has ported FORTH to several of these chips, including both eZ80 and Z380/382. His site is in my short list of references on these chips; I bookmarked his site back in 2014 or so as I recall when I started getting back into TRS-80's as a hobby again.

Douglass is a very sharp engineer and gracious host and I enjoyed our working weekend. I have heard from him over last year and due to some personal issues he has not been able to apply the time to this he would like to. I hope Douglass rejoins us soon and get well Douglass.

Yes, indeed. Personal issues waylay us all from time to time.

He did make a big contribution and to my knowledge he was first one outside RS/Misosys/Logical system that had a copy of source simply because he sat down and typed it all in.

I meant no slight to him or to you by neglecting to add him to my list; my list was intended to record the copies of the sources that are complete; to the best of my knowledge he made it through Volume I of the three volumes of 'The Source,' but I always reserve the right to be wrong.

EDIT: Note that there are private copies that others have, either disassemblies or type-ins; I know Aaron Brockbank has both LS-DOS source reconstructions and DOSPLUS II source reconstructions as well. No slight meant to Aaron, either. Blasted brain fog!

Good luck with your projects.



I think I've read enough of "The Source" to formulate a strategy from bring up TRSDOS (maybe I should refer it as LS-DOS instead?) on new hardware platform. The goal is not full compatibility on the first iteration, but to learn about the structure of the software and most importantly, the sys1-13 command overlays.


Sounds like a good start, Bill!
 
Last edited:
Back
Top