Timex 2000 series: Difference between revisions

Jump to navigation Jump to search
Typographical changes
(Typographical changes)
Line 42: Line 42:
The TS2068, the TC2068 and the TC2048 each share the same basic internal design, described immediately below:
The TS2068, the TC2068 and the TC2048 each share the same basic internal design, described immediately below:


* The TC2068 is the Portuguese made European version operating at 50Hz on a 230-240v power supply and generates a PAL television signal (used throughout Europe, except in France where SECAM is used instead) with a normal expansion bus. Both machines feature an [[AY-3-8912]] sound chip (not 128 compatible), an extended version of BASIC in 24K of ROM (semi-compatible), two non-standard joystick ports, a cartridge dock (not IF2 compatible), and a new ULA with extra video modes, but some incompatiblities. There is also a Polish clone of the TC2068, called the UK2086, which substitutes an RS232 port for one of the joystick ports.
* The TC2068 is the Portuguese made European version operating at 50Hz on a 230–240v power supply and generates a PAL television signal (used throughout Europe, except in France where SECAM is used instead) with a normal expansion bus. Both machines feature an [[AY-3-8912]] sound chip (not 128 compatible), an extended version of BASIC in 24K of ROM (semi-compatible), two non-standard joystick ports, a cartridge dock (not IF2 compatible), and a new ULA with extra video modes, but some incompatiblities. There is also a Polish clone of the TC2068, called the UK2086, which substitutes an RS232 port for one of the joystick ports.


* The TC2048 was designed and produced in Portugal. Basically, the TC2048 is a TC2068 with all the extra hardware removed, except the new ULA, but a normal BASIC ROM (only slightly modified), a BNC composite out (but no RGB signals on the bus), and a [[Kempston joystick interface|Kempston]] joystick port (but no +5v as needed by autofire joysticks).
* The TC2048 was designed and produced in Portugal. Basically, the TC2048 is a TC2068 with all the extra hardware removed, except the new ULA, but a normal BASIC ROM (only slightly modified), a BNC composite out (but no RGB signals on the bus), and a [[Kempston joystick interface|Kempston]] joystick port (but no +5v as needed by autofire joysticks).
Line 58: Line 58:
== Screen Modes ==
== Screen Modes ==
The ULA used by the Timex machines provides a number of additional screen modes. These are controlled using Port 0xff. An unfortunate side effect of this is that a few games, like Arkanoid, which expect reading 0xff to produce screen and ATTR data bytes when the ULA is reading the screen memory, will not work, since reading 0xff on the Timex returns the last byte sent to the port. It is not known if this port is fully decoded but it seems likely that it is partially decoded, as on the Spectrum. Port 0xff is also used to enable/disable the timer interrupt and select which bank of memory to use for the horizontal MMU. The byte to output will be interpreted thus:
The ULA used by the Timex machines provides a number of additional screen modes. These are controlled using Port 0xff. An unfortunate side effect of this is that a few games, like Arkanoid, which expect reading 0xff to produce screen and ATTR data bytes when the ULA is reading the screen memory, will not work, since reading 0xff on the Timex returns the last byte sent to the port. It is not known if this port is fully decoded but it seems likely that it is partially decoded, as on the Spectrum. Port 0xff is also used to enable/disable the timer interrupt and select which bank of memory to use for the horizontal MMU. The byte to output will be interpreted thus:
  Bits 0-2: Screen mode. 000=screen 0, 001=screen 1, 010=hi-colour, 110=hi-res
  Bits 0–2: Screen mode. 000=screen 0, 001=screen 1, 010=hi-colour, 110=hi-res
   Bits 3-5: Sets the screen colour in hi-res mode.
   Bits 3–5: Sets the screen colour in hi-res mode.
               000 - Black on White    100 - Green on Magenta
               000—Black on White    100—Green on Magenta
               001 - Blue on Yellow    101 - Cyan on Red
               001—Blue on Yellow    101—Cyan on Red
               010 - Red on Cyan        110 - Yellow on Blue
               010—Red on Cyan        110—Yellow on Blue
               011 - Magenta on Green  111 - White on Black
               011—Magenta on Green  111—White on Black
   Bit 6:    If set disables the generation of the timer interrupt.
   Bit 6:    If set disables the generation of the timer interrupt.
   Bit 7:    Selects which bank the horizontal MMU should use. 0=DOCK, 1=EX-ROM.
   Bit 7:    Selects which bank the horizontal MMU should use. 0=DOCK, 1=EX-ROM.
