5

I'm using the RC2014 (Z80), running CP/M. The "24886009" ROM chip (photo below) comes with 32k BASIC, 56k BASIC, SCM and CP/M for SIO/2 serial.

When you run CP/M from the RC2014 ROM, you need to interact with a series of prompts (screenshot below), each requiring input to actually start CP/M:

  1. Space
  2. X
  3. Y

Is there a way to automatically boot CP/M on the RC2014 rather than having to enter the 3 keystrokes?

Also, is there a way to automatically run a CP/M program at boot? (Similar to autoexec.bat on DOS)

CP/M via Tera Term

RC2014 ROM chip

8
  • 4
    This seems to be a question about a modern day computer and modern day software,both active maintained as of 2022 It might be more appropriate to ask at the creator/maintainer of that computer and/or ROM. Ofc, peeking at the sources might as well help
    – Raffzahn
    Jul 25, 2022 at 15:34
  • 3
    Ah, so this problem is not specific to CP/M, and instead is specific to the data or BIOS on the RC2014 ROM chip? Perhaps creating my own ROM chip is the answer? Jul 25, 2022 at 15:46
  • 3
    Yes, from looking at the page you linked as well as the mentioned patches, it's clear that these ar RC2014 specific functions of that ROM. CP/M itself is of course able to boot straight from reset. Point is that for that computer they wanted to give the user options to go ahead. For yourself, go ahead and modify the ROM-Loader (it is just a loader, as CP/M seems to come form CF) the way you need it.
    – Raffzahn
    Jul 25, 2022 at 15:50
  • 1
    Three synchronized dipping birds? Jul 25, 2022 at 19:43
  • 2
    I'm going to vote to reopen this as on-topic, because it's about the RC2014. Please see (and vote on) this answer on meta. I'll also cite questions 22285 and 24834 as precedents (and there are still other well received questions about the RC2014 on this site). Jul 26, 2022 at 10:11

1 Answer 1

13

Use the SCM Auto bit (edit the ROM)

TL;DR: Use my modified ROM to start CP/M automatically on RC2014.

For these instructions, you'll need an EEPROM chip (e.g. W27C512-70) and a ROM reprogrammer device (e.g. XGecu T48).

  1. Download 24886009.BIN from the RC2014 GitHub repo.
  2. Open the .BIN in your favorite hex editor (e.g. HxD, Xgpro, etc).
  3. Locate memory location 0x7FBA (row 7FB0, column 0A).
  4. Change the value from 0x41 to 0xC1 (thanks Steve).
    • 01000001 (0x41) becomes 11000001 (0xC1).
    • This sets the Auto flag (bit 7) for CPM to on.
    • For more info, see SCM guide doc page 36.
  5. Run ROM reprogrammer software (e.g. Xgpro).
    • Hint: You can also use Xgpro to edit the ROM image.
  6. Insert an EEPROM into your reprogrammer (ensure correct position).
  7. In Xgpro, press the "PROG." button (center of toolbar at top).
  8. Insert the ROM into the RC2014 pageable ROM module.
  9. Ensure that only A14 and A15 are set (do not set A13).
  10. The RC2014 should now boot straight to CPM (see note below).

Note:

  • You may see a "Compact flash not present" error, even with a working CP/M CF card present. This happens because sometimes the CR card is too slow to init, and when you press the CPU reset button (i.e. the reset button on the Z80 CPU card) this almost always occurs. If you press the reset button on the RC2014 Pro backplane, CP/M will normally boot automatically, and you won't see the CF card error (but maybe 1 in 5 times the CF card will be too slow to init and you’ll see the error).
  • Most retro computing enthusiasts probably already know this, but in case you're like me: EEPROM means 'electronically erasable' and is not quite the same as EPROM or UVPROM.

Original research

Edit: As advised, I asked a question on the RC2014-Z80 Google Group and got the response from Steve Cousins (who wrote SCM, which works on RC2014, and he also makes kits for the RC2014):

Hi Nick,

That's an interesting question.

SCM includes a very simple ROM filing system which allows extra features to be added to the monitor. The CPM command is implemented this way. Each extra feature has a descriptor at the end of the ROM bank it is in. Here is an example from a 32k SCM ROM:

7FA0:  55 AA 43 50 4D 20 20 20  20 20 03 00 74 4D 44 00  U.CPM     ..tMD.
7FB0:  55 AA 43 50 4D 20 20 20  20 20 41 80 55 4C B4 00  U.CPM     A.UL..
7FC0:  55 AA 42 41 53 49 43 20  20 20 03 00 09 4D 6B 00  U.BASIC   ...Mk.
7FD0:  55 AA 57 42 41 53 49 43  20 20 01 00 03 30 52 1C  U.WBASIC  ...0R.
7FE0:  55 AA 42 41 53 49 43 20  20 20 01 00 00 30 55 1C  U.BASIC   ...0U.
7FF0:  55 AA 4D 6F 6E 69 74 6F  72 20 02 00 00 00 E6 22  U.Monitor ....."

Each feature has a number of flags in the descriptor which tell SCM what to do with it. One of those flags is AUTORUN. Setting this flag causes the feature to be executed during SCM initialisation.

In this case, setting bit 7 of location 0x7FBA will cause the SCM command to AUTORUN and thus load CP/M at reset. So change the value 0x41 to 0xC1.

A 16k ROM bank will have this table ending at 0x3FFF.

This is all documented in the Small Computer Monitor User Guide [page 36].

Below is a terminal session from the modified ROM.

Steve

The monitor starts up 'invisibly' before loading CPM:

 CP/M 2.2 Copyright 1979 (c) by Digital Research, BIOS-F (2022-03-23)

A>
A>

Starting up without a CF card enters the monitor but without the usual SCM startup message.:

 Compact flash not present
*
*

Note: This involves using the 88 ROM image (don't set A13).

Original message from the RC2014 creator, Spencer Owen:

With regard to your question about booting directly to CP/M, no, other than modifying the initial loader program on ROM (which would the lose the ability to to receive Intel Hex files, which although rarely used, can be super useful), I don't know of a way. If you boot to SCM, you just have to type cpm and hit return, but that is going to be one extra keystroke. It may be worth asking the question on the RC2014-Z80 Google Group where there are a lot more people familiar with the RC2014 than on Stack Overflow.

1
  • 3
    Worked fine. Great reaction :))
    – Raffzahn
    Jul 25, 2022 at 19:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .