BBC Micro Screen Formats Part 2

This article was originally published in The Crypt Mag

Introduction

Following on from my previous article on BBC Micro screen formats, this article aims to provide information on screen modes used by the American BBC Micro systems, shadow screens and the ‘Mode 8’ screen mode.

The American BBC Micro

The BBC Micro was also made available to the American market and due to the differences between British and American TV systems changes had to be made to the screen modes for reasons of compatibility.

The table below shows the American screen properties. For comparison the British screen properties are provided in brackets where there are differences.

Mode Graphics Width Graphics Height Text Columns Text Rows Depth No. of Colours Memory Used
0 640 200 (256) 80 25 (32) 1 2 16 kB (20 kB)
1 320 200 (256) 40 25 (32) 2 4 16 kB (20 kB)
2 160 200 (256) 20 25 (32) 4 16 16 kB (20 kB)
3 80 22 (25) 1 2 16 kB
4 320 200 (256) 40 25 (32) 1 2 8 kB (10 kB)
5 160 200 (256) 20 25 (32) 2 4 8 kB (10 kB)
6 40 22 (25) 1 2 8 kB
7 40 20 (25) 8 1 kB

The main differences are the reduction in screen height and, in some cases, reduced memory consumption.

Mode 8

Mode 8 is not a standard screen mode on the BBC Micro, but by programming the video chip you have the facility to create your own screen modes.

The following program (taken from the Advanced User Guide for the BBC Micro) sets up a ‘Mode 8’ screen and displays a small demonstration of the new mode. Note that due to the nature of this program some emulators may have problems and give unexpected results. It has been tested to work fine under BeebEm.

10 REM CREATE 'MODE 8'
20 REM NOTE: NO WINDOWING ALLOWED
30 REM
40 REM NOTE: POKING VDU VARIABLES
50 REM IS GENERALLY ILL ADVISED.
60 MODE 5:REM BASIC MODE
70 REM CONFIGURE VIDEO ULA FOR 10 COLUMN, 16 CHARACTER
80 *FX 154,224
90 ?&360=&F:REM COLOUR MASK
100 ?&361=1:REM PIXELS PER BYTE—1
110 ?&34F=&20:REM BYTES PER CHARACTER (4 wide x 8 high)
120 ?&363=&55:REM GRAPHICS RIGHT MASK
130 ?&362=&AA:REM GRAPHICS LEFT MASK
140 ?&30A=9:REM NO. OF CHARS PER LINE
150 VDU 20
160 REM DEMO
170 MOVE 0,0:DRAW 640,512:DRAW 1279,0
180 PRINT TAB(1,2);
190 A$=”***HelloThere***”
200 COLOUR 129
210 FOR A%=1 TO 16
220 IF A%=9 THEN PRINT TAB(1,8);
230 COLOUR A%-1
240 PRINT MID$(A$,A%,1);
250 NEXT A%
260 PRINT

Running this program should provide you with the following screen:

The properties of this screen mode are as follows:

Mode Graphics Width Graphics Height Text Columns Text Rows Depth No. of Colours Memory Used
8 80 256 10 32 4 16 10 kB

As you can see the properties are similar to a Mode 2 screen, but with half the horizontal resolution and hence half the memory consumption. This results in a 10 kB screen mode with 16 colours (i.e. 8 normal and 8 flashing) which is useful if a program is quite memory hungry, but requires more colour than standard 10 kB modes would allow. It also allows 16 colour graphics modes on the earlier BBC Micro model A which only had 16 kB of RAM as standard.

Shadow Screens

Later models of the BBC Micro such as the model B+ and Master series have what are called shadow screens. The main difference between normal and shadow screens is that the memory used for a shadow screen is located in a specially reserved area. By utilising shadow screens more memory is made available for use by programs.

Shadow screens are also useful for creating smooth animations by switching between normal and shadow screen, a technique referred to as double buffering.

By using shadow screens it is also possible to create, for example, a high resolution 2 colour 640×512 screen mode. This is achieved by having half of the screen in normal screen memory and the other half in shadow screen memory and then interlacing the two together.

Article copyright © 2007, 2014 Francis G. Loch

4 thoughts on “BBC Micro Screen Formats Part 2”

  1. Hi there! Great article – and very useful. I have a question based on the modes displayed – is it possible to make a MODE 1 screen, but which only uses 256 by 256 pixels? I can see from your example how to code some of it, but I’m not sure what the right and left mask do, nor if the BBC can display a square mode.

    1. From what I understand of programming the BBC Micro’s video chip I don’t think a 256×256 screen mode is possible, but I may be wrong with that. You could try asking at http://www.retrosoftware.co.uk/forum/ to see if anyone there can help.

      Depending on what you are trying to achieve, have you considered just creating a window that is 256×256? You can do this quite simply using VDU commands. Have a look at the following:

      http://beebwiki.mdfs.net/VDU_24
      http://beebwiki.mdfs.net/VDU_28

      Kind regards,

      Francis

  2. Many have suggested it can’t be done – but there may still be some cunning trick – so I’ve stuck a message on retro as you suggest. Basically I’m just greedy and want 4K back! My game only requires 256 by 256 for display, so the right hand side of the screen is redundant. I’ll fill it with something, if development gets that far – but just reclaiming the ram would be best.

    1. You don’t really need to define your own screen mode then, all you really want to do is set up a graphics window to the size you want (similar to what games like Exile done to reduce memory consumption). The guys on Retro Software would be able to advise you how to do this better than I can.

      Kind regards,

      Francis

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Homepage of Francis G. Loch's various projects