Screen 0 is the normal screen at 0x4000. Screen 1 uses the same format but at 0x6000.
Screen 0 is the normal screen at 0x4000. Screen 1 uses the same format but at 0x6000.


The hi-colour screen uses the data area of screen 0 and screen 1 to create a 512x192 pixel screen. Columns are taken alternately from screen 0 and screen 1. The attribute area is not used. In this mode all colurs, including the BORDER, are BRIGHT, and the BORDER colour is the same as the PAPER colour.
The hi-colour screen uses the data area of screen 0 and screen 1 to create a 512×192 pixel screen. Columns are taken alternately from screen 0 and screen 1. The attribute area is not used. In this mode all colours, including the BORDER, are BRIGHT, and the BORDER colour is the same as the PAPER colour.


The multi-colour screen uses the data area of screen 0 for its data and the data area of screen 1 for its attributes, giving 2 colours per 8x1 pixel block. The attribute area is in the same byte order as the data area, which means MLT files, which have the attribute are in series, must be converted to be displayed.
The multi-colour screen uses the data area of screen 0 for its data and the data area of screen 1 for its attributes, giving 2 colours per 8×1 pixel block. The attribute area is in the same byte order as the data area, which means MLT files, which have the attribute are in series, must be converted to be displayed.


Bit 6 is the hardware equivalent of issuing a DI (disable interrupts) instruction in machine code, and is unaffected by the instruction EI (enable interrupts), so should be used with caution. Bit 6 can be useful for getting ROM routines which normally enable interrupts to run slightly faster.
Bit 6 is the hardware equivalent of issuing a DI (disable interrupts) instruction in machine code, and is unaffected by the instruction EI (enable interrupts), so should be used with caution. Bit 6 can be useful for getting ROM routines which normally enable interrupts to run slightly faster.


With careful timing it is possible to mix screen modes so you could have a screen where the top half is hi-colour and the bottom half is hi-res - perfect for text adventures with graphics. Using a similar technique it is also possible to have more than two colours on a hi-res screen. However, it is believed that no commercial software ever actually did this.
With careful timing it is possible to mix screen modes so you could have a screen where the top half is hi-colour and the bottom half is hi-res—perfect for text adventures with graphics. Using a similar technique it is also possible to have more than two colours on a hi-res screen. However, it is believed that no commercial software ever actually did this.
 
