Previous Thread
Next Thread
Print Thread
Page 1 of 2 1 2
#77607 02/23/12 08:10 AM
Joined: Feb 2012
Posts: 14
B
Member
OP Offline
Member
B
Joined: Feb 2012
Posts: 14
The TRS-80 Model 16 description claims to be missing a ROM for the 68000. This is incorrect. The Model 16 (and 6000) do not have any ROM for the 68000! The Z80 has to load an image into the 68000 memory before it takes the 68000 out of reset.

Joined: Feb 2005
Posts: 449
C
Senior Member
Offline
Senior Member
C
Joined: Feb 2005
Posts: 449
The pages describing the M68000 were missing from the schematics, so it was just a guess that it has a ROM. Do you happen to know how much memory the M68K has and where/how it is mapped to the Z80 address space?

Joined: Feb 2012
Posts: 14
B
Member
OP Offline
Member
B
Joined: Feb 2012
Posts: 14
The amount of memory can vary from 128KB to multiple megabytes. Theoretically up to 7MB, but RS never made big enough RAM cards to get there. That's physical address space, but logical address space is more complicated. They have a crude two-segment MMU which can modify A12 through A19 for relocation and bounds-checking, but it passes A20 through A22 straight through, so the relocation and bounds checking applies to each 1MB of the 7MB possible RAM address space. A23 selects between the two sets of relocatoin and bounds registers.

The 68K side also has an Am9519 interrupt controller.

For (most of) the details, you need the Model 16 Service Manual, which can temporarily be found here:

http://www.brouhaha.com/~eric/retrocomputing/radio_shack/trs80_model_ii/trs80_model_16_service_manual.pdf

Note that there were three generations of 68K board, the original 6 MHz long board, the 6 MHz short board, and the 8 MHz board. There may have been significant changes to the 8 MHz board, as it was not fully compatible, but there doesn't seem to be any documentation on it.

Reverse-engineered boot ROM source code can be found at:
http://www.brouhaha.com/~eric/retrocomputing/radio_shack/trs80_model_ii/trs80m2boot.zip

Joined: Feb 2012
Posts: 14
B
Member
OP Offline
Member
B
Joined: Feb 2012
Posts: 14
The 68K memory can be mapped into the Z80 address space 16KB at a time, from 8000 to BFFF, by writing the upper address bits A14..A23 and some control bits to the control ports DE and DF. You have to write zero to the low four bits of port FF first, to deselect any Z80 RAM from that region. Some of the details are in the service manual, though they seem to leave some important information as an exercise for the reader.

Joined: Feb 2012
Posts: 14
B
Member
OP Offline
Member
B
Joined: Feb 2012
Posts: 14
A few more comments about Model II/12/16 ROMs. The "cpu_2119.bin/hex" ROM couldn't possibly have been from a "Texas Instruments 2716", because the TMS2716 is NOT pin compatible with anyone else's 2716, and requires three supply voltages. If it was really a TI part, it must have been a TMS2516, which was their 5V only part that was compatible with the normal 2716. In fact, I found a photo of S/N 178892, and it definitely is a TMS2516JL-45.

c8ff is version 1, 2bff is version 2, 2119 is version 3, fc86 is version 4, and 9733 is version 5.

If you really want the keyboard ROM dumped, at some point I can build a custom test fixture to extract it. I don't have time right now. Later models use a different keyboard which might contain a different microcontroller.

Joined: Mar 2001
Posts: 16,806
Likes: 32
R
Very Senior Member
Online Content
Very Senior Member
R
Joined: Mar 2001
Posts: 16,806
Likes: 32
Thanks for all the great info about the Model 16! The more off-the-beaten-path machines are what makes emulation interesting.

And yes, we really do want the keyboard ROM dumped. We're a bit obsessive that way.

Joined: Feb 2005
Posts: 449
C
Senior Member
Offline
Senior Member
C
Joined: Feb 2005
Posts: 449
The keyboard has an 8021 MCU on it, and nothing but a 10K resistor connected across the XTAL inputs. What clock frequency does this create?

Joined: Mar 2006
Posts: 1,059
Likes: 1
L
Very Senior Member
Offline
Very Senior Member
L
Joined: Mar 2006
Posts: 1,059
Likes: 1
If you need help dumping the 8021, I have a setup on a solderless breadboard here which dumps them.
To make such a setup, you will need:
a solderless breadboard
a dip28-ended cable (i.e. has dip28 connector on both ends; one end plugs into the eprom reader, the other end into the breadboard)
a 3.579545Mhz (or so, 1.8432Mhz works fine as well) crystal
a 9v battery and a 9v battery connector with wires
a 170ohm resistor, for the 9v battery '+' terminal
a 1Mohm resistor, to run parallel with the crystal to make it oscillate properly

