Page 1 of 1

TRS-80 Core Has Moved

Posted: Mon Nov 11, 2024 3:06 pm
by theflynn49

Hello...

I just spent a few weeks to make some fixes to the disk controller and the keyboard of this core, so LDOS is now loading and running fine.
Other DOSes should be improved as well. It will be published soon.

Feedback welcome, if someone is interested, as where to go from this point may be a cool subject of discussion ...

Rgds,
jF


Re: TRS-80 Core Has Moved

Posted: Mon Nov 11, 2024 3:26 pm
by rcade

Thanks for your work!

It would be great if it could be extended to emulate the Model III and/or 4 also. The III might be a good bit easier than the 4.


Re: TRS-80 Core Has Moved

Posted: Tue Nov 12, 2024 3:25 pm
by akeley

It's wonderful news that there's an ongoing development for this core. TRS-80 I is one of my favourite computing underdogs. Thank you!


Re: TRS-80 Core Has Moved

Posted: Wed Nov 13, 2024 6:04 pm
by theflynn49

Many thanks for all the kind words and the thanks. It makes me hopeful that a community may arise to keep this core alive and that's making me happy.
I know dev time is hard to find these days, but end user tests and experiments are essential to core progress.

@rcade : going to Model III is a good goal; there are not many differences with the Model I, the most difficult being the 1791 in place of the 1771, with the ability to support DD disks. Of course that mean supporting another disk format, JV1 lacking DD ability. JV3 would do and seems doable to me, by contrast, DMK looks like hell (debate welcome).

On shorter terms, I would like to :

  • Add support for 4 drives ; Having the support for 240 tracks permits more things, but the space disk is still very limited. Adding 2 drives is easy to do and will add some comfort. (I had to put the C Misosys compiler all on one 202-track disk to be able to C-recompile the samples, as a example of 'discomfort')

  • Modify the "load CMD" command. I love this command. It is a genius idea. But it can't work. If I am not wrong about how it's done, it forces the Z80 into an address after loading the CMD file in memory without any caution, and this just will work only by luck (you know, init SP, DI, etc...). Beside this, sometimes a CMD needs more than one file to work properly.
    As the software library for the trs80 consist mainly of a gazillon of /CMD and /BAS files, I wish we would have a way to load directly a /CMD file, but a working one, and the same with a /BAS file. This way we could scan the software library as it is to run stuff without creating a DSK off line.
    What I propose here is to replace the "load CMD" command by a "Upload file to disk" command, (along with a small Z80 app to run on the core).
    This would work like this : Load an empty or work disk, launch the Z80 app (CMD"MISTER"), upload files, and voilà, you can run the app from the work disk with all the needed files on it.
    An alternative would be to try to fix the CMD command and add a" load BAS file" directly to memory (at the correct location depending of the running basic). But I don't know if it's feasible.

  • not touching load .CAS It works fine. Both binary and basic files. It's lovely to feel the pain of loading cassettes again after 45 years :D

I prefer if everyone agree on theses topics before I butcher this core more :) so tell me.

I hope this core keeps some activity.

My best
jF


Re: TRS-80 Core Has Moved

Posted: Thu Nov 14, 2024 11:45 am
by kathleen

Thank you for your hard work @theflynn49,
The TRS-80 computers are ones of my favorite computers, those computers have something special than others were not having back in the days.
In my opinion having the whole TRS-80 range, Model I, Model II, Model III & model IV worst it. Especially because each of them have dedicated software. I'm not sure about the retro compatibility between the models however, can a model I software be run on a Model IV ? . But anyway in a preservation point of view I'll dream to have all those 3 additional models to the already existing Model I (that I like a lot :-))
There is also the Model 16 based on a MC68000 if I'm not wrong.


Re: TRS-80 Core Has Moved

Posted: Thu Nov 14, 2024 2:44 pm
by akeley
theflynn49 wrote: Wed Nov 13, 2024 6:04 pm
  • Modify the "load CMD" command. I love this command. It is a genius idea. But it can't work. If I am not wrong about how it's done, it forces the Z80 into an address after loading the CMD file in memory without any caution, and this just will work only by luck (you know, init SP, DI, etc...). Beside this, sometimes a CMD needs more than one file to work properly.
    As the software library for the trs80 consist mainly of a gazillon of /CMD and /BAS files, I wish we would have a way to load directly a /CMD file, but a working one, and the same with a /BAS file. This way we could scan the software library as it is to run stuff without creating a DSK off line.
    What I propose here is to replace the "load CMD" command by a "Upload file to disk" command, (along with a small Z80 app to run on the core).
    This would work like this : Load an empty or work disk, launch the Z80 app (CMD"MISTER"), upload files, and voilà, you can run the app from the work disk with all the needed files on it.
    An alternative would be to try to fix the CMD command and add a" load BAS file" directly to memory (at the correct location depending of the running basic). But I don't know if it's feasible.

