Giter VIP home page Giter VIP logo

trs-80_mister's Introduction

TRS-80 for MiSTer Platform

Model I Support

This is a port of HT1080Z MiST core by Jozsef Laszlo to the MiSTer

NOTE: This core was renamed from ht1080z to TRS-80. If you are using the old core, be sure to rename the ht1080z directory to trs-80 on the MiSTer SD Card

To learn how to use the TRS-80, this is a quick tutorial: https://www.classic-computers.org.nz/system-80/driving_instructions.htm

The TRS-80 with Disk Drives attached will boot to a screen of '@' symbols and will then only continue booting once you place a disk in the drive. To bypass this and boot directly to BASIC to load a cassette game, press Escape immediately after selecting Reset in the OSD menu.

To load a cassette game:

  return
  system
  <Then go to the OSD and load a cassette>
  [type the first letter of the file you want to load (e or g for the disk images provided)]
  / (to start once loaded)

To load a CMD file:

Just select it in the OSD. Some CMD files won't work if they access disk rom routines and there is no disk in the drive. Sometimes a clean reboot is necessary before loading a CMD.

To load files from DSK images:

There are three main TRS-80 image formats, which are JV1, JV3 and DMK and they all usually share the same DSK extension. This MiSTer Core only supports the JV1 image format with upto 250 tracks, all tracks must currently hold 10 x 256 byte sectors. To check what format a disk is in, and if it is compatible with the core, use the TRSTOOLS utility from Matthew Reed, available from: http://www.trs-80emulators.com/trstools/

The Disk emulation supports reading and writing to JV1 formatted disks, but disks cannot be formatted in the core because there is no Write Track support for JV1 images. There are many different DOS versions for the TRS-80 with popular ones including TRSDOS, NEWDOS/80 and MULTIDOS. For beginners it is recommended you use TRSDOS which is the original DOS produced by Radio Shack. Instructions for using TRSDOS can be found in the following Wikipedia article: https://en.wikipedia.org/wiki/TRSDOS

Features:

  • TRS-80 Model I with 48KB installed
  • Expansion interface with dual disk drives
  • Real Time Clock (RTC)
  • White, Green and Amber Phosphor screen emulation
  • Sound output is supported (however cassette saving sound is suppressed)
  • Cassette loading is many times faster than the original 500 baud

Notes:

  • The included BOOT.ROM has been modified to take advantage of a special interface for loading cassettes; original BASIC ROMs are also supported
  • Simulates Percom Doubler and TRS-80DD, but the upcoming JV3 decoding will be required to use DD disk images
  • Even though sector write operations are supported, formatting of disks is not.

Technical:

Debug status line

  • The Debug Status line will only be visible in Partial or Full overscan modes
    • For monitoring Floppy Disk Controller (FDC)
    • Usess the following format: Ddddd,Ccc,Ttt,Sss,dnn,sSS * where:
      • dddd - Drive select latch (1-4). Only 2 drives are currently supported
      • cc - FDC Command Register
      • tt - FDC Track Register
      • ss - FDC Sector Register
      • nn - FDC Data Register
      • SS - FDC Status Register
      • * - RTC Second Timer

Special ports (i.e. Z-80 "OUT"/"IN" commands) have been added as follows:

  • VIDEO:

    • OUT 0, n (where n=(0-7)) -> change foreground color
    • OUT 1, n (where n=(0-7)) -> change bacgronund color
    • OUT 2, n (where n=(0-7)) -> change overscan color
  • Memory-mapped cassette:

    • OUT 6, n (where n=(0-255)) -> set address bits 23-16 of virtual memory pointer
    • OUT 5, n (where n=(0-255)) -> set address bits 15- 8 of virtual memory pointer
    • OUT 4, n (where n=(0-255)) -> set address bits 7- 0 of virtual memory pointer
    • A = INP(4) -> read virtual memory at current virtual memory pointer and increment pointer
    • Note that cassette image is loaded at 0x010000, and no memory exists beyond 0x01ffff
  • Holmes Sprinter Interface

    • OUT 254, n - Even number = Override Turbo. Odd number = Enabe Turbo

Special memory mapped ports have been added as follows:

  • TRS-80 DD Interface - Memory mapped interface
    • 0x37ec = 0x80 - Enable Double Density Mode
    • 0x37ec = 0xa0 - Disable Double Density Mode

trs-80_mister's People

Contributors

alanswx avatar asicguy avatar dshadoff avatar hackshed avatar sorgelig avatar steddyman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

trs-80_mister's Issues

Keyboard seems sluggish

Subjectively, the keyboard seems to react slowly (ie. ~100ms per keystroke, which is slower than it should be).