== Memory ==
== Memory ==
{| class="wikitable" style="text-align: center; float:right; margin:0.5em 0px 0.5em 1em; clear:right;"
{| class="wikitable" style="text-align: center; float:right; margin:0.5em 0px 0.5em 1em; clear:right;"
Line 84: Line 85:
|- style="height: 3em;"
|- style="height: 3em;"
! 0xFFFF <br />0xE000
! 0xFFFF <br />0xE000
| Bank 7' || rowspan="4" | 32k RAM || Bank 7
| Bank 7′ || rowspan="4" | 32k RAM || Bank 7
|- style="height: 3em;"
|- style="height: 3em;"
! 0xDFFF <br />0xC000
! 0xDFFF <br />0xC000
| Bank 6' || Bank 6
| Bank 6′ || Bank 6
|- style="height: 3em;"
|- style="height: 3em;"
! 0xBFFF <br />0xA000
! 0xBFFF <br />0xA000
| Bank 5' || Bank 5
| Bank 5′ || Bank 5
|- style="height: 3em;"
|- style="height: 3em;"
! 0x9FFF <br />0x8000
! 0x9FFF <br />0x8000
| Bank 4' || Bank 4
| Bank 4′ || Bank 4
|- style="height: 3em;"
|- style="height: 3em;"
! 0x7FFF <br />0x6000
! 0x7FFF <br />0x6000
| Bank 3' || Screen 1 || Bank 3
| Bank 3′ || Screen 1 || Bank 3
|- style="height: 3em;"
|- style="height: 3em;"
! 0x5FFF <br />0x4000
! 0x5FFF <br />0x4000
| Bank 2' || Screen 0 || Bank 2
| Bank 2′ || Screen 0 || Bank 2
|- style="height: 3em;"
|- style="height: 3em;"
! 0x3FFF <br />0x2000
! 0x3FFF <br />0x2000
| Bank 1' || rowspan="2" | 16k ROM || Bank 1
| Bank 1′ || rowspan="2" | 16k ROM || Bank 1
|- style="height: 3em;"
|- style="height: 3em;"
!0x1FFF <br />0x0000
!0x1FFF <br />0x0000
| Bank 0' || Bank 0
| Bank 0′ || Bank 0
|-
|-
|}
|}
The Timex machines feature a horizontal memory management unit. In the TS2068 and TC2068 it is used to support the extended BASIC and cartridges plugged into the dock. It is present in the TC2048 but there is no direct way to connect anything to it (although the refresh signals are available to connect an additional 128K of RAM to the horizontal MMU).
The Timex machines feature a horizontal memory management unit. In the TS2068 and TC2068 it is used to support the extended BASIC and cartridges plugged into the dock. It is present in the TC2048 but there is no direct way to connect anything to it (although the refresh signals are available to connect an additional 128K of RAM to the horizontal MMU).


Memory is paged in 8K banks from either the DOCK or the EX-ROM, but these banks are mutually exclusive - you cannot page in a bank from both simultaneously. Both DOCK and EX-ROM banks are uncontended. Bit 7 of port 0xff determines which bank to use (0=DOCK, 1=EX-ROM). Port 0xf4 determines which banks are to be paged in with each bit referring to the relevant bank (0-7 or 0'-7'). When memory is being paged, interrupts should be disabled and the stack should be in an area which is not going to change.  
Memory is paged in 8K banks from either the DOCK or the EX-ROM, but these banks are mutually exclusive—you cannot page in a bank from both simultaneously. Both DOCK and EX-ROM banks are uncontended. Bit 7 of port 0xff determines which bank to use (0=DOCK, 1=EX-ROM). Port 0xf4 determines which banks are to be paged in with each bit referring to the relevant bank (0–7 or 0′–7′). When memory is being paged, interrupts should be disabled and the stack should be in an area which is not going to change.  


The HOME bank is the normal Spectrum memory area. The top 32K is uncontended but the 16K screen area below that is contended. Banks are overlaid on this bank, but paging over the screen area does not change the RAM used by the ULA. This does mean it is possible to set up a screen and page it out.
The HOME bank is the normal Spectrum memory area. The top 32K is uncontended but the 16K screen area below that is contended. Banks are overlaid on this bank, but paging over the screen area does not change the RAM used by the ULA. This does mean it is possible to set up a screen and page it out.


On a TC2048, BASIC is contained in the 16K ROM area and banks 0-7 and 0'-7' are not normally available, while on a TS2068 or a TC2068 part of the BASIC is stored in an 8K ROM in bank 0' and cartridges plugged into the dock use banks 0-7.
On a TC2048, BASIC is contained in the 16K ROM area and banks 0–7 and 0′–7′ are not normally available, while on a TS2068 or a TC2068 part of the BASIC is stored in an 8K ROM in bank 0' and cartridges plugged into the dock use banks 0–7.


The contended memory timings for these machines are unknown but should be similar to that for the 48K machine, except that the pattern starts at a different number of T-states after the interrupt, than the usual 14344.
The contended memory timings for these machines are unknown but should be similar to that for the 48K machine, except that the pattern starts at a different number of T-states after the interrupt, than the usual 14344.
Line 122: Line 123:
== Sound Chip ==
== Sound Chip ==
The [[AY-3-8912]] used in the TS2068 and TC2068 is controlled by two I/O ports:
The [[AY-3-8912]] used in the TS2068 and TC2068 is controlled by two I/O ports:
  OUT (0xf5) - Select a register 0-14
  OUT (0xf5)—Select a register 0–14
   IN  (0xf6) - Read the value of the selected register
   IN  (0xf6)—Read the value of the selected register
   OUT (0xf6) - Write to the selected register
   OUT (0xf6)—Write to the selected register