Wow. If possible, this would be truly genius ;)

Like I said, I love Trash 80, and some time ago started making a game collection. I got sidetracked by my other projects and only got about 1/3rd into letter A, but this is mostly due to a huge amount of work needed to transfer assorted BAS/CMD files to disk. The process is relatively simple, but quite time consuming, and so it's easy to get bogged down.

If your automation method worked it'd be a godsend, then all that's needed would be just sorting out the games from software (TOSEC has them all mixed together).

Yes, some CMD files will work straight, some need the OS mounted for the extra files. So the command sometimes works and sometimes it doesn't. BAS files always need BASIC of course.

@Kathleen: Model II is a bit of a confusing outlier, because it has different architecture than I/III/IV, which are backward compatible. The majority of soft is for model I, Model II has the least (especially games). Although both II and IV could run CP/M natively.


Re: TRS-80 Core Has Moved

Posted: Thu Nov 14, 2024 3:32 pm
by ericgus09

Like many the TRS80 I/III was the first real world contact I had with any kind of computer, so it holds a very very special place for me in my heart. And thank you for anything you can do to make this core better @theflynn49 .. I love the ideas and while my original experiences with the TRS80s was generally tape based (and the pain involved) any enhancements or modernizations features to make using it more comfortable now a days is more then welcome ..

One feature id love to have enabled in this core (and its not a high priority in any way shape or form) is to enable RS232 UART so we can use the misters softmodem hayes emulated modem to call out to internet BBSs from this core .. (like we can do on many other cores, C64, Amiga, ao486, CoCo, MacPlus, AppleII etc..)


Re: TRS-80 Core Has Moved

Posted: Fri Nov 15, 2024 1:23 pm
by theflynn49

Hello, and thank you all for the good vibes.

@Kathleen : as Akeley suggested, the Model II is too different from the others, and is more office oriented since it has nearly no graphics except to draw tables. As Mister is more game-oriented, ... Eventually it will be done, but meanwhile I suggest you try an emulator like trs80gp, which works everywhere, emulates all models and probably will give you that retro feeling you miss :)

@Akeley : okay, let's do it ! Hold my beer ... :D

@ericgus09 : I am not opposed to do a rs232 interface, especially because it think most of it is already in there. Do you mind gathering all the available docs for this (interface doc, tech spec, schematics if possible, and a test application, whatever you find ...) ?


Re: TRS-80 Core Has Moved

Posted: Fri Nov 15, 2024 5:35 pm
by kathleen

@theflynn49,
Agree with you and also whith what @Akelay says. But for me the Mister is not only game-oriented, I often use it for let's say office apps. It is even this aspect that I like much.
I know the amazing trs80gp and I'm using it for other models than the Model I, but to be honest, since I own the Mister I prefer to use it rather than the emulators on my PC. Not because one is better/behaving better than the other, not at all, but I feel more close to the original hardware with the Mister. My opinion of course :-)


Re: TRS-80 Core Has Moved

Posted: Sat Nov 16, 2024 6:58 am
by ericgus09

Ill see what I can find but im not a core developer and dont know much bout the internals of the TRS80s series.. I want to say they sometimes refer to it as MUNT? it was originally part of the MIDILINK layer that runs on the linux side of the MISTER .. and while it was originally created to, handle midi (by name "midilink") they put in a 3rd option to do hayes modem emulation, I know a large number of other cores have this enabled so it should be fairly well documented to a point (eg even the COCO core has it) .. so im not sure if looking at the github for the Coco core might be of any help .. but im pretty sure (at least on the mister side ) all of the UART stuff is pretty well documented and a standard part of the main mister core functionality now.

EDIT: (I found this which I think is the original repo .. I dont know if this is the current code or its functionality has now been incorporated into the main mister code) but you can take a peek here

The bit im talking bout is mostly at the end of the readme where it says "MidiLink : TCP The TCP option works like a WiFi232 adapter supporting a small subset of the Hayes "AT" command set and some additionl stuff"

https://github.com/MiSTer-devel/MidiLink_MiSTer

the Coco core is here, https://github.com/MiSTer-devel/CoCo3_MiSTer

perhaps the UART_6551 in the CoCo core might be of assistance to you getting it added to the TRS80 core..
https://github.com/MiSTer-devel/CoCo3_M ... /UART_6551
and
https://github.com/MiSTer-devel/CoCo3_M ... /mt32pi.sv