False key presses in some games (and stuck keys)

Hi
I've been adding some features to this core myself in my own branch including:

  1. More accurate phosphor colours
  2. Simulation of CPU to Video ram contention (black lines)
    I could do with talking to someone about how to handle working together on features since the first feature is incompatible with the latest merge. I was also looking at adding Disk support.

During this work I've been testing various games including games from Big Five and some do not work correctly. For example when Attack Force is running on the core, when you are in the main game loop (not menu) it always thinks that the down and space keys are pressed. Also Meteor mission thinks the right key is permanently pressed. Both these games were off a DSK collection and I had converted the CMD to a CAS file using CMD2CAS.EXE. This bug is something that happened betweened the last official release on the 1st of April, and the current Master branch (as of 4 days ago). The release version from the 1st of April did not have this issue, but there was a major rewrite of keyboard routine after that according to the commit history.

On debugging this issue I wrote the following simple basic program (for the TRS-80):
10 PRINT PEEK(14591)
20 GOTO 10

This code reads the address 0x38FF that will read and combine all keyboard address rows and the results are all OR'd together. Some games use this mechanism to check for a return of 0 indicating no keys are pressed before bothering to scan the address rows individually. Also, they can read multiple rows using this mechanism if they need keys from two rows, but don't care if other keys on the keyboard trigger the action (they are alternative key options for the user).

If you run the above program it should print 0 when no keys are pressed but sometimes it does not. You can force this condition by running the program, then pressing the Left Shift key and holding it down, then pressing and holding down the 8 key on the top row, then releasing the Left Shit key, then finally releasing the 8 key. When you do this, the above code will still report the * key is still held down by returning 4 (bit 2 of 0x3820 for the '*').

I was planning to try and work out what is causing this issue and fixing it in my commit, but after seeing the latest merge, I'm now concerned this core is under active development and I should be co-ordinating my work with whoever is the main contributor.

Need regular NTSC output

Core was written to function either as PAL or as VGA (at double NTSC frequencies, double-scanning lines).

Should be modified for proper NTSC-like output.

Last two releases (20200618 and 20220309) just leave screen filled with @ symbols, 20200522 works.

The last two releases of this core seem to fail to load the boot.rom file (which I have in GAMES/TRS-80/BOOT.ROM, However TRS-80_20200522.rbf starts and runs ok.. 20200618 and 20220309 fail with the screen filled with "@" .. this is with the most up to date MISTER version v221014 (as of Nov 1, 2022) .. Am I missing an additional ROM file or does the BOOT.ROM file need to be in a new location for the core to find it?

TRS-80_20200522.rbf
TRS-80_20200618.rbf
TRS-80_20220309.rbf

/media/fat/Games/TRS-80# ls -l
total 640
-rwxr-xr-x 1 root root 14336 Nov 3 00:26 BOOT.ROM
-rwxr-xr-x 1 root root 4117 Feb 15 2019 env.cas
-rwxr-xr-x 1 root root 9924 Feb 15 2019 galaxy.cas
-rwxr-xr-x 1 root root 6916 Apr 11 2001 haunt.cas
-rwxr-xr-x 1 root root 13056 Nov 26 2021 spores.cas
/media/fat/Games/TRS-80#

First keystroke at boot is ignored

At the "READY ?" prompt, the enter key needs to be pressed twice, as the first entry is suppressed. Not sure if this is a framework versioning issue or a matter of PS2 keyboard initialization.

In-core menu occasionally reacts strangely

When scrolling through items with the up/down arrow keys on the keyboard, the in-core menu sometimes flips to the main-mister menu (i.e. as though right arrow was pressed).

Workaround: longer wait time between keystrokes reduces likelihood that this occurs.

Could be a framework versioning issue, or it could be related to interaction with the PS2 keyboard driver.

Disk images start to get errors randomly

After mounting disks and running a few programs successfully, NEWDOS/80 booted OK but suddenly was not able to read the directory from either drive 0 or 1. Mounting a different disk in drive 1 did not solve the problem.

A cold boot of MiSTer, or loading of a new core then back to the TRS-80 core DID fix the issue.

DMK support please?

I appreciate the addition of disk support, but nearly every emulator has moved to DMK format, to such a degree it's very difficult to even find software (or working converters!) in JV1 format any longer.

Even the very basic (Microsoft) Colossal Cave adventure needs DMK because of on-disk copy protection...any hope of this format being supported?

Inconsistent bootup

About 30-50% of the time, the screen will fill with "@" signs and the system won't start (but the remainder of attempts, it will start).

I believe that the core is starting to process instructions before the boot ROM is completely loaded.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.