IN 0xf5 always returns 255.
IN 0xf5 always returns 255.


Line 158: Line 159:
* '''SOUND:''' The SOUND command accepts pairs of numbers separated by semi-colons. Up to 15 pairs are permitted for each SOUND command. The first number in each pair designates the register, while the second number contains the value. <u>Example:</u> SOUND [n,n];[n,n] ..... [n,n];[n,n]. The available registers are:
* '''SOUND:''' The SOUND command accepts pairs of numbers separated by semi-colons. Up to 15 pairs are permitted for each SOUND command. The first number in each pair designates the register, while the second number contains the value. <u>Example:</u> SOUND [n,n];[n,n] ..... [n,n];[n,n]. The available registers are:


**0 - Fine Tune, Channel A. Permitted values: 0-255
**0—Fine Tune, Channel A. Permitted values: 0–255
**1 - Coarse Tune, Channel A. Permitted values: 0-15
**1—Coarse Tune, Channel A. Permitted values: 0–15
**2 - Fine Tune, Channel B. Permitted values: 0-255
**2—Fine Tune, Channel B. Permitted values: 0–255
**3 - Coarse Tune, Channel B. Permitted values: 0-15
**3—Coarse Tune, Channel B. Permitted values: 015
**4 - Fine Tune, Channel C. Permitted values: 0-255
**4—Fine Tune, Channel C. Permitted values: 0–255
**5 - Coarse Tune, Channel C. Permitted values: 0-15
**5—Coarse Tune, Channel C. Permitted values: 015
**6 - Noise. Permitted values: 0-31
**6—Noise. Permitted values: 0–31
**7 - Enable. Permitted values: 0-63
**7—Enable. Permitted values: 0–63
**8 - Amplitude, Channel A. Permitted values: 0-15
**8—Amplitude, Channel A. Permitted values: 0–15
**9 - Amplitude, Channel B. Permitted values: 0-15
**9—Amplitude, Channel B. Permitted values: 0–15
**10 - Amplitude, Channel C. Permitted values: 0-15 (16 enables envelope)
**10—Amplitude, Channel C. Permitted values: 0–15 (16 enables envelope)
**11 - Fine Tune envelope period. Permitted values: 0-255
**11—Fine Tune envelope period. Permitted values: 0–255
**12 - Coarse Tune envelope period. Permitted values: 0-255
**12—Coarse Tune envelope period. Permitted values: 0–255
**13 - Envelope shape. Permitted values: 0-15
**13—Envelope shape. Permitted values: 0–15


* '''STICK:''' The STICK command is used to read the signal generated by devices connected to one of the two Joystick ports available. The first number represents the device type being read - (1) is the Joystick and (2) is the button. The second number is the Joystick number - (1) is left and (2) is right. <u>Example:</u> IF STICK([n,n]) THEN ... Valid return values are 1 (pressed) or 0 (not pressed) if reading the button, and:
* '''STICK:''' The STICK command is used to read the signal generated by devices connected to one of the two Joystick ports available. The first number represents the device type being read—(1) is the Joystick and (2) is the button. The second number is the Joystick number—(1) is left and (2) is right. <u>Example:</u> IF STICK([n,n]) THEN ... Valid return values are 1 (pressed) or 0 (not pressed) if reading the button, and:


** 0 - Centred
** 0—Centred
** 1 - Up
** 1—Up
** 2 - Down
** 2—Down
** 4 - Left
** 4—Left
** 5 - Up and Left
** 5—Up and Left
** 6 - Down and Left
** 6—Down and Left
** 8 - Right
** 8—Right
** 9 - Up and Right
** 9—Up and Right
** 10 - Down and Right
** 10—Down and Right


{{CC-BY-SA-techwiki|Timex 2000 series|Timex_2000_series}}
{{CC-BY-SA-techwiki|Timex 2000 series|Timex_2000_series}}

Navigation menu