On the solderless breadboard:
* The crystal (in parallel with the 1Mohm resistor) goes across 8021 pins 15 and 16 (XTAL1 and XTAL2)
* The 9v battery connector goes between the VCC (+5v) pin (pin 28) of the dip28 and (thru the 170ohm resistor to limit current) to give +14v or so to both 8021 pin 3 (PROG) and pin 17 (RESET), to put the 8021 into rom verify mode.
Don't plug the battery into the connector yet!
(Since this may be a bit confusing, it goes: VCC(+5) -> -[9v batt]+ -> 170ohm resistor -> 8021 pins 3 and 17 )
* The a0 pin (pin 10) of the dip28 connects to pin 13 (t1) of the 8021 to increment address in rom verify mode
* The data bus of the dip28 (pins 11,12,13,15,16,17,18) connects to 8021 pins 4,5,6,7,8,9,10,11 (P00 thru P07) respectively.
* dip28 VCC (+5v) (pin 28) connects to 8021 pin 28 (VCC)
* dip28 GND (pin 14) connects to 8021 pin 14 (VSS)

Set your eprom programmer to a dip28 chip like 27256, connect the dip28-ended cable, start dumping, and THEN connect the 9v battery; you should get at first a bunch of 0xFF while the 9v battery wasn't connected, then a bunch of garbage (since the 8021 was executing and didn't reset pc to 0), and finally a repeating pattern of 0x1000 bytes, 0x800 of data (with each byte repeated twice, because we're using A0 to clock the T1 pin) and 0x800 of 0xFF. If you send the whole dump of the 27256, I can easily pick out the rom part of the data based on the FFs.

Thanks to Kevin Horton for figuring out how to dump these chips.

If this seems too intimidating, you can lend the chip here and I'll dump it and send it back asap. PM me if you want to do this.

LN

Last edited by Lord Nightmare; 02/24/12 09:39 PM. Reason: clarify some details

"When life gives you zombies... *CHA-CHIK!* ...you make zombie-ade!"
Joined: Mar 2006
Posts: 1,059
Likes: 1
L
Very Senior Member
Offline
Very Senior Member
L
Joined: Mar 2006
Posts: 1,059
Likes: 1
The dip28-ended cable is probably the hardest part to get; I believe there's a guy at http://www.hylander.com/miniwave.html who is selling them for $10 each, but you'd need to ask him if its the correct part; it should have two ends which look like dip28 chips with a ribbon between them, and the pins connect 1:1.
My board actually uses a more common dip24-ended cable with both ends stuffed into dip28 sockets and an extra 4 wires jammed into the 4 extra pins of the sockets on each end. It looks ugly but works fine.

LN

Last edited by Lord Nightmare; 02/24/12 09:44 PM. Reason: clarify

"When life gives you zombies... *CHA-CHIK!* ...you make zombie-ade!"
Joined: Feb 2012
Posts: 14
B
Member
OP Offline
Member
B
Joined: Feb 2012
Posts: 14
The MCS-48 user manual says that the 8021 will run at 3 MHz when a 10 Kohm resistor is connected between the XTAL1 and XTAL2 pins. Since the 8021 uses 30 oscillator cycles per instruction cycle (vs. 15 for the "normal" 8048 family parts), that results in a 10 us instruction cycle. The manual also notes that "the required resistance may vary from 10 Kohm, and should be adjusted as necessary." I would expect the actual frequency to be 3 MHz +/- 30%. (Most of that tolerance is NOT due to the tolerance of the resistor.)

According to TRS-80 Model II Technical Bulletin 40, the keyboard schematic in the Technical Reference Manual is wrong, and the timing component used for the 8021 is not a resistor, but rather, a 1000 uH inductor. I have not found any good description of how the frequency varies with the inductance, but it's probably reasonable to guess that the frequency is approximately 3 MHz.

Apparently some Model II keyboards were made by Cherry rather than Keytronic. They would not be capacitive, so they would have different electronics than the Keytronic keyboard, which might use an entirely different microcontroller, but would probably use different firmware even if an 8021 was used.

Page 1 of 2 1 2

Link Copied to Clipboard
Who's Online Now
4 members (mixmaster, R. Belmont, 2 invisible), 27 guests, and 8 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics8,973
Posts117,882
Members5,001
Most Online890
Jan 17th, 2020
Forum Host
These forums are hosted by www.retrogamesformac.com
Forum hosted by www.retrogamesformac.com