https://github.com/search?q=repo%3AMiST ... &type=code


Re: TRS-80 Core Has Moved

Posted: Sat Nov 16, 2024 9:51 am
by theflynn49

@ericgus09 thank you for the links, it saves some time. Maybe you know what could be qualified as "the best" TRS80-Model I application that used a rs232 add-on ? And what that add-on was ? that's what I am looking for. We don't want to invent some rs232; we want to emulate some specific rs232 add-on that was used by some commonly used application in the past ...

ps : I think I found this https://prof-80.fr/images/TRS_80M1/Cart ... )(pdf).pdf
and also this : https://www.trs-80.com/wordpress/ports-and-i-o-devices/


Re: TRS-80 Core Has Moved

Posted: Sat Nov 16, 2024 3:51 pm
by dshadoff

First, the TRS-80 Model I, Model 3, and Model 4 were largely - but not completely - compatible.
I don't recall all the differences, but slight variations in clock speed, larger differences in boot ROM, and some port addresses (if I recall correctly, one of the larger differences was disk subsystems).
It should be possible to make one core accommodate all of these, but the disk subsystem(s) would probably be the most difficult aspect.
(Model II was a different beast entirely.)

theflynn49 wrote: Sat Nov 16, 2024 9:51 am

Maybe you know what could be qualified as "the best" TRS80-Model I application that used a rs232 add-on ? And what that add-on was ? that's what I am looking for. We don't want to invent some rs232; we want to emulate some specific rs232 add-on that was used by some commonly used application in the past ...

ps : I think I found this https://prof-80.fr/images/TRS_80M1/Cart ... )(pdf).pdf
and also this : https://www.trs-80.com/wordpress/ports-and-i-o-devices/

Yes, you have found the official RS-232-C interface document; this should be considered the quintessential version for Model I. It was an add-on to the Expansion Interface. While I recall there were RS-232 interfaces which didn't require the Expansion Interface (I didn't have the EI), they were compatible.

I seem to recall at some point that some people were "hacking" their units to use a 16450 or 16550 UART for better baud rates and/or buffering, but the electrical interface (including port/memory addressing) would have remained the same.

Back at that time, I recall only two main uses for RS-232:

  • modem/terminal software (I don't recall a specific package being a leader, but if Radio Shack listed one, that would have been the defacto standard)
  • driving a serial printer

At this point in time, the Hayes "AT" command set was not yet established as any sort of standard, so any modem setup was mostly done manually - DIP switches were used (on both sides), not software commands.

It was truly the wild west.


Re: TRS-80 Core Has Moved

Posted: Sat Nov 16, 2024 4:50 pm
by theflynn49

@dshadoff : thank you for these informations, the app was "TERM" I think I found it too in ver 1.5. The system80 rom from Dick Smith had an imbedded term program too, but it has been removed from the ROM provided with the core.

I see you are one of the main contributors a few years ago, I hope you find my changes compatible with your original design. Don't hesitate to complain if otherwise ;)


Re: TRS-80 Core Has Moved

Posted: Sun Nov 17, 2024 5:32 am
by ericgus09

Yes I think TERM was it but im by no means the definitive expert .. hopefully others chime in.. but thank you for even considering this idea .. I also wanted to mention you could probably look at some of the other cores to see how they interface the Mister modem emulation/midi/serial-rs232 linux side to the fpga core .. of course different cores will likely be different how the handle serial as per the machines they are recreating but it might give some insight ..


Re: TRS-80 Core Has Moved

Posted: Thu Nov 21, 2024 12:21 am
by theflynn49

@ericgus09 : I just committed a release with the RS232 interface. You can wait for Sorgelig to merge it in a few days, or get it there =>
TRS-80_20241122.rbf

Hope you like it. Don't go too fast, even at x12 speed, the TRS80 is not fast enough to go over 4800 bauds or something.
jF

(Edit: I just made another new release, so I edited the link)


Re: TRS-80 Core Has Moved

Posted: Fri Nov 22, 2024 4:21 am
by ericgus09

OH NICE THANK YOU! ..

Ill try to give this a test over the weekend .. weekdays are busy with new job.. I really appreciate you taking the time to add this.. im sure others will appreciate it..


Re: TRS-80 Core Has Moved

Posted: Fri Nov 22, 2024 10:13 am
by theflynn49

If someone finds a terminal program that displays lowercases, please tell me. I think I tried every one of them, they send lower case characters, but none seems to be able to display them. For my tests I mostly used "Terminal Program (1979)(William D Schroeder)[CMD]" (a huge 512 bytes CMD file named termws2.cmd)

FYI the "X" field in the debug line (the yellow line on top you can see if you enable it along with overscan) is the debug for rs232 like this :

  • bit 11 = RX buffer ready (1 = char ready)
  • bit 10 = TX buffer ready (1 = empty)
  • bit 9 = Overrun flag
  • bit 8 = Frame error flag
  • bit 7 = CTS
  • bit 6 = DSR
  • bit 5 = CD (simulated when MiSTer is not in "none" UART mode)
  • bit 5 = RxD
  • bit 3 = 0
  • bits 2..0 = 3 emulated switches of the speed select (from the speed given by MiSTer)

You cannot set the parameters; Baud rate, word length(8), Nb stop bits(1), parity(none) are all forced by MiSTer.

As a sidenote, it seems that most of the time capitals are displayed as in the range $00..$1F and not $40..$5F ; that's bizarre but hey, that's the trash-80 ... If someone knows why it is so, I'd like to hear it ...

jF

Edit : I just answer myself : LDOS/LCOMM works with lower cases ! You have to setup the comm driver with : "SET *CL to RS232R/DVR (RTS=Y,DTR=Y)" to make it working though.


Re: TRS-80 Core Has Moved

Posted: Fri Nov 22, 2024 12:12 pm
by rhester72

Is it possible you have the UART in PETSCII vs. normal ASCII mode?


Re: TRS-80 Core Has Moved

Posted: Fri Nov 22, 2024 5:34 pm
by theflynn49

@rhester : The hardware doesn't care how the characters are encoded. It's up to the Comm software to deal with that.
LDOS/LCOMM has a translation character feature, but its usable for a few characters only.


Re: TRS-80 Core Has Moved

Posted: Sat Nov 23, 2024 1:57 am
by rhester72
theflynn49 wrote: Fri Nov 22, 2024 5:34 pm

@rhester : The hardware doesn't care how the characters are encoded. It's up to the Comm software to deal with that.
LDOS/LCOMM has a translation character feature, but its usable for a few characters only.

I don't think that's quite true.

A setting like "TCP_TERM_TRANS = PETSKII" in MidiLink.INI is "twisting the bits" behind the hardware's back, and if it's set and shouldn't be, the terminal has no means of dealing with that (short of just displaying what it gets). The net result would be a complete reversal of upper and lower case, though...not 100% sure if that's the artifact you're seeing.


Re: TRS-80 Core Has Moved

Posted: Sat Nov 23, 2024 10:34 am
by theflynn49
rhester72 wrote: Sat Nov 23, 2024 1:57 am

A setting like "TCP_TERM_TRANS = PETSKII" in MidiLink.INI

I think I see what you mean. and in my mind this was specifically made for the C64. Thanks to bring the point to my attention, it may fix future compatibility problems easily.

The TRS-80 has different problems, it has difficulties to display lower cases and it is too slow to handle then end-of-line because of the processing time to scroll the screen. Thus above 300 and even 110 bauds you get problems with LDOS/LCOMM which is the only comm terminal I found that displays lower cases. But the coding is ASCII, no need to scramble that and the flag is not set for that matter. The TRS80 not only has no lower case in its character ROM (but we have the "lower case kit", so this is fixed), but it displays the characters from 0x41 to 0x6F in the range 0x01 to 0x1F, which is upper case anyway. So to display lower case, we need to bypass the original ROM keyin routine to generate lower case, and bypass the display ROM routine, to insert the real chars 0x61-0x7F in the video RAM directly, and only a few programs can do that.

So, I am implementing a 32-bytes fifo buffer to fix the speed problem, and I hope to be able to support 2400 bauds with LCOMM with that.
Otherwise, the tests I have performed with another fast term program on a BBS has proven reliable up to 2400 bauds, (but all in capitals).


Re: TRS-80 Core Has Moved

Posted: Sat Nov 23, 2024 2:16 pm
by theflynn49

Hello ...
FIY : I just published a new core with the 32-byte fifo cache and a few more fixes. it's here : TRS-80_20241123.rbf

It works well with TRSDOS and a term program like "termws2" from W.D.Schroeder (1979)
It has a few quirks with LDOS/LCOMM, but then it has lower case ! yes :D

All CPU speed work but 2400 bauds requires x3 or x12 CPU to work. 4800 bauds seems too fast in any case, but I may be wrong.

I tested both the mister "Console" and "Modem" connections. the rest should work but MIDI wasn't invented when the TRS80 was making the buzz
Warning: the Mister side apps for communication have their own quirks. Always reset the link after changing the baud rate. Using the UART Mister setting "none" before your next choice helps often.

Happy testing ...

jF