<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://oldwiki.cpcwiki.eu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Fgbrain</id>
		<title>CPCWiki - THE Amstrad CPC encyclopedia! - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="https://oldwiki.cpcwiki.eu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Fgbrain"/>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php/Special:Contributions/Fgbrain"/>
		<updated>2026-08-28T05:22:34Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.25.1</generator>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=%CE%95.%CE%A0.%CE%A4.%CE%91_/_%CE%97_%CE%95%CE%BB%CE%BB%CE%B7%CE%BD%CE%B9%CE%BA%CE%AE_%CF%80%CE%BB%CE%B5%CF%85%CF%81%CE%AC_%CF%84%CE%BF%CF%85_Amstrad_(Greek_Side_Of_Amstrad)&amp;diff=110683</id>
		<title>Ε.Π.Τ.Α / Η Ελληνική πλευρά του Amstrad (Greek Side Of Amstrad)</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=%CE%95.%CE%A0.%CE%A4.%CE%91_/_%CE%97_%CE%95%CE%BB%CE%BB%CE%B7%CE%BD%CE%B9%CE%BA%CE%AE_%CF%80%CE%BB%CE%B5%CF%85%CF%81%CE%AC_%CF%84%CE%BF%CF%85_Amstrad_(Greek_Side_Of_Amstrad)&amp;diff=110683"/>
				<updated>2023-04-11T17:20:36Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;19 issues:&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-05-%CE%91%CF%80%CF%81%CE%AF%CE%BB%CE%B9%CE%BF%CF%82-1987.17939/ Apr1987]&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-06-%CE%9C%CE%AC%CE%B9%CE%BF%CF%82-1987.17956/ May1987]&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-11-%CE%9D%CE%BF%CE%AD%CE%BC%CE%B2%CF%81%CE%B9%CE%BF%CF%82-1987.834/ nov1987]&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-12-%CE%94%CE%B5%CE%BA%CE%AD%CE%BC%CE%B2%CF%81%CE%B9%CE%BF%CF%82-1987.1195/ Dec1987]&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-13-%CE%99%CE%B1%CE%BD%CE%BF%CF%85%CE%AC%CF%81%CE%B9%CE%BF%CF%82-1988.17968/ Jan1988]&lt;br /&gt;
# issue &lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-15-%CE%9C%CE%AC%CF%81%CF%84%CE%B9%CE%BF%CF%82-1988.17943/ Mar1988]&lt;br /&gt;
# issue&lt;br /&gt;
# issue&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-18-%CE%99%CE%BF%CF%8D%CE%BD%CE%B9%CE%BF%CF%82-1988.625/ Jun1988]&lt;br /&gt;
# [https://retromaniax.gr/threads/%CE%95-%CE%A0-%CE%A4-%CE%91-19-%CE%99%CE%BF%CF%8D%CE%BB%CE%B9%CE%BF%CF%82-%CE%91%CF%8D%CE%B3%CE%BF%CF%85%CF%83%CF%84%CE%BF%CF%82-1988.790/ last issue]&lt;br /&gt;
&lt;br /&gt;
reading the mag videos:&lt;br /&gt;
https://www.youtube.com/playlist?list=PL4lNmaj7owmCHzjRH903s5Tb1U8-jHofr&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=CRTC&amp;diff=108371</id>
		<title>CRTC</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=CRTC&amp;diff=108371"/>
				<updated>2022-01-05T20:24:25Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Links */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* ''This is an article about the &amp;quot;Cathode Ray Tube Controller&amp;quot; hardware unit of the Amstrad CPC. For the cpc scene member see [[ChaRleyTroniC]]''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The '''CRTC''' (Cathode Ray Tube Controller) helps to generate the video signal of the Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
NOTE: This document describes the functionality in terms of the CPC with its separate CRTC and Gate-Array. The Plus has both integrated into the same IC, but could be considered to have two functional blocks, one for CRTC and one for Gate-Array. In this document the term 'Gate-Array' is used, but this also applies to the ASIC.&lt;br /&gt;
&lt;br /&gt;
== Overview ==&lt;br /&gt;
&lt;br /&gt;
The 6845 Cathode Ray Tube Controller (CRTC) is a programmable IC used to generate video displays. This IC is used in a variety of computers including the Amstrad CPC, Amstrad CPC+ and KC Compact. &lt;br /&gt;
&lt;br /&gt;
The CRTC was a common part available from many different manufacturers. During the life of the CPC, Amstrad sourced the CRTC from various manufacturers. &lt;br /&gt;
&lt;br /&gt;
All ICs used were based on the same design but have a different implementation. As a result they do not operate identically in all situations. This document highlights these differences. &lt;br /&gt;
&lt;br /&gt;
This table lists the known ICs used, with their part number, manufacturer and type number. &lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''Part number''||''Manufacturer''||''Type number (note 3)''&lt;br /&gt;
|-&lt;br /&gt;
|HD6845S||Hitachi||0&lt;br /&gt;
|-&lt;br /&gt;
|UM6845||UMC||0&lt;br /&gt;
|-&lt;br /&gt;
|UM6845R||UMC||1&lt;br /&gt;
|-&lt;br /&gt;
|MC6845||Motorola||2&lt;br /&gt;
|-&lt;br /&gt;
|AMS40489||Amstrad||3 (note 1)&lt;br /&gt;
|-&lt;br /&gt;
|40226||Amstrad||4 (note 2)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
'''NOTES''' &lt;br /&gt;
&lt;br /&gt;
1. The CRTC functionality is integrated into the CPC+ ASIC. This type exists only in the CPC464+,CPC6128+ and GX4000. &lt;br /&gt;
&lt;br /&gt;
2. This type exists in &amp;quot;cost-down&amp;quot; CPC464 and CPC6128 systems. In the &amp;quot;cost-down&amp;quot; the CRTC functionality is integrated into a single ASIC IC. This ASIC is often refered to as the &amp;quot;Pre-ASIC&amp;quot; because it preceeded the CPC+ ASIC. The CRTC functionality of the Pre-ASIC is almost identical to the CRTC within the ASIC.&lt;br /&gt;
 &lt;br /&gt;
3. In the Amstrad community each 6845 implementation has been assigned a type number. This type identifies a group of implementations which operate in exactly the same way. &lt;br /&gt;
&lt;br /&gt;
As far as I know, the type number system was originally used by demo programmers. &lt;br /&gt;
&lt;br /&gt;
It is possible to detect the 6845 present using software methods, and this is done to: &lt;br /&gt;
&lt;br /&gt;
* warn that the software was not designed for the detected 6845 and may function incorrectly, &lt;br /&gt;
* to adapt the software so that it will run with the detected 6845 &lt;br /&gt;
* In most cases, the type of the detected 6845 is reported. &lt;br /&gt;
&lt;br /&gt;
4. As far as I know, the KC compact used HD6845R only.&lt;br /&gt;
&lt;br /&gt;
== Timings and relating with Z80 instructions count ==&lt;br /&gt;
&lt;br /&gt;
Some informations like : how many Z80 instructions can I fit within a scan line ? Within a screen ? Etc... See http://www.cpcwiki.eu/forum/programming/frame-flyback-and-interrupts/msg25106/#msg25106&lt;br /&gt;
(To be extracted/edited to conform to wiki good practices).&lt;br /&gt;
&lt;br /&gt;
==Programming==&lt;br /&gt;
&lt;br /&gt;
The 6845 is selected when bit 14 of the I/O port address is set to &amp;quot;0&amp;quot;. Bit 9 and 8 of the I/O port address define the function to access. The remaining bits can be any value, but it is adviseable to set these to &amp;quot;1&amp;quot; to avoid conflict with other devices in the system.&lt;br /&gt;
&lt;br /&gt;
The recommended I/O port addresses are&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''I/O port address''||''Function''||''Read/Write''&lt;br /&gt;
|-&lt;br /&gt;
|&amp;amp;BCxx||Select 6845 register||Write only&lt;br /&gt;
|-&lt;br /&gt;
|&amp;amp;BDxx||Write 6845 register data||Write only&lt;br /&gt;
|-&lt;br /&gt;
|&amp;amp;BExx||(note 1)||Read only&lt;br /&gt;
|-&lt;br /&gt;
|&amp;amp;BFxx||(note 1)||Read only&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
'''NOTE'''&lt;br /&gt;
&lt;br /&gt;
1. The function of these I/O ports is dependant on the CRTC type&lt;br /&gt;
 &lt;br /&gt;
2. If you perform an IN instruction to the select or write functions it will write data to the CRTC from the current data on the bus.&lt;br /&gt;
&lt;br /&gt;
==Addressing==&lt;br /&gt;
&lt;br /&gt;
The following table defines the generated memory address from the CRTC and Gate-Array signals. &lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''Memory Address Signal''||''Signal source''||''Signal name''&lt;br /&gt;
|-&lt;br /&gt;
|A15||6845||MA13 &lt;br /&gt;
|-&lt;br /&gt;
|A14||6845||MA12&lt;br /&gt;
|-&lt;br /&gt;
|A13||6845||RA2 &lt;br /&gt;
|-&lt;br /&gt;
|A12||6845||RA1 &lt;br /&gt;
|-&lt;br /&gt;
|A11||6845||RA0 &lt;br /&gt;
|-&lt;br /&gt;
|A10||6845||MA9 &lt;br /&gt;
|-&lt;br /&gt;
|A9||6845||MA8 &lt;br /&gt;
|-&lt;br /&gt;
|A8||6845||MA7 &lt;br /&gt;
|-&lt;br /&gt;
|A7||6845||MA6 &lt;br /&gt;
|-&lt;br /&gt;
|A6||6845||MA5 &lt;br /&gt;
|-&lt;br /&gt;
|A5||6845||MA4 &lt;br /&gt;
|-&lt;br /&gt;
|A4||6845||MA3 &lt;br /&gt;
|-&lt;br /&gt;
|A3||6845||MA2 &lt;br /&gt;
|-&lt;br /&gt;
|A2||6845||MA1 &lt;br /&gt;
|-&lt;br /&gt;
|A1||6845||MA0&lt;br /&gt;
|-&lt;br /&gt;
|A0||Gate-Array||CCLK&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
CRTC generates the address, Gate-Array reads the data and converts it to pixels based on the current mode.&lt;br /&gt;
&lt;br /&gt;
== DISPTMG ==&lt;br /&gt;
&lt;br /&gt;
DISPTMG signal defines the border. When DISPTMG is &amp;quot;1&amp;quot; the border colour is output by the Gate-Array to the display. The DISPTMG can be forced using R8 (DISPTMG Skew) on type 0,3 and 4 or by setting R6=0 on type 1. It is not possible to force the DISPTMG on type 2 or 5.&lt;br /&gt;
&lt;br /&gt;
The border has higher priority than pixels but lower priority than the black colour output when HSYNC/VSYNC are active.&lt;br /&gt;
&lt;br /&gt;
== HSYNC and VSYNC ==&lt;br /&gt;
&lt;br /&gt;
On CPC, HSYNC and VSYNC from the CRTC are passed into the Gate-Array.&lt;br /&gt;
&lt;br /&gt;
When HSYNC is active Gate-Array outputs the palette colour black. If the HSYNC is set to 14 characters then black will be output for 14us.&lt;br /&gt;
&lt;br /&gt;
The HSYNC is modified before being sent to the monitor. It  happens 2us after the HSYNC from the CRTC and lasts 4us when HSYNC length is greater or equal to 6. &lt;br /&gt;
&lt;br /&gt;
If R2=46, and HSYNC width is 14 then monitor hsync starts at 48 and lasts until 51.&lt;br /&gt;
&lt;br /&gt;
On a CPC monitor, the HSYNC is rendered in &amp;quot;absolute black&amp;quot;. It is darker than the black output by the Gate-Array.&lt;br /&gt;
&lt;br /&gt;
The VSYNC is also modified before being sent to the monitor. It happens two lines* after the VSYNC from the CRTC and stay two lines (same cut rule if VSYNC is lower than 4). PAL (50Hz) does need two lines VSYNC_width, and 4us HSYNC_width.&lt;br /&gt;
&lt;br /&gt;
Using CRTC1, VSYNC width value 0 means a value of 16.&lt;br /&gt;
&lt;br /&gt;
== The 6845 Registers ==&lt;br /&gt;
&lt;br /&gt;
The Internal registers of the 6845 are:&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''Register Index''||''Register Name''||''Range''||''CPC Setting''||''Notes''&lt;br /&gt;
|-&lt;br /&gt;
|0||Horizontal Total||00000000||63||Width of the screen, in characters. Should always be 63 (64 characters). 1 character == 1μs.&lt;br /&gt;
|-&lt;br /&gt;
|1||Horizontal Displayed||00000000||40||Number of characters displayed. Once horizontal character count (HCC) matches this value, DISPTMG is set to 1.&lt;br /&gt;
|-&lt;br /&gt;
|2||Horizontal Sync Position||00000000||46||When to start the HSync signal.&lt;br /&gt;
|-&lt;br /&gt;
|3||Horizontal and Vertical Sync Widths||VVVVHHHH||128+14||HSync pulse width in characters (0 means 16 on some CRTC), should always be more than 8; VSync width in scan-lines. (0 means 16 on some CRTC. Not present on all CRTCs, fixed to 16 lines on these)&lt;br /&gt;
|-&lt;br /&gt;
|4||Vertical Total||x0000000||38||Height of the screen, in characters.&lt;br /&gt;
|-&lt;br /&gt;
|5||Vertical Total Adjust||xxx00000||0||Measured in scanlines, can be used for smooth vertical scrolling on CPC.&lt;br /&gt;
|-&lt;br /&gt;
|6||Vertical Displayed||x0000000||25||Height of displayed screen in characters. Once vertical character count (VCC) matches this value, DISPTMG is set to 1.&lt;br /&gt;
|-&lt;br /&gt;
|7||Vertical Sync position||x0000000||30||When to start the VSync signal, in characters.&lt;br /&gt;
|-&lt;br /&gt;
|8||Interlace and Skew||xxxxxx00||0||00: No interlace; 01: Interlace Sync Raster Scan Mode; 10: No Interlace; 11: Interlace Sync and Video Raster Scan Mode&lt;br /&gt;
|-&lt;br /&gt;
|9||Maximum Raster Address||xxx00000||7||Maximum scan line address on CPC can hold between 0 and 7, higher values' upper bits are ignored&lt;br /&gt;
|-&lt;br /&gt;
|10||Cursor Start Raster||xBP00000||0||Cursor not used on CPC. B = Blink On/Off; P = Blink Period Control (Slow/Fast). Sets first raster row of character that cursor is on to invert.&lt;br /&gt;
|-&lt;br /&gt;
|11||Cursor End Raster||xxx00000||0||Sets last raster row of character that cursor is on to invert&lt;br /&gt;
|-&lt;br /&gt;
|12||Display Start Address (High)||xx000000||48&lt;br /&gt;
|-&lt;br /&gt;
|13||Display Start Address (Low)||00000000||0||Allows you to offset the start of screen memory for hardware scrolling, and if using memory from address &amp;amp;0000 with the firmware.&lt;br /&gt;
|-&lt;br /&gt;
|14||Cursor Address (High)||xx000000||0&lt;br /&gt;
|-&lt;br /&gt;
|15||Cursor Address (Low)||00000000||0&lt;br /&gt;
|-&lt;br /&gt;
|16||Light Pen Address (High)||xx000000||||Read Only&lt;br /&gt;
|-&lt;br /&gt;
|17||Light Pen Address (Low)||00000000||||Read Only&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
registers 18-31 read as 0, on type 0 and 2.&lt;br /&gt;
registers 18-30 read as 0 on type1, register 31 reads as 0x0ff.&lt;br /&gt;
&lt;br /&gt;
Details about Reg. 12 and Reg. 13 specifically:&lt;br /&gt;
&lt;br /&gt;
  .------- REG 12 --------.   .------- REG 13 --------.&lt;br /&gt;
  |                       |   |                       |&lt;br /&gt;
   15 14 13 12 11 10 09 08     07 06 05 04 03 02 01 00&lt;br /&gt;
  .--.--.--.--.--.--.--.--.   .--.--.--.--.--.--.--.--.&lt;br /&gt;
  |X |X |  |  |  |  |  |  |   |  |  |  |  |  |  |  |  |&lt;br /&gt;
  '--'--'--'--'--'--'--'--'   '--'--'--'--'--'--'--'--'&lt;br /&gt;
        '--.--'--.--'---------------.-----------------'&lt;br /&gt;
           |     |                  |&lt;br /&gt;
           |     |                  '------&amp;gt; Offset for setting&lt;br /&gt;
           |     |                           videoram &lt;br /&gt;
           |     |                           (1024 positions)&lt;br /&gt;
           |     |                           Bits 0..9&lt;br /&gt;
           |     |&lt;br /&gt;
           |     '-------------------------&amp;gt; Video Buffer : note (1)&lt;br /&gt;
           |&lt;br /&gt;
           '-------------------------------&amp;gt; Video Page : note (2)&lt;br /&gt;
  note (1)                 note (2)&lt;br /&gt;
  .--.--.--------------.  .--.--.---------------.&lt;br /&gt;
  |11|10| Video Buffer |  |13|12|   Video Page  |&lt;br /&gt;
  |--|--|--------------|  |--|--|---------------|&lt;br /&gt;
  | 0| 0|     16Ko     |  | 0| 0|  0000 - 3FFF  |&lt;br /&gt;
  |--|--|--------------|  |--|--|---------------|&lt;br /&gt;
  | 0| 1|     16Ko     |  | 0| 1|  4000 - 7FFF  |&lt;br /&gt;
  |--|--|--------------|  |--|--|---------------|&lt;br /&gt;
  | 1| 0|     16Ko     |  | 1| 0|  8000 - BFFF  |&lt;br /&gt;
  |--|--|--------------|  |--|--|---------------|&lt;br /&gt;
  | 1| 1|     32Ko     |  | 1| 1|  C000 - FFFF  |&lt;br /&gt;
  '--'--'--------------'  '--'--'---------------'&lt;br /&gt;
&lt;br /&gt;
So, it's possible to use 32KB screen size (used for [[Programming:Overscan|overscan]]) by setting bits 11 and 10 both to 1 (of Register 12). Bits MA11 and MA10 of the address generated by the CRTC are not written on the address bus to access video memory; settings both bits to 1 is the only way to cause a carry to bit MA12 when address pass over the end of current video page to change the memory address to the next video page.&lt;br /&gt;
&lt;br /&gt;
== CRTC Differences ==&lt;br /&gt;
&lt;br /&gt;
In this section I will attempt to identify all the differences between each CRTC. &lt;br /&gt;
&lt;br /&gt;
The following tables list the functions that can be accessed for each type: &lt;br /&gt;
&lt;br /&gt;
Type 0&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''b1''||''b0''||''Function''||''Read/Write'' &lt;br /&gt;
|-&lt;br /&gt;
|0||0||Select internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|0||1||Write to selected internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|1||0||-||- &lt;br /&gt;
|-&lt;br /&gt;
|1||1||Read from selected internal 6845 register||Read only &lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Type 1&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''b1''||''b0''||''Function''||''Read/Write'' &lt;br /&gt;
|-&lt;br /&gt;
|0||0||Select internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|0||1||Write to selected internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|1||0||Read Status Register||Read Only &lt;br /&gt;
|-&lt;br /&gt;
|1||1||Read from selected internal 6845 register||Read only &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Type 2&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''b1''||''b0''||''Function''||''Read/Write'' &lt;br /&gt;
|-&lt;br /&gt;
|0||0||Select internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|0||1||Write to selected internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|1||0||-||- &lt;br /&gt;
|-&lt;br /&gt;
|1||1||Read from selected internal 6845 register||Read only &lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Type 3 and 4&lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|''b1''||''b0''||''Function''||''Read/Write'' &lt;br /&gt;
|-&lt;br /&gt;
|0||0||Select internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|0||1||Write to selected internal 6845 register||Write Only &lt;br /&gt;
|-&lt;br /&gt;
|1||0||Read from selected internal 6845 register||Read Only &lt;br /&gt;
|-&lt;br /&gt;
|1||1||Read from selected internal 6845 register||Read only &lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
It is not possible to read from all the internal registers, this table shows the read/write status of each register for each type: &lt;br /&gt;
&lt;br /&gt;
{|{{Prettytable|width: 700px; font-size: 2em;}}&lt;br /&gt;
|rowspan=2|''Register Index''||rowspan=2|''Register Name''||colspan=4|''Type'' &lt;br /&gt;
|-&lt;br /&gt;
|0||1||2||3||4&lt;br /&gt;
|-&lt;br /&gt;
|0||Horizontal Total||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|1||Horizontal Displayed||Write Only||Write Only||Write Only||(note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|2||Horizontal Sync Position||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|3||Horizontal and Vertical Sync Widths||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|4||Vertical Total||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|5||Vertical Total Adjust||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|6||Vertical Displayed||Write Only||Write Only||Write Only||(note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|7||Vertical Sync position||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|8||Interlace and Skew||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|9||Maximum Raster Address||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|10||Cursor Start Raster||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|11||Cursor End Raster||Write Only||Write Only||Write Only||(note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|12||Display Start Address (High)||Read/Write||Write Only||Write Only||Read/Write (note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|13||Display Start Address (Low)||Read/Write||Write Only||Write Only||Read/Write (note 2)||(note 3) &lt;br /&gt;
|-&lt;br /&gt;
|14||Cursor Address (High)||Read/Write||Read/Write||Read/Write||Read/Write (note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|15||Cursor Address (Low)||Read/Write||Read/Write||Read/Write||Read/Write (note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|16||Light Pen Address (High)||Read Only||Read Only||Read Only||Read Only (note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|17||Light Pen Address (Low)||Read Only||Read Only||Read Only||Read Only (note 2)||(note 3)&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
'''Notes'''&lt;br /&gt;
&lt;br /&gt;
1. On type 0 and 1, if a Write Only register is read from, &amp;quot;0&amp;quot; is returned. &lt;br /&gt;
&lt;br /&gt;
2. See the document &amp;quot;Extra CPC Plus Hardware Information&amp;quot; for more details.&lt;br /&gt;
&lt;br /&gt;
3. CRTC type 4 is the same as CRTC type 3. The registers also repeat as they do on the type 3.&lt;br /&gt;
&lt;br /&gt;
== Horizontal and Vertical Sync (R3) ==&lt;br /&gt;
&lt;br /&gt;
UM6845:&lt;br /&gt;
&lt;br /&gt;
Bits 7..4 define Vertical Sync Width. If 0 is programmed this gives 16 lines of VSYNC.&lt;br /&gt;
Bits 3..0 define Horizontal Sync Width. If 0 is programmed no HSYNC is generated.&lt;br /&gt;
&lt;br /&gt;
UM6845R:&lt;br /&gt;
&lt;br /&gt;
Bits 7..4 are ignored. Vertical Sync is fixed at 16 lines.&lt;br /&gt;
Bits 3..0 define Horizontal Sync Width. If 0 is programmed no HSYNC is generated.&lt;br /&gt;
&lt;br /&gt;
MC6845:&lt;br /&gt;
&lt;br /&gt;
Bits 7..4 are ignored. Vertical Sync is fixed at 16 lines.&lt;br /&gt;
Bits 3..0 define Horizontal Sync Width. If 0 is programmed this gives a HSYNC width of 16.&lt;br /&gt;
&lt;br /&gt;
Pre-ASIC/ASIC:&lt;br /&gt;
&lt;br /&gt;
Bits 7..4 define Vertical Sync Width. If 0 is programmed this gives 16 lines of VSYNC.&lt;br /&gt;
Bits 3..0 define Horizontal Sync Width. If 0 is programmed this gives a HSYNC width of 16.&lt;br /&gt;
&lt;br /&gt;
== UM6845R and R31 ==&lt;br /&gt;
&lt;br /&gt;
R31 is described in the UM6845R documentation as &amp;quot;Dummy Register&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Its use is described in the documentation for the Rockwell R6545 in combination with R18, R19 and R8 and the Status Register.&lt;br /&gt;
&lt;br /&gt;
In the UM6845R it appears to have no effect. Reading and writing does nothing. Reading it returns 0x0ff.&lt;br /&gt;
&lt;br /&gt;
R31 doesn't exist on types 0,2,3.&lt;br /&gt;
&lt;br /&gt;
== UM6845R and R12/R13 ==&lt;br /&gt;
&lt;br /&gt;
The UM6845R differs to other CRTC in respect of R12/R13. &lt;br /&gt;
&lt;br /&gt;
When VCC=0, R12/R13 is re-read at the start of each line. R12/R13 can therefore be changed for each scanline when VCC=0. &lt;br /&gt;
&lt;br /&gt;
Just like other CRTCs when RC==(R9-1), the current MA is captured for the next char-line.&lt;br /&gt;
&lt;br /&gt;
In demos to make a display compatible with all CRTCs program R12/R13 when VCC!=0. This will then take effect at the next frame start.&lt;br /&gt;
&lt;br /&gt;
== UM6845R status register ==&lt;br /&gt;
&lt;br /&gt;
The UM6845R has a status register that can be read using port &amp;amp;BExx.&lt;br /&gt;
&lt;br /&gt;
Bit 6 is set to 1 if there is a strobe input to the /LPEN signal. It is cleared to 0 when either R17 or R16 (LPEN address) of the CRTC are read. It signals there is a valid LPEN input. On my CPC (arnoldemu) with UM6845R, it is triggered at power on, R17 and R16 have the values 0 when read.&lt;br /&gt;
&lt;br /&gt;
Bit 5 is set to 1 when CRTC is in &amp;quot;vertical blanking&amp;quot;. Vertical blanking is when the vertical border is active. i.e. VCC&amp;gt;=R6. &lt;br /&gt;
&lt;br /&gt;
It is cleared when the frame is started (VCC=0). It is not directly related to the DISPTMG output (used by the CPC to display the border colour) because that output is a combination of horizontal and vertical blanking.&lt;br /&gt;
This bit will be 0 when pixels are being displayed.&lt;br /&gt;
&lt;br /&gt;
All the other bits read as 0 and don't have any function.&lt;br /&gt;
&lt;br /&gt;
== Datasheets ==&lt;br /&gt;
&lt;br /&gt;
* [[Media:hd6845.hitachi.pdf|HD6845S (Hitachi) (aka type 0)]]&lt;br /&gt;
* [[Media:Um6845.umc.pdf|UM6845 (UMC)  (aka type 0)]]&lt;br /&gt;
* [[Media:Um6845r.umc.pdf|UM6845R (UMC)  (aka type 1)]]&lt;br /&gt;
* [[Media:Mc6845.motorola.pdf|MC6845 (Motorola) (aka type 2)]]&lt;br /&gt;
&lt;br /&gt;
* [[VHDL implementation of the 6845]]&lt;br /&gt;
&lt;br /&gt;
== Clones ==&lt;br /&gt;
* [CM607P   a Bulgarian clone made in Pravetz factory]&lt;br /&gt;
* [EF6845P  by Thomson Semiconductors]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Tools about CRTC ==&lt;br /&gt;
&lt;br /&gt;
*  [http://www.cpcwiki.eu/imgs/9/99/Elmar_Krieger-SPECIAL_EFFECTS.dsk  some BASIC tools to detect CRTC types 0-1-2 and show some effects - by [[Elmar Krieger]] ]     (DSK for Emulators)&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
* [http://en.wikipedia.org/wiki/6845 Wikipedia on the CRTC]&lt;br /&gt;
* [http://www.grimware.org/doku.php/documentations/devices/crtc CRTCs on grimware]&lt;br /&gt;
* [http://logonsystem.fr/down/ACCC2-FR.pdf   Amstrad Cpc Crtc Compendium]     Latest (2021!!) document containing  in-depth info about CRTC programming on CPC.&lt;br /&gt;
&lt;br /&gt;
==Related pages==&lt;br /&gt;
&lt;br /&gt;
*[[Gate Array]]&lt;br /&gt;
&lt;br /&gt;
*[[ASIC]]&lt;br /&gt;
&lt;br /&gt;
*[[Video modes]]&lt;br /&gt;
&lt;br /&gt;
*[[Synchronising with the CRTC and display]] : technic and details on the relationship between Gate Array and CRTC.&lt;br /&gt;
&lt;br /&gt;
[[Category:Hardware]] [[Category:CPC Internal Components]] [[Category:Programming]] [[Category:Datasheet]] [[Category:Graphic]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Amazing_Demo&amp;diff=108370</id>
		<title>Amazing Demo</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Amazing_Demo&amp;diff=108370"/>
				<updated>2022-01-05T20:18:27Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* LATEST UPDATE IN 2021 !!! */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Amazing Demo''' was the first megademo created by [[Logon System]] and [[Malibu Crackers]]&lt;br /&gt;
All the part have been coded by [[Longshot]] and [[Naminu]] &lt;br /&gt;
&lt;br /&gt;
This demo was the first to use offset line-to-line splitting. The loader was ultra fast but many drives known problems with the special format used (see [[FDC]]. This demo has suffered too of [[CRTC]] compatibility problem. &lt;br /&gt;
&lt;br /&gt;
== LATEST UPDATE IN 2021 !!! ==&lt;br /&gt;
New bug-free version (Rev 2021) was released in November of 2021. Includes a new intro part.&lt;br /&gt;
https://demozoo.org/productions/302806/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;The different parts of Amazing Demo&amp;quot;&amp;gt;&lt;br /&gt;
Image:amazing02.gif&lt;br /&gt;
Image:amazing07.gif&lt;br /&gt;
Image:amazing03.gif&lt;br /&gt;
Image:amazingend.gif&lt;br /&gt;
Image:amazing04.gif&lt;br /&gt;
Image:amazing05.gif&lt;br /&gt;
Image:amazing01.gif&lt;br /&gt;
Image:amazing01b.gif&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
https://youtu.be/QzRHXuVNXTs&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Demos]]&lt;br /&gt;
[[Category:Year unknown]]&lt;br /&gt;
[[Category:Video contents]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Amazing_Demo&amp;diff=108369</id>
		<title>Amazing Demo</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Amazing_Demo&amp;diff=108369"/>
				<updated>2022-01-05T20:17:04Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Amazing Demo''' was the first megademo created by [[Logon System]] and [[Malibu Crackers]]&lt;br /&gt;
All the part have been coded by [[Longshot]] and [[Naminu]] &lt;br /&gt;
&lt;br /&gt;
This demo was the first to use offset line-to-line splitting. The loader was ultra fast but many drives known problems with the special format used (see [[FDC]]. This demo has suffered too of [[CRTC]] compatibility problem. &lt;br /&gt;
&lt;br /&gt;
== LATEST UPDATE IN 2021 !!! ==&lt;br /&gt;
New bug-free version (Rev 2021) was released in November of 2021. Includes an new intro part.&lt;br /&gt;
https://demozoo.org/productions/302806/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;The different parts of Amazing Demo&amp;quot;&amp;gt;&lt;br /&gt;
Image:amazing02.gif&lt;br /&gt;
Image:amazing07.gif&lt;br /&gt;
Image:amazing03.gif&lt;br /&gt;
Image:amazingend.gif&lt;br /&gt;
Image:amazing04.gif&lt;br /&gt;
Image:amazing05.gif&lt;br /&gt;
Image:amazing01.gif&lt;br /&gt;
Image:amazing01b.gif&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
https://youtu.be/QzRHXuVNXTs&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Demos]]&lt;br /&gt;
[[Category:Year unknown]]&lt;br /&gt;
[[Category:Video contents]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=DIY&amp;diff=103816</id>
		<title>DIY</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=DIY&amp;diff=103816"/>
				<updated>2019-11-11T20:20:45Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== DIY Hardware Projects ==&lt;br /&gt;
&lt;br /&gt;
Do-it-yourself (DIY) projects...&lt;br /&gt;
&lt;br /&gt;
=== Communication - RS232 / PC Connection ===&lt;br /&gt;
* [[AMSSIO|AMSSIO RS232 interface]]&lt;br /&gt;
* [[CPC Booster|RS232 and RS485 interface of the CPC Booster+]]&lt;br /&gt;
* [[CPCI RS232 Interface|CPCI RS232 Interface]]&lt;br /&gt;
* [[Z80 STI RS232 interface]]&lt;br /&gt;
* [[Z80-SIO dual ports RS232 interface for CPC (French)]]&lt;br /&gt;
&lt;br /&gt;
=== Floppy Drives  ===&lt;br /&gt;
&lt;br /&gt;
*[[ABBA switch]] (swap drive A: and B:) &lt;br /&gt;
*[[Adding 3.5&amp;quot; drive to CPC464]]&lt;br /&gt;
*[[Guide on how to connect a 3.5|Connecting a 3.5&amp;quot; drive to a CPC6128/664]] &lt;br /&gt;
*[[Guide on how to connect a 3.5|Connecting a 3.5&amp;quot; drive to a CPC6128/664 (with photos)]] &lt;br /&gt;
*[[Connecting a Disc Interface to CPC464+]] &lt;br /&gt;
*[[Modify PC floppy drives|Modify PC floppy drives to work on a CPC]] &lt;br /&gt;
*[[DDI Modification|Modify a DDI-1 for use with 3.5&amp;quot; Drives]] &lt;br /&gt;
*[[Side Select Switch]] (force AMSDOS to use Side B) &lt;br /&gt;
*[[Drive Compatibility]] &lt;br /&gt;
*[[DIY:Floppy_Drives|Floppy pinning and signal description, adapter cables]]&lt;br /&gt;
*[[Connect a 3 inch drive to a PC|How to connect a 3&amp;quot; CPC drive to a PC]]&lt;br /&gt;
*[[Side Select Switch - Alternative Method]]&lt;br /&gt;
&lt;br /&gt;
=== Cassette deck ===&lt;br /&gt;
*[[Adding an audio in mod for your 464]]   https://www.youtube.com/watch?v=5H56gcIA4cM&lt;br /&gt;
useful if you want to use an external source for tape-loading&lt;br /&gt;
&lt;br /&gt;
=== HID ===&lt;br /&gt;
* [[PS2Mouse|AMX Compatible PS/2 and USB Mouse Adapter]]&lt;br /&gt;
* [[Atari-ST mouse adapter]]&lt;br /&gt;
* [[CPCKey|Attaching an AT keyboard to the CPC]]&lt;br /&gt;
&lt;br /&gt;
=== Joysticks ===&lt;br /&gt;
* [[Joystick_Autofire|Joystick Autofire Circuit]]&lt;br /&gt;
* [[Joystick Y-cables|Joystick Y-cables]]&lt;br /&gt;
* [[Joystick_Splitter|Joystick Splitter Circuit]]&lt;br /&gt;
* [[PSX controller mod for Amstrad CPC|PSX controller mod for Amstrad CPC]]&lt;br /&gt;
&lt;br /&gt;
=== Mass Storage ===&lt;br /&gt;
* [[DIY_464_External_Audio_Socket|DIY Tape/CD Socket for CPC464]]&lt;br /&gt;
* [[DIY_Plus_Tape_Socket|DIY Tape Socket for CPC6128+]]&lt;br /&gt;
* [[HxC_SDCard_Internal|How To Build An Internal HxC SDCard Drive]]&lt;br /&gt;
* [[HxC_Floppy_Emulator|HxC Disc Emulator using PC as Storage Medium]]&lt;br /&gt;
* [[HxC_Standalone_Floppy_Emulator|HxC Disc Emulator using SDCard]]&lt;br /&gt;
* [[IDE8255|IDE8255 for IDE hard discs]]&lt;br /&gt;
* [[SDiskEmul|SD Card Disc Drive Emulator]]&lt;br /&gt;
* [[SYMBiFACE II|SYMBiFACE II for IDE hard discs]]&lt;br /&gt;
* [[X-MASS]] ([[TotO]])&lt;br /&gt;
* [[UIDE Universal IDE adapter cards for Z-80 computers]]&lt;br /&gt;
&lt;br /&gt;
=== Power Supply ===&lt;br /&gt;
* [[Powering a CPC 6128 from a Sinclar Spectrum +3 PSU|Powering a CPC 6128 from a Sinclar Spectrum +3 PSU]]&lt;br /&gt;
&lt;br /&gt;
=== Printer ===&lt;br /&gt;
* [[8bit Printer Ports]]&lt;br /&gt;
* [[Simple RS232 for Printer usage|Simple RS232 for Printer usage]]&lt;br /&gt;
* [[DB-25 Printer Port Adapter]]&lt;br /&gt;
&lt;br /&gt;
=== Real Time Clocks ===&lt;br /&gt;
* [[ACU_Real_Time_Clock_(DIY)|ACU Realtime Clock]] (without year counter)&lt;br /&gt;
* [[Real Time Clock|CPCI Real Time Clock]] (note: incomplete instructions / schematics due to low-resolution scans)&lt;br /&gt;
&lt;br /&gt;
=== ROM / RAM Expansions ===&lt;br /&gt;
* [[AcidInside|AcidInside - Internal ACID Socket]] (Bryce)&lt;br /&gt;
* [[ACU_Romboard_(DIY)|ACU Romboard]] (ACU)&lt;br /&gt;
* [[CPC4MB|CPC4MB - 4 MB memory expansion]] ([[Yarek]])&lt;br /&gt;
* [[DIY_Cartridge|DIY Plus Cartridge]] (Bryce)&lt;br /&gt;
* [[DualOS|Dual OS for CPC6128 using a 32K EPROM]] (Bryce)&lt;br /&gt;
* [[FlashGordon]] (MegaFlash clone with different Flash chip)&lt;br /&gt;
* [[Inicron RAM-Box|Inicron RAM-Box]] (Inicron)&lt;br /&gt;
* [[Inicron ROM-RAM-Box|Inicron ROM-RAM-Box]] (Inicron)&lt;br /&gt;
* [[LowerROM|LowerROM Board]] (Bryce)&lt;br /&gt;
* [[MITM|Man In The Middle Cartridge]] (Bryce)&lt;br /&gt;
* [[MegaROM|MegaROM]] (Bryce)&lt;br /&gt;
* [[MegaFlash|MegaFlash]] (Bryce)&lt;br /&gt;
* [[Multi_Cartridge|Multi-Cartridge]] (Bryce)&lt;br /&gt;
* [[Old School 512K RAM Expansion]] (Revaldinho) - 512K RAM expansion built with an SRAM and 74 Series standard logic&lt;br /&gt;
* [[Amstrad ROM Expander|Practical Electronics ROMBoard Project]] (Simon Dean)&lt;br /&gt;
* [[Ramcard 128]] ([[RAM7]])&lt;br /&gt;
* [[Upgrading a Dk'tronics RAM Expansion|Upgrading a Dk'tronics RAM Expansion]] (Bryce)&lt;br /&gt;
* [[X-MEM]] ([[TotO]])&lt;br /&gt;
* [[X-ROM]] ([[Timatic Systems]])&lt;br /&gt;
* [[Y-MEM]] ([[TotO]])&lt;br /&gt;
&lt;br /&gt;
=== Sound ===&lt;br /&gt;
* [[Digiblaster|Digiblaster Sound Card]] (8 bit DAC on printer port)&lt;br /&gt;
* [[FuturePlayer|FuturePlayer - MP3 Player]] (connected to printer port)&lt;br /&gt;
* [[PlayCity]] ([[TotO]])&lt;br /&gt;
* [[SP0256_on_Printer_Port_(DIY)|SP0256 Speech Synthesizer for Printer Port]]&lt;br /&gt;
&lt;br /&gt;
=== TV / Monitors ===&lt;br /&gt;
* [[Convert an MP1 into an MP2|Converting an MP1 into an MP2]]&lt;br /&gt;
* [[LCD And Plasma TV Solution|Getting a CPC to work with an LCD or plasma TV]]&lt;br /&gt;
* [[PCAI_Video_Texting_(DIY)|PCAI Video Modulator]]&lt;br /&gt;
* [[RGB_SVideo|RGB to S-Video Converter]]&lt;br /&gt;
* [[TV SCART cable|TV SCART cables]]&lt;br /&gt;
&lt;br /&gt;
=== Others ===&lt;br /&gt;
* [[6 MHz CPC]]&lt;br /&gt;
* [[Ambug|Ambug Robot]]&lt;br /&gt;
* [[Expanding from CPC 464 to CPC 6128 Spec]]&lt;br /&gt;
* [[464Plus Conversion|Converting a 464+ into a 6128+]]&lt;br /&gt;
* [[PCAI_A/D_Converter_(DIY)| PCAI Analogue to Digital Converter]]&lt;br /&gt;
* [[Schneiderware]] (a series of DIY projects that were released in [[CPC Schneider International]] magazine)&lt;br /&gt;
* [[Reset_Button|Reset Button]]&lt;br /&gt;
* [[Expansion Converter|UK/DE Expansion Converter]]&lt;br /&gt;
* [[Khany]] 's [[BankSwapper]] http://www.cpcwiki.eu/index.php/File:Khany%27s_BankSwapper.jpg&lt;br /&gt;
&lt;br /&gt;
== Hardware Repair ==&lt;br /&gt;
&lt;br /&gt;
* [[Changing the drive belt|Changing the drive belt]]&lt;br /&gt;
* [[Changing cassette deck belts|Changing cassette deck belts]]&lt;br /&gt;
* [[IC Repair|How to remove/replace an IC]]&lt;br /&gt;
* [[Keyboard Membrane Repair/Replacement Guide]]&lt;br /&gt;
* [[Joystick_Repair|A Guide To Repairing Digital Joysticks]]&lt;br /&gt;
* [[Writepin|Finding and Replacing the Floppy Write Pin]]&lt;br /&gt;
* Repair and service a disk drive in an Amstrad CPC 6128 video:  https://www.youtube.com/watch?v=tKZCbHqEX_k&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to's / Tutorials ==&lt;br /&gt;
&lt;br /&gt;
* [[A guide to running software on a real Amstrad CPC/CPC Plus computer|A Guide to running software on a real CPC!]] &lt;br /&gt;
* [[Transfering Alkatraz protected tapes and most games!|Transfering Alkatraz protected tapes and most games!]] &lt;br /&gt;
* [[Willem Programmer|Willem Programmer]] - how to program eproms using the Willem eprom programmer.&lt;br /&gt;
&lt;br /&gt;
[[Category:DIY| ]] [[Category:Hardware| ]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=ZACK&amp;diff=103611</id>
		<title>ZACK</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=ZACK&amp;diff=103611"/>
				<updated>2019-08-25T15:51:49Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Download */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
'''ZACK'''&lt;br /&gt;
is the ''ZAp-em-up Construction Kit'', an unfinished game creator software for the CPC. A unique and very promising package for people who wanted to create professional quality games easily. Written by Richard Wilson ([[Executioner|Executioner]]) in 1993.&lt;br /&gt;
According to the author himself: ''Everything got finished except the sound/FX and completed game loader/multi-load code.''&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Download ===&lt;br /&gt;
&lt;br /&gt;
You can download the unfinished version and sources of ZACK from author's [[WinApe|WINAPE]] site:&lt;br /&gt;
&lt;br /&gt;
* [http://winape.net/download/zack.zip  ZACK preview]  (Note: use |CPM to run. ParaDOS is required for second disk image.)&lt;br /&gt;
&lt;br /&gt;
* [http://winape.net/download/zackdev.zip  The complete source code for ZACK]    (ParaDOS is required due to 800k disk image.)&lt;br /&gt;
&lt;br /&gt;
* [https://www.cpc-power.com/index.php?page=detail&amp;amp;num=12647    latest &amp;amp; more complete DSK of ZACK v1.0 !!]&lt;br /&gt;
&lt;br /&gt;
=== Previews ===&lt;br /&gt;
[[image:Zack AA Preview.jpg|thumb|none|ZACK previewed in Amstrad Action issue 98]]&lt;br /&gt;
&lt;br /&gt;
=== ZACK Programming Language ===&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Commands&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
BACKGROUND (x,y) = value		Set a background tile&lt;br /&gt;
BACKGROUND COLLISION from[ .. to]	Test for background collision&lt;br /&gt;
BORDER ink				Set Border&lt;br /&gt;
BYTE var{ ,var}				Define Byte variable(s)&lt;br /&gt;
CLEAR SCREEN byte			Clear the screen&lt;br /&gt;
CONSOLE					Output on Console&lt;br /&gt;
CONST var = value{ ,var = value}	Define constant(s)&lt;br /&gt;
COPY LAYOUT x,y,width,height TO x,y	Copy a section of the Layout&lt;br /&gt;
COPY SPRITE n TO n			Copy a Sprite&lt;br /&gt;
DEC var					Decrement a variable&lt;br /&gt;
DEFINE var = value{ ,var = value}	Define constant(s) (Same as CONST)&lt;br /&gt;
DEFINE KEY key				Define a key&lt;br /&gt;
DEFINE MAIN TASK number			Define a Main Task&lt;br /&gt;
DEFINE MARKER TASK number		Define a Marker Task&lt;br /&gt;
DEFINE MOVE TASK number			Define a Move Task&lt;br /&gt;
DEFINE DRAW TASK number			Define a Draw Task&lt;br /&gt;
DRAW x,y[,pen]				Not implemented (Draw a line)&lt;br /&gt;
DRAW TASK number			Execute DRAW Task&lt;br /&gt;
ELSE					ELSE statement&lt;br /&gt;
ELSE IF expr				ELSE IF statement&lt;br /&gt;
ENDIF					End of IF statement&lt;br /&gt;
FLASH OBJECT				Flash the current Object&lt;br /&gt;
FOR var = start TO end[ STEP step]	For loop statement&lt;br /&gt;
GOTO line				GOTO statement&lt;br /&gt;
GOTO MARKER marker			Go to Layout Marker&lt;br /&gt;
HIDDEN SCREEN				Output on Hidden Screen&lt;br /&gt;
IF expr[ GOTO line]			IF or IF .. GOTO statement&lt;br /&gt;
INC var					Increment a variable&lt;br /&gt;
INK pen, ink				Set the given pen to palette colour&lt;br /&gt;
INPUT var[:width]			Assign user input to variable&lt;br /&gt;
INSERT HIGH position			Insert a High Score in the table&lt;br /&gt;
KILL number				Kill given Object&lt;br /&gt;
KILL ALL				Kill all Objects&lt;br /&gt;
LOCATE x,y				Position text cursor&lt;br /&gt;
MAIN TASK number			Execute MAIN Task&lt;br /&gt;
MOVE x,y				Move graphics position&lt;br /&gt;
MOVE OBJECT dx,dy[ SCROLL]		Move current Object (include scroll)&lt;br /&gt;
MOVE OBJECTS				Execute MOVE Tasks for all Objects&lt;br /&gt;
MOVE TASK number			Execute given MOVE Task&lt;br /&gt;
NEW OBJECT obj,part,x,y,mt[,dt[,v1..]]	Create a new Object (mt = Move Task, dt=Draw Task)&lt;br /&gt;
NEXT					Continue FOR loop&lt;br /&gt;
OBJECT COLLISION from[ .. to]		Check for collision with another Object&lt;br /&gt;
ORIGIN x,y				Change the output Origin&lt;br /&gt;
PAUSE delay[ KEY key]			Pause for given time (or until key pressed)&lt;br /&gt;
PLAY FX number				Not implemented (Play given Sound Effect)&lt;br /&gt;
PLAY TUNE number			Not implemented (Play given Tune)&lt;br /&gt;
PLOT x,y[,pen]				Not implemented (Plot a point)&lt;br /&gt;
PRINT [@x,y,]expr[:width]		Print value (at position, with given width)&lt;br /&gt;
REPEAT					Repeat loop statement&lt;br /&gt;
RESET var{ ,var}			Reset variable(s) to zero&lt;br /&gt;
RESET INKS				Reset palette to default???&lt;br /&gt;
RETURN					Return from a Task&lt;br /&gt;
SCORE var{, var}			Define a Score variable&lt;br /&gt;
SCREEN TYPE number			Set the screen format&lt;br /&gt;
SCROLL					Scroll the layout (if scrolling on)&lt;br /&gt;
SCROLL OFF				Turn automatic scrolling off&lt;br /&gt;
SCROLL ON				Turn automatic scrolling on&lt;br /&gt;
SHOW BACKGROUND				Show the background&lt;br /&gt;
SHOW KEY key				Show the label for the given key&lt;br /&gt;
SHOW MINI number			Show given Mini-Sprite at current position&lt;br /&gt;
SHOW OBJECT obj,part			Show an Object at current position&lt;br /&gt;
SHOW OBJECTS				Show all Objects&lt;br /&gt;
SHOW SCREEN				Show the hidden screen&lt;br /&gt;
SHOW SHOT number			Show Shot-Sprite at current position&lt;br /&gt;
SHOW SPRITE number			Draw a Sprite at the current position&lt;br /&gt;
STOP FX					Not implemented (Stop Sound Effect)&lt;br /&gt;
STOP TUNE				Not implemented (Stop Tune playing)&lt;br /&gt;
STRING var{ ,var}			Define a String variable&lt;br /&gt;
SWAP SPRITE number,number		Swap two sprites&lt;br /&gt;
UNTIL expr				End of REPEAT..UNTIL loop&lt;br /&gt;
VISIBLE SCREEN				Output on the Visible Screen&lt;br /&gt;
WEND					End of WHILE loop&lt;br /&gt;
WHILE expr				WHILE loop statement&lt;br /&gt;
WINDOW x,y,width,height			Define a window for output&lt;br /&gt;
WORD var{ ,var}				Define a Word variable&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Some of these commands may not be fully implemented.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;Functions&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ABS expr				Absolute value&lt;br /&gt;
BACKGROUND (x, y)			Background tile (x and y in bytes)&lt;br /&gt;
DIR obj					Direction of another object (0..7)&lt;br /&gt;
INKEY key				Test a key&lt;br /&gt;
MAX (value1{, valuen})			Maximum of values&lt;br /&gt;
MIN (value1{, valuen})			Minimum of values&lt;br /&gt;
NOT expr				Logical NOT&lt;br /&gt;
RND					Random Word&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;b&amp;gt;System variables&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
marker				Byte	Current layout marker number&lt;br /&gt;
scroll_type			Byte	Current scroll type (automatic?)&lt;br /&gt;
x_scrl				Byte	Current horizontal scroll direction&lt;br /&gt;
y_scrl				Byte	Current vertical scroll direction&lt;br /&gt;
mk_task				Byte	Task for current marker&lt;br /&gt;
m1 .. m8			Byte	Marker variables&lt;br /&gt;
&lt;br /&gt;
lay_x				Word	Layout X position&lt;br /&gt;
lay_y				Word	Layout Y position&lt;br /&gt;
par_x				Word	Parallax X position&lt;br /&gt;
par_y				Word	Parallax Y position&lt;br /&gt;
&lt;br /&gt;
object				Byte	Object number of current object&lt;br /&gt;
part				Byte	Part of current object (0 .. 11)&lt;br /&gt;
mv_task				Byte	Task to move object&lt;br /&gt;
dr_task				Byte	Task to draw object&lt;br /&gt;
x				Word	X position of object&lt;br /&gt;
y				Word	Y position of object&lt;br /&gt;
v1 .. v8			Byte	Object variables&lt;br /&gt;
priority			Byte	Priority of object&lt;br /&gt;
&lt;br /&gt;
y_pos				Byte	Y co-ordinate from LOCATE&lt;br /&gt;
x_pos				Byte	X co-ordinate from LOCATE&lt;br /&gt;
&lt;br /&gt;
case				Byte	CAPS LOCK state&lt;br /&gt;
ctrl_shift			Byte	Shift and CONTROL state&lt;br /&gt;
text_mode			Byte	Text output mode&lt;br /&gt;
intno				Byte	Current interrupt in frame (0 .. 5)&lt;br /&gt;
screen_type			Byte	Current screen type&lt;br /&gt;
flash_mask			Byte	Mask for flashing objects&lt;br /&gt;
&lt;br /&gt;
win_y				Byte	Window Y of top left&lt;br /&gt;
win_x				Byte	Window X of top left&lt;br /&gt;
win_h				Byte	Height of window&lt;br /&gt;
win_w				Byte	Width of window&lt;br /&gt;
org_y				Byte	Window Y origin&lt;br /&gt;
org_x				Byte	Window X origin&lt;br /&gt;
&lt;br /&gt;
current				Byte	Current object reference&lt;br /&gt;
parent				Byte	Current parent object reference&lt;br /&gt;
main_pty			Byte	Priority of objects from tasks&lt;br /&gt;
back_pty			Byte	Priority of objects from layout&lt;br /&gt;
new_pty				Byte	Priority of next object&lt;br /&gt;
num_obj				Byte	Number of objects&lt;br /&gt;
hit				Byte	Collision object reference&lt;br /&gt;
escape				Byte	Disable/Enable the Escape key&lt;br /&gt;
&lt;br /&gt;
high		10		Score	Array of high scores&lt;br /&gt;
name		10		String	Array of names for high scores&lt;br /&gt;
high_pos			Byte	Position from INSERT HIGH command&lt;br /&gt;
mask		16		Byte	Array of byte masks for each ink&lt;br /&gt;
sequence	?		Byte	Background sequence array&lt;br /&gt;
&lt;br /&gt;
.object				Byte	Parent object number&lt;br /&gt;
.part				Byte	Parent part&lt;br /&gt;
.mv_task			Byte	Parent Move Task&lt;br /&gt;
.dr_task			Byte	Parent Draw Task&lt;br /&gt;
.x				Word	Parent X location&lt;br /&gt;
.y				Word	Parent Y location&lt;br /&gt;
.v1 .. .v8			Byte	Parent object variables&lt;br /&gt;
&amp;lt;/pre&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Below is an example ZACK program:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
      WORD mky,dots,w1,w2&lt;br /&gt;
      BYTE pills,stage,m,power&lt;br /&gt;
&lt;br /&gt;
      PAUSE 10&lt;br /&gt;
&lt;br /&gt;
      SCREEN TYPE 1&lt;br /&gt;
      MAIN TASK 1&lt;br /&gt;
&lt;br /&gt;
      DEFINE MAIN TASK 1&lt;br /&gt;
&lt;br /&gt;
0     stage = 1&lt;br /&gt;
      m = 0&lt;br /&gt;
1     KILL ALL&lt;br /&gt;
      NEW OBJECT 1,28,48,0,0,-2&lt;br /&gt;
      INC m&lt;br /&gt;
      GOTO MARKER m&lt;br /&gt;
      mky = lay_y-184&lt;br /&gt;
      COPY LAYOUT 256,mky,32,14 TO 0,mky&lt;br /&gt;
&lt;br /&gt;
      x = 24&lt;br /&gt;
      y = 0&lt;br /&gt;
      FOR v1 = 0 TO m2&lt;br /&gt;
      NEW OBJECT 4,x+24,-16,y,1,2,0,0,1,0,0,0,lay_x+x,lay_y-16&lt;br /&gt;
      x = x+2&lt;br /&gt;
      y = y+4&lt;br /&gt;
      IF y=12&lt;br /&gt;
      y = 0&lt;br /&gt;
      ENDIF&lt;br /&gt;
      NEXT&lt;br /&gt;
&lt;br /&gt;
      MAIN TASK 2&lt;br /&gt;
      MAIN TASK 3&lt;br /&gt;
&lt;br /&gt;
      WHILE dots&lt;br /&gt;
      HIDDEN SCREEN&lt;br /&gt;
      SHOW BACKGROUND&lt;br /&gt;
      SHOW OBJECTS&lt;br /&gt;
      SHOW SCREEN&lt;br /&gt;
      CONSOLE&lt;br /&gt;
      MOVE OBJECTS&lt;br /&gt;
      COPY SPRITE 15 TO 35&lt;br /&gt;
      COPY SPRITE 34 TO 15&lt;br /&gt;
      COPY SPRITE 33 TO 34&lt;br /&gt;
      COPY SPRITE 32 TO 33&lt;br /&gt;
      COPY SPRITE 35 TO 32&lt;br /&gt;
      IF INKEY 38&lt;br /&gt;
      MAIN TASK 2&lt;br /&gt;
      ENDIF&lt;br /&gt;
      WEND&lt;br /&gt;
      INC stage&lt;br /&gt;
      IF m1 GOTO 1&lt;br /&gt;
      GOTO 0&lt;br /&gt;
&lt;br /&gt;
      DEFINE MAIN TASK 2&lt;br /&gt;
&lt;br /&gt;
      HIDDEN SCREEN&lt;br /&gt;
      CLEAR SCREEN 0&lt;br /&gt;
      PRINT @11,0,&amp;quot;PAC ATTACK&amp;quot;&lt;br /&gt;
      PRINT @12,2,&amp;quot;Stage&amp;quot;&lt;br /&gt;
      PRINT @18,2,stage:2&lt;br /&gt;
      v2 = 32&lt;br /&gt;
      RESET dots,pills&lt;br /&gt;
      FOR w2 = mky TO mky+448 STEP 32&lt;br /&gt;
      FOR w1 = 32 TO 280 STEP 8&lt;br /&gt;
      v1 = BACKGROUND (w1,w2)&lt;br /&gt;
      MOVE w1/8+12,v2&lt;br /&gt;
      IF v1=0&lt;br /&gt;
      v3 = 1&lt;br /&gt;
      ELSE IF v1&amp;lt;15&lt;br /&gt;
      v3 = 2&lt;br /&gt;
      ELSE IF v1&amp;lt;18&lt;br /&gt;
      v3 = v1-12&lt;br /&gt;
      ELSE&lt;br /&gt;
      v3 = 0&lt;br /&gt;
      ENDIF&lt;br /&gt;
      SHOW SHOT v3&lt;br /&gt;
      IF v1=16&lt;br /&gt;
      INC dots&lt;br /&gt;
      ELSE IF v1=17&lt;br /&gt;
      INC pills&lt;br /&gt;
      ENDIF&lt;br /&gt;
      NEXT&lt;br /&gt;
      v2 = v2+4&lt;br /&gt;
      NEXT&lt;br /&gt;
      PRINT @10,13,&amp;quot;Dots  :&amp;quot;&lt;br /&gt;
      PRINT @17,13,dots:4&lt;br /&gt;
      PRINT @10,15,&amp;quot;Pills :&amp;quot;&lt;br /&gt;
      PRINT @17,15,pills:4&lt;br /&gt;
      SHOW SCREEN&lt;br /&gt;
      REPEAT&lt;br /&gt;
      UNTIL INKEY 47&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
      DEFINE MAIN TASK 3&lt;br /&gt;
&lt;br /&gt;
      BYTE c1,c2,i1[5],i2[5]&lt;br /&gt;
      DEFINE i1[1]=3,i1[2]=2,i1[4]=6,i1[5]=13&lt;br /&gt;
      DEFINE i2[1]=3,i2[2]=2,i2[3]=4,i2[4]=0,i2[5]=13&lt;br /&gt;
      CONSOLE&lt;br /&gt;
&lt;br /&gt;
      v2 = 1&lt;br /&gt;
      FOR w2 = mky TO mky+448 STEP 32&lt;br /&gt;
      v4 = 1&lt;br /&gt;
      FOR w1 = 32 TO 280 STEP 8&lt;br /&gt;
      v1 = BACKGROUND (w1,w2)&lt;br /&gt;
      IF v1=0&lt;br /&gt;
      v3 = 1&lt;br /&gt;
      ELSE IF v1&amp;lt;15&lt;br /&gt;
      v3 = 2&lt;br /&gt;
      ELSE IF v1&amp;lt;18&lt;br /&gt;
      v3 = v1-12&lt;br /&gt;
      ELSE&lt;br /&gt;
      v3 = 0&lt;br /&gt;
      ENDIF&lt;br /&gt;
      c1 = i1[v3]&lt;br /&gt;
      c2 = i2[v3]&lt;br /&gt;
      PLOT v4,v2,mask[c1]&lt;br /&gt;
      PLOT v4,v2+1,mask[c2]&lt;br /&gt;
      i1[4] = i1[4] XOR 3&lt;br /&gt;
      INC v4&lt;br /&gt;
      NEXT&lt;br /&gt;
      v2 = v2+2&lt;br /&gt;
      NEXT&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
      DEFINE MOVE TASK 0&lt;br /&gt;
&lt;br /&gt;
      power = 0&lt;br /&gt;
      w1 = lay_x+28&lt;br /&gt;
      w2 = lay_y+48&lt;br /&gt;
      IF NOT ((w1 AND 7) OR (w2 AND 31))&lt;br /&gt;
      v6 = BACKGROUND (w1+v1*4,w2+v2*4)&lt;br /&gt;
      IF v6&amp;lt;16&lt;br /&gt;
      v1 = 0&lt;br /&gt;
      v2 = 0&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      IF (lay_y AND 31)=16&lt;br /&gt;
      IF v1&amp;lt;2 AND INKEY 63&lt;br /&gt;
      v6 = BACKGROUND (w1+8,w2)&lt;br /&gt;
      IF v6&amp;gt;15&lt;br /&gt;
      v1 = 2&lt;br /&gt;
      v2 = 0&lt;br /&gt;
      object = 0&lt;br /&gt;
      GOTO 1&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ELSE IF v1&amp;gt;-2 AND INKEY 71&lt;br /&gt;
      v6 = BACKGROUND (w1-1,w2)&lt;br /&gt;
      IF v6&amp;gt;15&lt;br /&gt;
      v1 = -2&lt;br /&gt;
      v2 = 0&lt;br /&gt;
      object = 1&lt;br /&gt;
      GOTO 1&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      IF (lay_x AND 7)=4&lt;br /&gt;
      IF v2&amp;lt;8 AND INKEY 22&lt;br /&gt;
      v6 = BACKGROUND (w1,w2+32)&lt;br /&gt;
      IF v6&amp;gt;15&lt;br /&gt;
      v1 = 0&lt;br /&gt;
      v2 = 8&lt;br /&gt;
      object = 3&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ELSE IF v2&amp;gt;-8 AND INKEY 19&lt;br /&gt;
      v6 = BACKGROUND (w1,w2-32)&lt;br /&gt;
      IF v6&amp;gt;15&lt;br /&gt;
      v1 = 0&lt;br /&gt;
      v2 = -8&lt;br /&gt;
      object = 2&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
1     lay_x = (lay_x+v1) AND 255&lt;br /&gt;
      lay_y = lay_y+v2&lt;br /&gt;
      IF NOT ((w1 AND 7) OR (w2 AND 31))&lt;br /&gt;
      v6 = BACKGROUND (w1,w2)&lt;br /&gt;
      IF v6=16 OR v6=17&lt;br /&gt;
      IF v6=16&lt;br /&gt;
      DEC dots&lt;br /&gt;
      ELSE&lt;br /&gt;
      power = 1&lt;br /&gt;
      ENDIF&lt;br /&gt;
      BACKGROUND (w1,w2) = 63&lt;br /&gt;
      v4 = w1/8-3&lt;br /&gt;
      v5 = ((w2-mky+32) AND &amp;amp;FFE0)/16+1&lt;br /&gt;
      PLOT v4,v5,0&lt;br /&gt;
      PLOT v4,v5+1,0&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      IF v1 OR v2&lt;br /&gt;
      part = (part+1) MOD 6&lt;br /&gt;
      ENDIF&lt;br /&gt;
      OBJECT COLLISION 4&lt;br /&gt;
      IF hit&lt;br /&gt;
      BORDER 26&lt;br /&gt;
      ENDIF&lt;br /&gt;
&lt;br /&gt;
      DEFINE MOVE TASK 1&lt;br /&gt;
&lt;br /&gt;
      BYTE a,b,d[4],adx[3],ady[3]&lt;br /&gt;
      DEFINE adx[1]=8,adx[3]=-8&lt;br /&gt;
      DEFINE ady[0]=-32,ady[2]=32&lt;br /&gt;
&lt;br /&gt;
      IF power&lt;br /&gt;
      v3 = 255&lt;br /&gt;
      IF object=4&lt;br /&gt;
      object = 5&lt;br /&gt;
      v1 = -v1&lt;br /&gt;
      v2 = -v2&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
&lt;br /&gt;
      IF v3&lt;br /&gt;
      DEC v3&lt;br /&gt;
      ELSE&lt;br /&gt;
      object = 4&lt;br /&gt;
      ENDIF&lt;br /&gt;
&lt;br /&gt;
      IF NOT ((w1 AND 7) OR (w2 AND 31))&lt;br /&gt;
      v6 = BACKGROUND (w1+v1*4,w2+v2*4)&lt;br /&gt;
      IF v1&amp;lt;&amp;gt;0&lt;br /&gt;
      a = BACKGROUND (w1,w2-32)&lt;br /&gt;
      b = BACKGROUND (w1,w2+32)&lt;br /&gt;
      ELSE&lt;br /&gt;
      a = BACKGROUND (w1-8,w2)&lt;br /&gt;
      b = BACKGROUND (w1+8,w2)&lt;br /&gt;
      ENDIF&lt;br /&gt;
      IF v6&amp;lt;16 OR (a&amp;gt;15) OR (b&amp;gt;15)&lt;br /&gt;
      a = DIR (1)/2&lt;br /&gt;
      IF v3&lt;br /&gt;
      a = a XOR 2&lt;br /&gt;
      ENDIF&lt;br /&gt;
      IF a=(v4 XOR 2)&lt;br /&gt;
      d[3] = a&lt;br /&gt;
      b = 0&lt;br /&gt;
      ELSE&lt;br /&gt;
      d[0] = a&lt;br /&gt;
      b = 1&lt;br /&gt;
      ENDIF&lt;br /&gt;
      a = RND AND 3&lt;br /&gt;
      IF a=(v4 XOR 2)&lt;br /&gt;
      a = (a+1) AND 3&lt;br /&gt;
      ENDIF&lt;br /&gt;
      FOR v4 = b TO b+2&lt;br /&gt;
      d[v4] = a&lt;br /&gt;
      a = (a+1) AND 3&lt;br /&gt;
      NEXT&lt;br /&gt;
      d[4] = a&lt;br /&gt;
      a = 0&lt;br /&gt;
      GOTO 2&lt;br /&gt;
1     INC a&lt;br /&gt;
      IF a&amp;gt;4&lt;br /&gt;
      PAUSE 100&lt;br /&gt;
      ENDIF&lt;br /&gt;
2     v4 = d[a]&lt;br /&gt;
      v6 = BACKGROUND (w1+adx[v4],w2+ady[v4])&lt;br /&gt;
      IF v6&amp;lt;15 OR (v6=15 AND ((v4&amp;lt;&amp;gt;0) OR (RND AND 7))) GOTO 1&lt;br /&gt;
      v1 = adx[v4]/4&lt;br /&gt;
      v2 = ady[v4]/4&lt;br /&gt;
      ENDIF&lt;br /&gt;
      ENDIF&lt;br /&gt;
      w1 = w1+v1&lt;br /&gt;
      w2 = w2+v2&lt;br /&gt;
&lt;br /&gt;
      x = MAX (MIN (w1-lay_x,72),-16)&lt;br /&gt;
      y = MAX (MIN (w2-lay_y,160),-64)&lt;br /&gt;
      part = (part AND 12)+((part+1) AND 3)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[User:Executioner|Executioner]] 09:48, 5 September 2006 (CEST)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming software]]&lt;br /&gt;
[[Category:Applications]]&lt;br /&gt;
[[Category:Vaporware]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102507</id>
		<title>Programming:Calculating xpos,ypos to screen address in assembly</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102507"/>
				<updated>2018-12-25T11:53:36Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== Calculating xpos,ypos to screen address ==&lt;br /&gt;
&lt;br /&gt;
The screen address at a given x,y position can be calculated as such:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
;; screenaddr = screenbase + (y AND 7)*&amp;amp;800 + int(y/8)*2*R1 + int(x/M)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
where:&lt;br /&gt;
x and y your 2D coordinates&lt;br /&gt;
&lt;br /&gt;
R1 = value of CRTC register 1 (eg. 40 with the default firmware settings)&lt;br /&gt;
&lt;br /&gt;
M = 2 (for screen mode 0, 2 pixels/byte)&lt;br /&gt;
M = 4 (for screen mode 1, 4 pixels/byte)&lt;br /&gt;
M = 8 (for screen mode 2, 8 pixels/byte)&lt;br /&gt;
&lt;br /&gt;
screenbase = &amp;amp;C000&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=102506</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=102506"/>
				<updated>2018-12-25T11:49:23Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
*[[A little optimization for Z80 Assembler]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Maze generation|Maze generation]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:Read/Write a file quickly byte-by-byte|Read or write a file quickly byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Games ==&lt;br /&gt;
*[[Programming:Coding a simple BASIC game into Assembly]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
*[[Programming:Calculating xpos,ypos to screen address in assembly|Calculating xpos,ypos to screen address]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Fastest_Character_Print_in_Mode_2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
*[[Programming:Storing and Retrieving Screens from the extra 64kb|Storing and Retrieving Screens from the extra 64kb]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102505</id>
		<title>Programming:Calculating xpos,ypos to screen address in assembly</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102505"/>
				<updated>2018-12-25T11:48:14Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Calculating xpos,ypos to screen address ==&lt;br /&gt;
&lt;br /&gt;
The screen address at a given x,y position can be calculated as such:&lt;br /&gt;
&lt;br /&gt;
[pre]&lt;br /&gt;
&lt;br /&gt;
screenaddr = screenbase + (y AND 7)*&amp;amp;800 + int(y/8)*2*R1 + int(x/M)&lt;br /&gt;
&lt;br /&gt;
[/pre]&lt;br /&gt;
&lt;br /&gt;
where:&lt;br /&gt;
x and y your 2D coordinates&lt;br /&gt;
&lt;br /&gt;
R1 = value of CRTC register 1 (eg. 40 with the default firmware settings)&lt;br /&gt;
&lt;br /&gt;
M = 2 (for screen mode 0, 2 pixels/byte)&lt;br /&gt;
M = 4 (for screen mode 1, 4 pixels/byte)&lt;br /&gt;
M = 8 (for screen mode 2, 8 pixels/byte)&lt;br /&gt;
&lt;br /&gt;
screenbase = &amp;amp;C000&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102504</id>
		<title>Programming:Calculating xpos,ypos to screen address in assembly</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102504"/>
				<updated>2018-12-25T11:45:41Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Calculating xpos,ypos to screen address in assembly ==&lt;br /&gt;
&lt;br /&gt;
The screen address at a given x,y position can be calculated as such:&lt;br /&gt;
&lt;br /&gt;
[pre]&lt;br /&gt;
&lt;br /&gt;
screenaddr = screenbase + (y AND 7)*&amp;amp;800 + int(y/8)*2*R1 + int(x/M)&lt;br /&gt;
&lt;br /&gt;
[/pre]&lt;br /&gt;
&lt;br /&gt;
where:&lt;br /&gt;
x and y your 2D coordinates&lt;br /&gt;
&lt;br /&gt;
R1 = value of CRTC register 1 (eg. 40 with the default firmware settings)&lt;br /&gt;
&lt;br /&gt;
M = 2 (for screen mode 0, 2 pixels/byte)&lt;br /&gt;
M = 4 (for screen mode 1, 4 pixels/byte)&lt;br /&gt;
M = 8 (for screen mode 2, 8 pixels/byte)&lt;br /&gt;
&lt;br /&gt;
screenbase = &amp;amp;C000&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102503</id>
		<title>Programming:Calculating xpos,ypos to screen address in assembly</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Calculating_xpos,ypos_to_screen_address_in_assembly&amp;diff=102503"/>
				<updated>2018-12-25T11:44:40Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Created page with &amp;quot;== Calculating xpos,ypos to screen address in assembly ==  The screen address at a given x,y position can be calculated as such:  [pre]  screenaddr = screenbase + (y AND 7)*&amp;amp;8...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Calculating xpos,ypos to screen address in assembly ==&lt;br /&gt;
&lt;br /&gt;
The screen address at a given x,y position can be calculated as such:&lt;br /&gt;
&lt;br /&gt;
[pre]&lt;br /&gt;
&lt;br /&gt;
screenaddr = screenbase + (y AND 7)*&amp;amp;800 + int(y/8)*2*R1 + int(x/M)&lt;br /&gt;
&lt;br /&gt;
[/pre]&lt;br /&gt;
&lt;br /&gt;
where:&lt;br /&gt;
x and y your 2D coordinates&lt;br /&gt;
&lt;br /&gt;
R1 = value of CRTC register 1 (eg. 40 with the default firmware settings)&lt;br /&gt;
&lt;br /&gt;
M = 2 (for screen mode 0, 2 pixels/byte)&lt;br /&gt;
M = 4 (for screen mode 1, 4 pixels/byte)&lt;br /&gt;
M = 8 (for screen mode 2, 8 pixels/byte)&lt;br /&gt;
&lt;br /&gt;
screenbase = &amp;amp;C000&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=102502</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=102502"/>
				<updated>2018-12-25T11:39:24Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
*[[A little optimization for Z80 Assembler]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Maze generation|Maze generation]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:Read/Write a file quickly byte-by-byte|Read or write a file quickly byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Games ==&lt;br /&gt;
*[[Programming:Coding a simple BASIC game into Assembly]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
&lt;br /&gt;
*[[Programming:Calculating xpos,ypos to screen address in assembly|Calculating xpos,ypos to screen address in assembly]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Fastest_Character_Print_in_Mode_2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
*[[Programming:Storing and Retrieving Screens from the extra 64kb|Storing and Retrieving Screens from the extra 64kb]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Plus&amp;diff=101828</id>
		<title>Plus</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Plus&amp;diff=101828"/>
				<updated>2018-05-14T06:42:53Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Accessing the Plus hardware improvements */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction to the Plus range == &lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery align=&amp;quot;right&amp;quot;&amp;gt;&lt;br /&gt;
image:6128plus_es.jpg|Spanish Amstrad 6128 Plus&lt;br /&gt;
image:6128plus_fr_en_kanga.jpg|Custom Airbrushed 6128 Plus&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In 1990 Amstrad introduced the &amp;quot;Plus&amp;quot; range which tweaked the hardware in many ways and added a cartridge slot to all models.  The Plus included the 464 Plus, 6128 Plus and the GX4000 video game console (which is a cut down Plus without the keyboard nor support for non-cartridge media). All of the range included a cartridge slot and additional hardware improvements.&lt;br /&gt;
&lt;br /&gt;
Most improvements were to the video display which saw an increase in palette to 4096 colours and gained the capability of hardware sprites. Splitting the display into two separate windows and pixel scrolling both became full supported hardware features although both were possible on the non-&amp;quot;Plus&amp;quot; hardware using clever programming of the existing Motorola 6845. An automatic DMA transfer system for feeding the sound chip was also added but the sound chip itself remained unchanged. Additionally, the BASIC command set for disc access was improved.&lt;br /&gt;
&lt;br /&gt;
These models did not do very well in the marketplace, failing to attract any substantial third party support. The 8-bit technology behind the Plus was starting to look a little out of date by 1990 and users resented the substantial price hike for cartridge games compared to their tape and disc counterparts.  However, the Plus machines did sell well in France where Amstrad still had a large following due to the success of the classic CPC range there.&lt;br /&gt;
&lt;br /&gt;
The range was officially titled as 'Amstrad 464 Plus', 'Amstrad 6128 Plus' and 'GX4000' and the 'CPC' (standing for Colour Personal Computer) abbreviation used in the older generation was dropped.  However, many Amstrad users refer to the Plus range as 'CPC Plus' or 'CPC+' due to the inherent similarities of the two ranges.&lt;br /&gt;
&lt;br /&gt;
Klick to see the PCB of the 6128 Plus [[Mainboard Versions]]&lt;br /&gt;
&lt;br /&gt;
== The GX4000 Games Console ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery align=&amp;quot;right&amp;quot;&amp;gt;&lt;br /&gt;
Image:Gx4000.jpg|Amstrad GX4000&lt;br /&gt;
Image:Amstrad-GX4000-Console-Set.jpg|Amstrad GX4000&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The GX4000 is a game console based on a 6128 Plus without a floppy controller or keyboard (although it is actually possible to modify one, add a floppy controller and a keyboard and use it as a Plus). It was delivered with two game paddles (as the ones delivered with the Plus models) and Burnin' Rubber on [[GX4000 cartridge|cartridge]] (without BASIC).&lt;br /&gt;
&lt;br /&gt;
The GX4000 was [[Amstrad]]'s attempt to gain some share in the home game console market, then dominated by the likes of Nintendo and Sega. Like others before it, and like others after it, it failed abysmally in its goal. Despite the fact that the hardware was decent (after all the CPC+ series were some of the very best 8-bit computers ever designed), it was a case of 'too little, too late'. Lack of CPC+ specific software, lack of marketing effort and bad timing meant that Amstrad's adventure in the home market was about to end.&lt;br /&gt;
&lt;br /&gt;
=== GX4000 differences compared to 464 or 6128 Plus ===&lt;br /&gt;
&lt;br /&gt;
* The master clock is 39.9Mhz (approx) instead of 40Mhz for the 464/6128 Plus. The Arnold V specification indicates this is to give a better picture. This means the GX4000 is 0.25% slower than a 464 or 6128 Plus but should have a better picture.&lt;br /&gt;
&lt;br /&gt;
* The pause button on the GX4000 is mapped to the P button on the CPC keyboard. Other than this the 2 digital joysticks are connected, all other keys are not connected.&lt;br /&gt;
&lt;br /&gt;
* There is a difference in the wiring schematics on the ADC inputs where the ASIC senses the computer configuration.&lt;br /&gt;
&lt;br /&gt;
* The following are not connected on GX4000 so the associated inputs are not defined (possibly high):&lt;br /&gt;
    * Printer (data and strobe)&lt;br /&gt;
    * Keyboard lines 0,1,2,4,5,7,8&lt;br /&gt;
    * FDC&lt;br /&gt;
    * FDD motor&lt;br /&gt;
    * Cassette read, write, motor&lt;br /&gt;
    * The signals /ROMEN, ROMDIS, /RAMRD, RAMDIS, CRTC CURSOR, EXP, Printer BUSY&lt;br /&gt;
&lt;br /&gt;
* When a system cartridge is inserted (this has been verified with a yellow and a green labelled system cartridge), the copyright message and a Ready prompt is displayed. If the fire buttons or directions are pressed on the first digital joystick you see X,Z and the arrows displayed, the same as if you had pressed these buttons on a 464/6128 Plus or CPC. Pressing Pause displays &amp;quot;P&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Accessing the Plus hardware improvements ==&lt;br /&gt;
&lt;br /&gt;
'''The Plus''' and GX4000 cartridges access the Plus hardware improvements, but specific software can be created using the extra features without the need of cartridge hardware (contrary as it was claimed by Amstrad in 1991). The extra features are not locked by a hardware mechanism but only by a special 17 bytes-length sequence send to the CRTC. So, it's possible for everyone to create his/her own software on the Plus, using the extra features available through a [[ASIC]] I/O page. Except the extra-features, the 464 and 6128 Plus machines are almost fully compatible with the classic CPC generation. Some minor differences are noticeable in the components ([[8255|PPI]], [[CRTC]], [[Gate Array]]) contained in the ASIC and in the interrupt mechanism in vectorised mode.&lt;br /&gt;
&lt;br /&gt;
For details about the Plus/GX4000 hardware features, see [[Arnold V Specs Revised]].&lt;br /&gt;
&lt;br /&gt;
== Software ==&lt;br /&gt;
&lt;br /&gt;
=== System Cartridges ===&lt;br /&gt;
&lt;br /&gt;
See [[Plus System Cartridge]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Pure CPC Plus demos  ===&lt;br /&gt;
&lt;br /&gt;
*[[4096 Preview|4096 Preview]] ([[Kevin Thacker|Kevin Thacker]]) &lt;br /&gt;
*[[Allergy|Allergy]] by [[Semilanceata|Semilanceata]] &lt;br /&gt;
*[[ASM Intro 1|ASM Intro 1]] by [[Roudoudou|Roudoudou]] of [[Flower corp|Flower corp]] &lt;br /&gt;
*[[Basic Demo 3|Basic Demo 3]] by [[Roudoudou|Roudoudou]] of [[Flower corp|Flower corp]] &lt;br /&gt;
*[[Black Sabbath|Black Sabbath]] by [[BDC-Iron|BDC-Iron]] &lt;br /&gt;
*[[Blob Demo]] by [[Redbox]]&lt;br /&gt;
*[[CPC+ Desktop|CPC+ Desktop]] by [[Odiesoft|Odiesoft]] &lt;br /&gt;
*[[Demo Plus|Demo Plus]] ([[GPA|GPA]]) &lt;br /&gt;
*[[Diamonds|Diamonds]] ([[ZilogMonkey|ZilogMonkey]]) &lt;br /&gt;
*[[DMA music demo|DMA music demo]] ([[Cadjo Clan|Cadjo Clan]]) &lt;br /&gt;
*[[Fantasy|Fantasy]] by [[Semilanceata|Semilanceata]] &lt;br /&gt;
*[[Hate Beats|Hate Beats]] by [[Ukonx|Ukonx]] &lt;br /&gt;
*[[It was so nice before the crash of the mir station|It was so nice before the crash of the mir station]] by [[Eliot|Eliot]] &lt;br /&gt;
*[[Kill Max]] by [[OFE|OFE]]&lt;br /&gt;
*[[Larsen|Larsen]] by [[OFE|OFE]]&lt;br /&gt;
*[[Lumiere]] by [[Revival|Revival]] &lt;br /&gt;
*[[LiquidSnake|LiquidSnake]] by [[Revival|Revival]] &lt;br /&gt;
*[[Sappy|Sappy]] by [[Semilanceata|Semilanceata]] &lt;br /&gt;
*[[Simply The Bests|Simply The Bests]] by [[Eliot|Eliot]] &lt;br /&gt;
*[[Seminoisin|Seminoisin]] by [[Semilanceata|Semilanceata]] &lt;br /&gt;
*[[Synergy|Synergy]] by [[Ast]] of&amp;amp;nbsp;[[Impact|Impact]] &lt;br /&gt;
*[[Tragedy|Tragedy]] by [[Ast]] of&amp;amp;nbsp;[[Impact|Impact]]&lt;br /&gt;
*[[Walking on a scroll|Walking on a scroll]] by [[BDC-Iron|BDC-Iron]] &lt;br /&gt;
*[[XMas 2008]] Dentro by [[Ast]] of&amp;amp;nbsp;[[Impact|Impact]] &lt;br /&gt;
*[[Wulf|Wulf]]/[[Ratz|Ratz]] unreleased part of [[Palatine|Palatine]] &lt;br /&gt;
*[[Ze Meeting 2000 Demo|Ze Meeting 2000 Demo]] by [[BDC-Iron|BDC-Iron]]&lt;br /&gt;
&lt;br /&gt;
=== Demos with Plus features ===&lt;br /&gt;
&lt;br /&gt;
* [[20, 21,22 February 1999 meeting Demo]] by [[Benediction]]&lt;br /&gt;
* [[A Step Beyond]] by [[Dirty Minds]]&lt;br /&gt;
* [[Genesis demo]] (unreleased ? - [[STS]])&lt;br /&gt;
* [[Heat Demo]] by [[Odiesoft]]&lt;br /&gt;
* [[Fire Engine demo]] (attributed to [[Roo-dolph]] but unreleased?)&lt;br /&gt;
* [[System Party 97]] by [[Eliot]]&lt;br /&gt;
* [[Texture Mapping Plus]] by [[Odiesoft]]&lt;br /&gt;
* [[Ze Meeting 96-97 Compilation]] by [[Condense]] (Contains a CPC+ part)&lt;br /&gt;
* [[Ae2010 Final Exams]] by [[Impact]] (The last part contains some Cpc+ features !)&lt;br /&gt;
&lt;br /&gt;
* to complete&lt;br /&gt;
&lt;br /&gt;
==== Slide Shows ====&lt;br /&gt;
&lt;br /&gt;
* [[Fatal Beauties]] by ([[FaTaLiTy]], 2007)&lt;br /&gt;
* [[Ghostbuster plus]] (fast-made slide-show by [[Ninxpe]] in 2007)&lt;br /&gt;
* [[Models]] by [[Da Boxon Team]]&lt;br /&gt;
* [[Sexy Slideshow]] by [[Demoniak]]&lt;br /&gt;
* [[Samantha Fox Slideshow]] by [[Demoniak]]&lt;br /&gt;
* [[The 7th guest slideshow]] by [[Snn]]&lt;br /&gt;
* [[Amiga Graphics Plus]] compiled by [[Simon Green]]&lt;br /&gt;
&lt;br /&gt;
=== Graphics  ===&lt;br /&gt;
&lt;br /&gt;
* [[Bmp Converter]] ([[Snn]] of [[Futur's]])&lt;br /&gt;
* [[Claudia]], a Bmp Converter ([[Eliot]])&lt;br /&gt;
* [[GMSK]] ([[TFM]] of [[FutureSoft]])&lt;br /&gt;
* [[GraphOS]] ([[BDC-Iron]])&lt;br /&gt;
* [[Kit 4096]] ([[OffseT]])&lt;br /&gt;
* [[Sprite Editor]] ([[Blue Impuls]])&lt;br /&gt;
* [[SMARTplus]] ([[Radical Software]])&lt;br /&gt;
&lt;br /&gt;
(to complete... see [[Applications]])&lt;br /&gt;
&lt;br /&gt;
=== Music  ===&lt;br /&gt;
&lt;br /&gt;
* [[Soundtracker DMA]] by [[Zik]] of [[Futur's]]&lt;br /&gt;
&lt;br /&gt;
(to complete... see [[Applications]])&lt;br /&gt;
&lt;br /&gt;
=== Utilities ===&lt;br /&gt;
&lt;br /&gt;
* [[B-ASIC]] ([[Logon System]])&lt;br /&gt;
&lt;br /&gt;
=== Alternate Operating Systems ===&lt;br /&gt;
&lt;br /&gt;
* [[FutureOS]]&lt;br /&gt;
&lt;br /&gt;
=== Cartridge Games ===&lt;br /&gt;
&lt;br /&gt;
* [[Barbarian 2 ( Cartridge )|Barbarian 2]]&lt;br /&gt;
* [[Batman The Movie ( Cartridge )|Batman The Movie]]&lt;br /&gt;
* [[Burnin' Rubber|Burning Rubber]]&lt;br /&gt;
* [[Chase HQ 2 ( Cartridge )|Chase HQ 2]]&lt;br /&gt;
* [[Copter 271 ( Cartridge )|Copter 271]]&lt;br /&gt;
* [[Crazy Cars 2 ( Cartridge )|Crazy Cars 2]]&lt;br /&gt;
* [[Dick Tracy ( Cartridge )|Dick Tracy]]&lt;br /&gt;
* [[Enforcer (With Phazer) ( Cartridge )|Enforcer (With Phazer)]]&lt;br /&gt;
* [[Fire and Forget 2 ( Cartridge )|Fire and Forget 2]]&lt;br /&gt;
* [[Klax ( Cartridge )|Klax]]&lt;br /&gt;
* [[Mystical ( Cartridge )|Mystical]]&lt;br /&gt;
* [[Navy Seals ( Cartridge )|Navy Seals]]&lt;br /&gt;
* [[No Exit ( Cartridge )|No Exit]]&lt;br /&gt;
* [[Operation Thunderbolt ( Cartridge )|Operation Thunderbolt]] &lt;br /&gt;
* [[Pang ( Cartridge )|Pang]]&lt;br /&gt;
* [[Panza kickboxing ( Cartridge )|Panza Kick Boxing]]&lt;br /&gt;
* [[Plotting ( Cartridge )|Plotting]]&lt;br /&gt;
* [[Pro Tennis Tour ( Cartridge )|Pro Tennis Tour]]&lt;br /&gt;
* [[Robocop 2 ( Cartridge )|Robocop 2]]&lt;br /&gt;
* [[Skeet Shoot (With Phazer) ( Cartridge )|Skeet Shoot]]&lt;br /&gt;
* [[Super Pinball Magic ( Cartridge )|Super Pinball Magic]]&lt;br /&gt;
* [[Switchblade ( Cartridge )|Switchblade]]&lt;br /&gt;
* [[Tennis Cup 2 ( Cartridge )|Tennis Cup 2]]&lt;br /&gt;
* [[Tintin On the Moon ( Cartridge )|Tintin on the Moon]]&lt;br /&gt;
* [[Wild Streets ( Cartridge )|Wild Streets]]&lt;br /&gt;
* [[World Of Sports ( Cartridge )|World Of Sports]]&lt;br /&gt;
&lt;br /&gt;
=== Unofficial Cartridge Games ===&lt;br /&gt;
&lt;br /&gt;
The following cartridge games are unofficial, i.e. in that they were not sold commercially during the Plus/GX4000 lifetime.&lt;br /&gt;
These cartridges work on Plus and GX4000.&lt;br /&gt;
&lt;br /&gt;
* [[Bears!]]&lt;br /&gt;
* [[Blue Angel 69]]&lt;br /&gt;
* [[Puzznic]]&lt;br /&gt;
* [[Stryker and the Crypts of Trogan]]&lt;br /&gt;
&lt;br /&gt;
=== Non-cartridge Games ===&lt;br /&gt;
&lt;br /&gt;
* [[Aigle D'or: Le Retour]]&lt;br /&gt;
* [[Best Of The Best]] - Championship Panza Gold Edition Karate/Kick Boxing Gold Edition ([[Loriciels]]) (1991)&lt;br /&gt;
* [[Burger Party]] ([[Futur's]]) - horizontal shoot'em up&lt;br /&gt;
* [[Bumpy's Arcade Fantasy]]&lt;br /&gt;
* [[Call &amp;amp;BD10'n'oeuf]] ([[Fenyx Kell]]) - released for the Amstrad Expo 2005 Contest&lt;br /&gt;
* [[DDay]]&lt;br /&gt;
* [[Fluff]] ([[Radical Software]])&lt;br /&gt;
* [[Frogger]] ([[Executioner]])&lt;br /&gt;
* [[Jet Set Willy Plus - Manic Miner 3 Plus]] ([[Andy Cadley]]) - remakes of 3 CPC classics for the CPC Plus &lt;br /&gt;
* [[Prehistorik 2]] ([[Titus Software]])&lt;br /&gt;
* [[Space Gun]] ([[Ocean]])&lt;br /&gt;
* [[Stryker and the Crypts of Trogan]] ([[Codemasters]]) - enhanced for Plus&lt;br /&gt;
* [[Wildfire]] (Game in development for the CPC plus)&lt;br /&gt;
&lt;br /&gt;
=== Games patched for the Plus ===&lt;br /&gt;
&lt;br /&gt;
The following Amstrad CPC games have been patched for the Plus to take advantage of its extended colour palette. They are often disk versions that do not work on GX4000:&lt;br /&gt;
&lt;br /&gt;
* [[Cybernoid II Plus]]&lt;br /&gt;
* [[FIFA World Cup 2006]] - based on ''World Cup Soccer: Italia '90''&lt;br /&gt;
* [[Solomon's Key Plus]]&lt;br /&gt;
* [[Operation Wolf Plus]]&lt;br /&gt;
* [[Rick dangerous 128%2B]] - Extended and enhanced for Plus&lt;br /&gt;
&lt;br /&gt;
=== Vapourwares ===&lt;br /&gt;
&lt;br /&gt;
Some games are said to have actually existed and even reviewed in some specialised press :&lt;br /&gt;
&lt;br /&gt;
* [[:Category:Vaporware]]&lt;br /&gt;
&lt;br /&gt;
=== Bootlegs ===&lt;br /&gt;
&lt;br /&gt;
Lately (as of May 2007) several instances ofbootleg cartridges have appeared. These are not original releases and, although they could run without any problems, caution should be exercised when buying. What is more, their collectible/historical value is doubtful. For more details, see [[Bootleg Cartridges]] and [http://www.pcwking.netfirms.com/cartridge.html here]&lt;br /&gt;
&lt;br /&gt;
=== Modern Cartridges ===&lt;br /&gt;
&lt;br /&gt;
* [[Modern Cartridges]]&lt;br /&gt;
&lt;br /&gt;
== Included in Delivery ==&lt;br /&gt;
&lt;br /&gt;
=== 464 Plus ===&lt;br /&gt;
&lt;br /&gt;
* The computer itself, including built-in Datacorder&lt;br /&gt;
* [[Plus System Cartridge]] with Operating System (v4), [[Locomotive BASIC]] v1.1, [[AMSDOS]] and the game [[Burnin' Rubber]]&lt;br /&gt;
* 1 Paddle&lt;br /&gt;
* 464 Plus/6128 Plus manual&lt;br /&gt;
* Game manual&lt;br /&gt;
* Either an [[Amstrad MM12 Monochrome Monitor]] or an [[Amstrad CM14 Colour Monitor]]&lt;br /&gt;
&lt;br /&gt;
=== 6128 Plus ===&lt;br /&gt;
&lt;br /&gt;
* The computer itself, including built-in 3&amp;quot; disk drive&lt;br /&gt;
* [[Plus System Cartridge]] with Operating System (v4), [[Locomotive BASIC]] v1.1, [[AMSDOS]] and the game [[Burnin' Rubber]]&lt;br /&gt;
* [[System Disk]] with CP/M Plus and utilities, identical disk for all countries&lt;br /&gt;
* 1 Paddle&lt;br /&gt;
* 464 Plus/6128 Plus manual&lt;br /&gt;
* Game manual&lt;br /&gt;
* Either an [[Amstrad MM12 Monochrome Monitor]] or an [[Amstrad CM14 Colour Monitor]]&lt;br /&gt;
&lt;br /&gt;
=== GX4000 ===&lt;br /&gt;
&lt;br /&gt;
* The console itself which included SCART and RF outputs for connection to a TV&lt;br /&gt;
* [[Burnin' Rubber]] cartridge&lt;br /&gt;
* 2 Paddles&lt;br /&gt;
* Console manual&lt;br /&gt;
* Game manual&lt;br /&gt;
* Power supply 11v 500mA - -(o- + &lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;Amstrad GX4000&amp;quot;&amp;gt;&lt;br /&gt;
Image:GX4000 01.jpg&lt;br /&gt;
Image:GX4000 02.jpg&lt;br /&gt;
Image:GX4000 03.jpg&lt;br /&gt;
Image:GX4000 04.jpg&lt;br /&gt;
Image:GX4000 05.jpg&lt;br /&gt;
Image:GX4000 06.jpg&lt;br /&gt;
Image:GX4000 07.jpg&lt;br /&gt;
Image:GX4000 08.jpg&lt;br /&gt;
Image:GX4000 09.jpg&lt;br /&gt;
Image:GX4000 10.jpg&lt;br /&gt;
Image:GX4000 11.jpg&lt;br /&gt;
Image:GX4000 12.jpg&lt;br /&gt;
Image:GX4000_Top.jpg|GX4000 Top&lt;br /&gt;
Image:GX4000_Bottom.jpg|GX4000 Bottom&lt;br /&gt;
Image:GX4000_PCB_Top.jpg|GX4000 Motherboard Top&lt;br /&gt;
Image:GX4000_PCB_Bottom.jpg|GX4000 Motherboard Bottom&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Amstrad CSD ==&lt;br /&gt;
&lt;br /&gt;
The Amstrad CSD was a system containing a 464PLUS motherboad and an additionnal Mainboard enabling to switch beteween 12 different game (or whatever) Cartridges. The System was supplied with some sort of JukeBox OS Cartridge.&lt;br /&gt;
&lt;br /&gt;
It was used as a demonstration system at retailers and shops were the Amstrad PLUS range was sold.&lt;br /&gt;
&lt;br /&gt;
[[Amstrad CSD| Check the Amstrad CSD page for more details.]]&lt;br /&gt;
&lt;br /&gt;
== Videos ==&lt;br /&gt;
&lt;br /&gt;
Showing the GX4000 in action&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|HLE7vi1J6Jc|300}}&lt;br /&gt;
&lt;br /&gt;
Review of the GX4000 by Retro Zone&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|T6oG7DRdBgI|300}}&lt;br /&gt;
&lt;br /&gt;
25th Anniversary Special By Novabug with Guru Larry&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|iWB6NRkjTmE|300}}&lt;br /&gt;
&lt;br /&gt;
Unboxing &amp;amp; Playtest by Novabug&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|q8quohU5awY|300}}&lt;br /&gt;
&lt;br /&gt;
== Emulators for the Plus ==&lt;br /&gt;
&lt;br /&gt;
* [[Arnold]]&lt;br /&gt;
* [[WinApe]]&lt;br /&gt;
* [[MESS]]&lt;br /&gt;
* [[NO$CPC]]&lt;br /&gt;
* [[MTMW]]&lt;br /&gt;
* [[ACE_(Emulator)|ACE CPC Emulator]]&lt;br /&gt;
&lt;br /&gt;
== Weblinks ==&lt;br /&gt;
&lt;br /&gt;
*http://www.gx4000.co.uk/ Xyphoe's GX4000 site - Reviews, roms, manuals, screen shots, vidoes, rarity/price guide for carts and more!&lt;br /&gt;
*http://www.cpcmania.com/   ( on the games section : GX4000/CPC+ GAMES )&lt;br /&gt;
*[http://www.pcwking.netfirms.com/cartridge.html Listing and pictures of Amstrad GX4000 games]&lt;br /&gt;
*[http://www.kjthacker.f2s.com/docs/carts.htm Complete list of GX 4000 games]&lt;br /&gt;
*http://www.thepixelempire.net/amstrad-gx4000-reviews.html - Reviews of the GX4000 titles&lt;br /&gt;
*http://www.thepixelempire.net/pixel-memories-amstrad-gx4000.html - A retrospective look at the console.&lt;br /&gt;
&lt;br /&gt;
[[Category:Hardware| ]] [[Category:CPC Plus| ]][[Category:Video contents]][[Category:CPC Internal Components| ]][[Category:CPC History|* ]][[Category:Non CPC Computers| ]][[Category:Amstrad Products| ]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Futurs%27&amp;diff=101547</id>
		<title>Futurs'</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Futurs%27&amp;diff=101547"/>
				<updated>2018-04-21T17:36:52Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Utilities */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Futurs' is a french demogroup. They published the [[Quasar CPC|Quasar CPC]] paper fanzine and have various others projects.&amp;lt;br&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
== Fanzine  ==&lt;br /&gt;
&lt;br /&gt;
*[[Quasar CPC|Quasar CPC]]: a CPC french papermag published between 1992 and 2007 (mainly dedicated to coding).&lt;br /&gt;
&lt;br /&gt;
*[[Quasar Net|Quasar Net]]: a wiki version of Quasar CPC, started in 2009 (embed improved version of the original Quasar CPC articles and illustrations, and some new topics).&lt;br /&gt;
&lt;br /&gt;
== Software  ==&lt;br /&gt;
&lt;br /&gt;
=== Demos  ===&lt;br /&gt;
&lt;br /&gt;
*[[Back to Futurs'|Back to Futurs']] (part of the [http://www.pouet.net/prod.php?which=67656[30 Years Megademo]])&lt;br /&gt;
&lt;br /&gt;
*[[Gloom's Demo|Gloom's Demo]] (guess part of the [[Power System Megademo 1995|Power System Megademo 1995]])&lt;br /&gt;
&lt;br /&gt;
*[[Schädel Demo|Schädel Demo]] (guess part of the [[The Years Of CPC Megademo|The Years Of CPC Megademo]])&lt;br /&gt;
&lt;br /&gt;
*[[Two Of Spade|Two Of Spade]]&lt;br /&gt;
&lt;br /&gt;
*[[Natural Bug Killer|Natural Bug Killer]]&lt;br /&gt;
&lt;br /&gt;
*[[PI1 screen slide show|PI1 screen slide show]]&lt;br /&gt;
&lt;br /&gt;
*[[Sample DMA demo|Sample DMA demo]]&lt;br /&gt;
&lt;br /&gt;
*[[The 7th guest slideshow|The 7th guest slideshow]]&lt;br /&gt;
&lt;br /&gt;
*[[RTS patched for Plus|RTS patched for Plus]]&lt;br /&gt;
&lt;br /&gt;
*[[Fuck Oeuf|Fuck Oeuf]]&lt;br /&gt;
 &lt;br /&gt;
*[[Citron_Demo|Citron Demo]]&lt;br /&gt;
&lt;br /&gt;
=== Utilities  ===&lt;br /&gt;
&lt;br /&gt;
*[[ACE_(Emulator)|ACE CPC Emulator]]&lt;br /&gt;
&lt;br /&gt;
*[[Kit Overscan|Kit Overscan]]&lt;br /&gt;
&lt;br /&gt;
*[[Amsdos Musical Loader|Amsdos Musical Loader]]&lt;br /&gt;
&lt;br /&gt;
*[[Kit 4096|Kit 4096]]&lt;br /&gt;
&lt;br /&gt;
*[[PI1-Convert|PI1-Convert]]&lt;br /&gt;
&lt;br /&gt;
*[[BMP-Convert|BMP-Convert]]&lt;br /&gt;
&lt;br /&gt;
*[[Hard Sprite Designer|Hard Sprite Designer]]&lt;br /&gt;
&lt;br /&gt;
*[[Soundtracker DMA|Soundtracker DMA]]: a sound tracker using the extended CPC+ functionalities. Currently only an early demo exists: [[Breakpoint 2010 - Fairy]]&lt;br /&gt;
&lt;br /&gt;
=== Roms  ===&lt;br /&gt;
&lt;br /&gt;
*[[ROMBoot|ROMBoot 1 &amp;amp;amp; 2]]: small ROMs to access common tools directly from boot sequence.&lt;br /&gt;
&lt;br /&gt;
*[[Syspatch|Syspatch]]: small system extension (fast math, 8-bit printer on CPC+, ...).&lt;br /&gt;
&lt;br /&gt;
*[[Interrupt lib|Interrupt lib]]: vectorized interrupt support for system.&lt;br /&gt;
&lt;br /&gt;
*[[CPCISA|CPCISA]] rom: drivers for CPC-ISA.&lt;br /&gt;
&lt;br /&gt;
*[[Albireo|Albireo]] rom: Amsdos compatible drive for Albireo USB card.&lt;br /&gt;
&lt;br /&gt;
=== Games  ===&lt;br /&gt;
&lt;br /&gt;
*[[Rendez-vous avec la M.O.R.T|Rendez-vous avec la M.O.R.T]]&lt;br /&gt;
&lt;br /&gt;
*[[Burger Party|Burger Party]]&lt;br /&gt;
&lt;br /&gt;
== Electronics  ==&lt;br /&gt;
&lt;br /&gt;
*[[Soundplayer|Soundplayer]]: simple improved version of the [[Digiblaster|Digiblaster]].&lt;br /&gt;
&lt;br /&gt;
* Soundplayer+, SoundplayerNG: these cards include a classic Soundplayer and a [[VirtualNet|VirtualNet]] network interface.&lt;br /&gt;
&lt;br /&gt;
== Unfinished projects  ==&lt;br /&gt;
&lt;br /&gt;
*[[Asic Inside|Asic Inside]]: a CPC+ demo, wich will be finished... soon... maybe...&lt;br /&gt;
&lt;br /&gt;
*[[Aventury|Aventury]] (cancelled, some preview where released within the Aventury Reliques Pack #1)&lt;br /&gt;
&lt;br /&gt;
*[[ANA|ANA]] operating system (prototyping only, discontinued).&lt;br /&gt;
&lt;br /&gt;
*[[Stormlord Plus|Stormlord Plus]]: a remake of the game stormlord for CPC+... finished but never published.&lt;br /&gt;
&lt;br /&gt;
*[[De retour des Ténèbres|De retour des Ténèbres]]: this game might be published one day or another... maybe... perhaps... who knows. :)&lt;br /&gt;
&lt;br /&gt;
*[[Mélodie|Mélodie]]: this project is a real sound card for cpc, with high-quality real time sampling and replaying (this project was cancelled before the final release).&lt;br /&gt;
&lt;br /&gt;
== Members  ==&lt;br /&gt;
&lt;br /&gt;
*[[Barjack|Barjack]]&lt;br /&gt;
&lt;br /&gt;
*[[Bilbo|Bilbo]]&lt;br /&gt;
&lt;br /&gt;
*[[OffseT|OffseT]]&lt;br /&gt;
&lt;br /&gt;
*[[Snn|SNN]]&lt;br /&gt;
&lt;br /&gt;
*[[Tony|Tony]]&lt;br /&gt;
&lt;br /&gt;
*[[Zik|Zik]]&lt;br /&gt;
&lt;br /&gt;
== Related link  ==&lt;br /&gt;
&lt;br /&gt;
Official web site: [http://futurs.cpcscene.net [http://futurs.cpcscene.net]]&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
[[Category:Scene_group]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=B-ASIC&amp;diff=101546</id>
		<title>B-ASIC</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=B-ASIC&amp;diff=101546"/>
				<updated>2018-04-21T17:15:22Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''B-Asic''' is a set of RSX commands allowing to use the Amstrad CPC Plus features from [[BASIC]]. It was written by [[Longshot]] of [[Logon System]].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
'''B-ASIC''' is a set of RSX instructions to manage the extra features of the '''CPC +'''&lt;br /&gt;
&lt;br /&gt;
RSX instruction signify that each instruction is prefixed by a special char : | on english keyboard and &amp;quot;ù&amp;quot; on french azerty keyboard&lt;br /&gt;
&lt;br /&gt;
Since release 3.0 B-ASIC runs only on CPC range with 128 Kb memory &lt;br /&gt;
&lt;br /&gt;
Main instructions can manage colours and sprites, providing an extra bank of '''128 sprites''' for a total of '''144 sprites''' (since version 3.4)&lt;br /&gt;
&lt;br /&gt;
'''B-ASIC doesn't take any byte of the CPC locomotive Basic memory.''' &lt;br /&gt;
(The RSX definition and code for locomative basic are not declared in main memory )&lt;br /&gt;
The whole interruption system and RSX managment is modified when B-Asic start. &lt;br /&gt;
&lt;br /&gt;
From a technical point of view, the code of the program BASIC using B-ASIC is copied in a bank, because one bank is always open for the system to store the BASIC code. &lt;br /&gt;
So, there are two video pages availables for the user. &lt;br /&gt;
&lt;br /&gt;
A set of new powerful instructions will come in future versions.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Games developed using B-ASIC ==&lt;br /&gt;
&lt;br /&gt;
* [[Call &amp;amp;BD10'n'oeuf]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Historics ==&lt;br /&gt;
* V1.1 ??/04/1991 Published in Amstrad Cent pour Cent (A100%) magazine N°38 (may/june 1991) New instructions INKF, INKS, BORDERP, INKFRVB, INKSRVB, BORDERRVB&lt;br /&gt;
* V1.2 ??/05/1991 Published in A100% N°39 (july/aug 1991)New instructions  SPRON,SPROFF,SPRZOOM,SPRXY,SPRTDEF,SPRTON,SPRTOFF, SPRSWAP,SPRPLOT,SPRCOPY,SPRTURNX,SPRTURNY,SPRFILL&lt;br /&gt;
* V1.3 ??/08/1991 Published in A100% N°40 (sept/oct 1991)- Corrected bug with  MODE instruction with some roms- Corrected bug on prg  &amp;gt; 16k- Update instructions SPRTDEF, SPRTON, SPRTOFF- New instructions SPRTORAM, RAMTOSPR, SPRSAVE, SPRLOAD- New instructions RETARDX, RETARDY, MASQUE, SPLIT&lt;br /&gt;
* V1.4 ??/??/1992 Published in A100% N°42 ()- B-Asic runs in banks (without RSX managment).&lt;br /&gt;
* V2.1 ??/??/1992 - New temporary version with RSX system deviation&lt;br /&gt;
* V3.1 ??/??/1992 - 2nd vidéo page. Corrected little bugs.- New instructions POKEASIC, POKEVR, DEFORGXY, DEFORGSPR - New instructions SPRCATCH, INKCOPY,SPRLINK, SPRUNLINK, ERALINK&lt;br /&gt;
* V3.2 25/02/2006 - Corrected a bug in table calculation (interrupt function)- Corrected a bug in locomotive firmware (ei before real end interrupt)&lt;br /&gt;
* V3.3 27/02/2006 - Corrected bug : Basic code copied in banque 5 at B-Asic boot (it was a problem for progr bigger than 16 kb) since 3.1- New instruction SPRWHERE&lt;br /&gt;
* V3.4 24/05/2007 - Corrected bug in SPRWHERE (variable setting between 4000 and 7FFF)- Update instruction SPRCOPY (now accepting sprites number from 0 to 143). Sprites 0 to 15 are real sprites. Now there are 128 sprites instead of 64 in previous version :  64 sprites FAST and 64 sprites SLOW (sprites access for sprites 80 to 143 are slowest than FAST sprites access). These additionnal sprites does not take more space than with 64 in the previous release.- New instruction DOKE,address, 16bitsvalue- Removing instructions RAMTOSPR and SPRTORAM, which are now unuseful. (replaced by SPRCOPY)- New instruction SPRTSTEP,n1,…,nx to play the sprite-way step by step (user action).- New instruction DEFKBDSPR to link one or two super-sprites with keyboard (or joystick) keys (automatic or user activable).- Update instruction CATCH : New name SPRCATCH- New instruction SPRCOLL to manage (automatically or user-activable) collisions for up to 8 super-sprites.- Some optimisations&lt;br /&gt;
&lt;br /&gt;
== Starting B-Asic ==&lt;br /&gt;
To use B-Asic, it's very easy. You need only two things :&lt;br /&gt;
Get the file named '''B-ASIC.BIN'''&lt;br /&gt;
Insert as first line in your basic program the following line :&lt;br /&gt;
&lt;br /&gt;
'''10 IF PEEK(&amp;amp;BC0E)&amp;lt;&amp;gt;&amp;amp;CD THEN OUT &amp;amp;7F00,&amp;amp;C1 :LOAD &amp;quot;B-ASIC.BIN &amp;quot;,&amp;amp;C000 :CALL &amp;amp;C000'''&lt;br /&gt;
&lt;br /&gt;
== Instructions ==&lt;br /&gt;
----&lt;br /&gt;
=== Colours Instructions Set ===&lt;br /&gt;
----&lt;br /&gt;
'''INKF,pen,colour'''&lt;br /&gt;
* pen=[0..15] colour=[0..4095]&lt;br /&gt;
* Modify colour of a pen&lt;br /&gt;
* Example : INKF,0,2303&lt;br /&gt;
----&lt;br /&gt;
'''INKFRVB,pen,red,green,blue'''&lt;br /&gt;
* pen=[0..15] red=[0..15] green=[0..15] blue=[0..15]&lt;br /&gt;
* Modify colour for a pen using colour elementaries components&lt;br /&gt;
* Example : FOR I=0 TO 15:INKFRVB,0,I,0,0:NEXT I&lt;br /&gt;
----&lt;br /&gt;
'''BORDERP,colour'''&lt;br /&gt;
* colour=[0..4095]&lt;br /&gt;
* Modify border's colour.&lt;br /&gt;
* Example : BORDERP,543&lt;br /&gt;
----&lt;br /&gt;
'''BORDERRVB,red,green,blue'''&lt;br /&gt;
* red=[0..15] green=[0..15] blue=[0..15]&lt;br /&gt;
* Modify border colour using colour elementaries components&lt;br /&gt;
* Example : FOR I=0 TO 15:BORDERRVB,0,0,0,I:NEXT I&lt;br /&gt;
----&lt;br /&gt;
'''INKS,pen,colour'''&lt;br /&gt;
* pen=[1..15] colour=[0..4095]&lt;br /&gt;
* Modify colour of an hardware sprite pen&lt;br /&gt;
* Note : The pen 0 cannot be modified. It's the transparent colour.&lt;br /&gt;
* Example : INKS,1,3456&lt;br /&gt;
----&lt;br /&gt;
'''INKSRVB,pen,red,green,blue'''&lt;br /&gt;
* pen=[1..15] red=[0..15] green=[0..15] blue=[0..15]&lt;br /&gt;
* Modify colour for an hardware sprite pen using colour elementaries components&lt;br /&gt;
* Note : The pen 0 cannot be modified. It's the transparent colour.&lt;br /&gt;
* Example : FOR I=0 TO 15:INKFRVB,0,I,0,0:NEXT I&lt;br /&gt;
----&lt;br /&gt;
'''INKCOPY'''&lt;br /&gt;
* Copy the whole colour screen palette to sprite palette.&lt;br /&gt;
----&lt;br /&gt;
=== Sprites Instructions Set ===&lt;br /&gt;
----&lt;br /&gt;
'''SPROFF,SpriteNumber'''&lt;br /&gt;
* SpriteNumber=[0..15]&lt;br /&gt;
* Sprite display is disactivated for specified sprite.&lt;br /&gt;
* Example : SPROFF,3  &lt;br /&gt;
----&lt;br /&gt;
'''SPRON,SpriteNumber'''&lt;br /&gt;
* SpriteNumber=[0..15]&lt;br /&gt;
* Sprite display is activated for specified sprite.&lt;br /&gt;
* Example : SPRON,3  &lt;br /&gt;
----&lt;br /&gt;
'''SPRZOOM,SpriteNumber,XZoom,YZoom'''&lt;br /&gt;
* SpriteNumber=[0..15] XZoom=[0..3] YZoom=[0..3]&lt;br /&gt;
* Define sprite zoom for specified sprite.&lt;br /&gt;
* If XZoom or YZoom is zeroed, sprite is not displayed&lt;br /&gt;
* Zoom value of 1 is no magnify.&lt;br /&gt;
* Note : Sprite must be activated by SPRON instruction to be displayed on screen&lt;br /&gt;
* Example : SPRZOOM,2,2,1 define the sprite 2 magnification to 2x horiz. and 1x vertically&lt;br /&gt;
----&lt;br /&gt;
'''SPRXY,SpriteNumber,XPos,YPos'''&lt;br /&gt;
* SpriteNumber=[0..15] XPos=[-256..767] YZoom=[-256..255]&lt;br /&gt;
* Define sprite position on screen according a mode 2 definition&lt;br /&gt;
* Note : Sprite must be activated by SPRON instruction to be displayed on screen&lt;br /&gt;
* Example : SPRXY,2,100,80 define sprite 2 position at 100,80 coordinates&lt;br /&gt;
----&lt;br /&gt;
'''SPRTDEF,SpriteNumber,Address,DurationPer,WaitingPer'''&lt;br /&gt;
* SpriteNumber=[0..15] Address=[0..65535] DurationPer=[0..65535] WaitingPer=[0..65535]&lt;br /&gt;
* Periods are defined by period of 0,02 second (e.g. 50 = 1 second) &lt;br /&gt;
* Define a path for the specified sprite.&lt;br /&gt;
* The path is defined by screen positions, given by a set of x,y coordinates defined in memory.&lt;br /&gt;
* Each coordinate is defined on 2 bytes (4 bytes for a screen position) in the memory&lt;br /&gt;
* The coordinate must be stored on a little endian method, e.g. the less significant byte in first and the most significant byte in second position in memory. &lt;br /&gt;
* You can use the instruction DOKE to do that easily (example : |DOKE address, x : |DOKE address+2,y : address=address+4)&lt;br /&gt;
* The last x coordinate must take the value F0F0 (hexa) to indicate the path end definition (|DOKE address,&amp;amp;F0F0)&lt;br /&gt;
* DurationPer indicates the time while the sprite will run on the path (at the last position the path start again at the fist position). &lt;br /&gt;
* If DurationPer is zeroed, so the duration is infinite.&lt;br /&gt;
* WaitingPer indicate the start period which occurs when the path will be activated (see SPRTON and SPRTOFF instructions). Note : A same path can be used by one or more sprites. Example : SPRTDEF,3,&amp;amp;3000,0,100 to define for sprite 3 a path defined in &amp;amp;3000 with an infinite loop of the path after 2 seconds of start delay after SPRTON,3 instruction.&lt;br /&gt;
----&lt;br /&gt;
'''SPRTON,SprNb1,SprNb2,...,SprNbx'''&lt;br /&gt;
* SprNbx=[O..15]&lt;br /&gt;
* Start the path simultanously for the specified sprites.&lt;br /&gt;
* Note : An undefined path for the sprite may occur an erratic behaviour of the sprite started.&lt;br /&gt;
* Example : SPRTON,1,5,7  start the path for sprites 1, 5 and 7 simultaneously&lt;br /&gt;
----&lt;br /&gt;
'''SPRTOFF,SprNb1,SprNb2,...,SprNbx'''&lt;br /&gt;
* SprNbx=[0..15]&lt;br /&gt;
* Stop the path simultaneously for the specified sprites &lt;br /&gt;
* Example : SPRTOFF,1,7 stop the path for sprites 1 and 7 simultanously&lt;br /&gt;
----&lt;br /&gt;
'''SPRTSTEP,SprNb1,SprNb2,...,SprNbx'''&lt;br /&gt;
* SprNbx=[0..15] &lt;br /&gt;
* Execute the path step by step for the specified sprites. &lt;br /&gt;
* Note : An undefined path for the sprite may occur an erratic behaviour of the sprite started. &lt;br /&gt;
* Example : SPRTSTEP,1,5,7 plays one path step (defined with SPRTDEF) for sprites 1, 5 and 7 simultaneously &lt;br /&gt;
----&lt;br /&gt;
'''SPRSWAP,SpriteNumber1,SpriteNumber2'''&lt;br /&gt;
* SpriteNumberx=[0..15]&lt;br /&gt;
* Exchange the sprite content of two sprites.&lt;br /&gt;
* Note : If SpriteNumber1=SpriteNumber2 it results just a waste of time.&lt;br /&gt;
* Example : SPRSWAP,1,5 exchange the graphics data of sprites 1 and 5&lt;br /&gt;
----&lt;br /&gt;
'''SPRPLOT,SpriteNumber,XPos,YPos,SpritePen'''&lt;br /&gt;
* SpriteNumber=[0..15] XPos=[0..15] YPos=[0..15] SpritePen=[0..15]&lt;br /&gt;
* Plot a pixel in the specified sprite at specified coordinates&lt;br /&gt;
* Note : SpritePen=0 means the transparent pen for sprite&lt;br /&gt;
* Example : SPRPLOT,3,10,9,4 plot a pixel pen 4 at coordinates 10,9 of sprite 3&lt;br /&gt;
----&lt;br /&gt;
'''SPRCOPY,SpriteOrg,SpriteDst'''&lt;br /&gt;
* SpriteOrg=[0..143], SpriteDst=[0..143] &lt;br /&gt;
* Copy the content of SpriteOrg to SpriteDst. &lt;br /&gt;
	Sprites number	Definition&lt;br /&gt;
	0 to 15		Real sprites&lt;br /&gt;
	16 to 79	Ram Fast sprites&lt;br /&gt;
	80 to 143	Ram Slow sprites&lt;br /&gt;
* Example : SPRCOPY,1,81 copy the content of sprite 1 (asic) to sprite 81 (ram slow)&lt;br /&gt;
----&lt;br /&gt;
'''SPRTURNX,SpriteNumber'''&lt;br /&gt;
* SpriteNumber=[0..15]&lt;br /&gt;
* Flip the sprite specified on horizontal axis&lt;br /&gt;
* Example : SPRTURNX,1&lt;br /&gt;
----&lt;br /&gt;
'''SPRTURNY,SpriteNumber'''&lt;br /&gt;
* SpriteNumber=[0..15]&lt;br /&gt;
* Flip the sprite specified on vertical axis&lt;br /&gt;
* Example : SPRTURNY,1&lt;br /&gt;
----&lt;br /&gt;
'''SPRFILL,SpriteNumber,SpritePen'''&lt;br /&gt;
* SpriteNumber=[0..15] SpritePen=[0..15]&lt;br /&gt;
* Fill the specified sprite with the specified pen&lt;br /&gt;
* Note : SpritePen=0 means the transparent pen for sprite&lt;br /&gt;
* Example : SPRFILL,1,12 fill the sprite 1 with pen 12&lt;br /&gt;
----&lt;br /&gt;
'''SPRCATCH,SpriteNumber,XPos,YPos'''&lt;br /&gt;
* SpriteNumber=[0..15] XPos=[0..143] YPos=[0..183]&lt;br /&gt;
* Get a sprite from mode 0 screen at specified coordinates (coordinates top/left).&lt;br /&gt;
* Note : This instruction runs only in graphic mode 0&lt;br /&gt;
* Example : CATCH,3,120,100 catch the pixels from 120,100 to 135,115 in sprite 3&lt;br /&gt;
----&lt;br /&gt;
'''SPRWHERE,SpriteNumber,@varx%,@vary%'''&lt;br /&gt;
* SpriteNumber=[0..15] varx=Name of x variable vary=Name of y variable&lt;br /&gt;
* Get the x,y coordinates of the specified sprite&lt;br /&gt;
* Important note : varx and vary must be defined first like integer (declaration in basic with '%') and&lt;br /&gt;
* they must be given to the instruction &amp;quot;by address&amp;quot; ('@' before the variable name). The * declaration must&lt;br /&gt;
* be respected to avoid unpredictibles results.&lt;br /&gt;
* Example : 10 VARX%=0: VARY%=0 : SPRWHERE,1,@VARX%,@VARY%: PRINT VARX%,VARY%&lt;br /&gt;
----&lt;br /&gt;
'''SPRSAVE,[SpriteNumber,] BlocNumber, Filename'''&lt;br /&gt;
* SpriteNumber=[0..15] BlocNumber=[0..4] Filename=Name of file in Amsdos standard &lt;br /&gt;
* Save a sprite or a set of 32 sprites (defined as one Block) to disk &lt;br /&gt;
* B-Asic can store 128 sprites definitions more than the usal sprites contained in asic ram. &lt;br /&gt;
* These 128 sprites are organised as 4 sets of 32 sprites named &amp;quot;Block&amp;quot;.  Each block contains 16 fast sprites and 16 slow sprites &lt;br /&gt;
Block &amp;amp; sprites number	Fast Sprites	Slow Sprites&lt;br /&gt;
1 - 0 to 15		16 to 31	80 to 95&lt;br /&gt;
2 - 0 to 15		32 to 47	96 to 111&lt;br /&gt;
3 - 0 to 15		48 to 63	112 to 127&lt;br /&gt;
4 - 0 to 15		64 to 79	128 to 143&lt;br /&gt;
* Bloc 0 is used for the 16 &amp;quot;real&amp;quot; asic sprites. &lt;br /&gt;
* If  SpriteNumber is not precised in the instruction, so a complete block is saved &lt;br /&gt;
* If  SpriteNumber is precised, only two sprites (fast and the slow sprite associated) for the block is saved &lt;br /&gt;
* Example : SPRSAVE,3,2,&amp;quot;SPR3BLK1.BIN&amp;quot; save the sprite fast and slow number 3 of the Bloc 2 (e.g. sprite 35 and sprite 99) in the file named &amp;quot;SPR3BLK1.BIN&amp;quot; &lt;br /&gt;
* Example : SPRSAVE,0,&amp;quot;SPRASIC.BIN&amp;quot; save the content of block 0 (e.g. 16 asic sprites) &lt;br /&gt;
----&lt;br /&gt;
'''SPRLOAD,[SpriteNumber,] BlocNumber, Filename'''&lt;br /&gt;
* SpriteNumber=[0..15] BlocNumber=[0..4] Filename=Name of file in Amsdos standard &lt;br /&gt;
* Load a sprite or a set of 32 sprites (defined as one Block) from disk &lt;br /&gt;
* B-Asic can store 128 sprites definitions more than the usal sprite contained in asic ram. &lt;br /&gt;
* These 128 sprites are organised as 4 sets of 32 sprites named &amp;quot;Block&amp;quot;. &lt;br /&gt;
Block &amp;amp; sprites number	Fast Sprites	Slow Sprites&lt;br /&gt;
1 - 0 to 15		16 to 31	80 to 95&lt;br /&gt;
2 - 0 to 15		32 to 47	96 to 111&lt;br /&gt;
3 - 0 to 15		48 to 63	112 to 127&lt;br /&gt;
4 - 0 to 15		64 to 79	128 to 143&lt;br /&gt;
* Bloc 0 is used for the 16 &amp;quot;real&amp;quot; asic sprites. &lt;br /&gt;
* If  SpriteNumber is not precised in the instruction, so a complete block is loaded &lt;br /&gt;
* If  SpriteNumber is precised, only the specified sprite of the block is loaded &lt;br /&gt;
* Note : If the file specified has an invalid size, an error is displayed &lt;br /&gt;
* Example : SPRLOAD,3,2,&amp;quot;SPR3BLK1.BIN&amp;quot; load the fast and slow sprites 3 of the Bloc 2 (e.g. sprites 35 and 99) from the file &amp;quot;SPR3BLK1.BIN&amp;quot; &lt;br /&gt;
* Example : SPRLOAD,3,&amp;quot;RAAHHHHH.SPR&amp;quot; load the block 3 (e.g. sprites 48 to 63 and sprites 112 to 127) from file &amp;quot;RAAHHHHH.SPR&amp;quot; &lt;br /&gt;
----&lt;br /&gt;
'''SPRLINK,SpriteNumber1,SpriteNumber2,Xrel,Yrel'''&lt;br /&gt;
* SpriteNumberx=[0..15] XRel=[-256..767] YRel=[-256..255]&lt;br /&gt;
* Link a sprite (2) to another sprite (1) with a relative position.&lt;br /&gt;
* That means if sprite (1) is moved, then sprite (2) is moved too.&lt;br /&gt;
* So if sprite 1 is moved in X1,Y1 then the sprite 2 will be moved automatically in X1+Xrel,Y1+Yrel&lt;br /&gt;
* It's possible to link all the sprites in all combinations to create one or more &amp;quot;super sprites&amp;quot;&lt;br /&gt;
* Note : A sprite cannot be linked to itself.&lt;br /&gt;
* Example : SPRLINK,1,2,16,0 link sprite 2 to sprite 1 with a relative x position of 16 pixels&lt;br /&gt;
* Example : SPRLINK,2,5,0,16 link sprite 5 to sprite 2 with a relative y position of 16 pixels&lt;br /&gt;
* [ so move the sprite 1 signify to move sprite 2 and 5 ]&lt;br /&gt;
----&lt;br /&gt;
'''SPRUNLINK,SpriteNumber1,SpriteNumber2'''&lt;br /&gt;
* SpriteNumberx=[0..15]&lt;br /&gt;
* Unlink a sprite from anoter sprite.&lt;br /&gt;
* Example : SPRUNLINK,2,5 erase the link between sprite 2 and 5&lt;br /&gt;
----&lt;br /&gt;
'''ERALINK'''&lt;br /&gt;
* Erase all link&lt;br /&gt;
----&lt;br /&gt;
'''SPRCOLL,NumDef,SpriteNum1,DeltaX1,DeltaY1,SpriteNum2,DeltaX2,DeltaY2,@collision%, PixelPerfect'''&lt;br /&gt;
'''SPRCOLL, NoDef, 255'''&lt;br /&gt;
'''SPRCOLL'''&lt;br /&gt;
* Process the collision test between two sprites automatically or manually&lt;br /&gt;
* NumDef = [0..7] (8 collisions can be processed simultaneously) SpriteNum1=[0..15] &lt;br /&gt;
* DeltaXn=[0..255], DeltaYn=[0..255] : Number of pixels in mode 2 definition from sprite coordinate defining the zone to test collision. This method is useful to extend the collision to a super sprite or to restrict collision to only a part of a sprite or supersprite. &lt;br /&gt;
* PixelPerfect is not used actually&lt;br /&gt;
* @collision% : This variable take the value 1 when a collision is detected between 2 sprites. The user must set the value to 0 to reset the collision detection.&lt;br /&gt;
&lt;br /&gt;
'''VERY IMPORTANT''' : The variable collision must be defined like an integer (déclaration by initialisation with %), and the variable must be given to function by address (e.g. @ ou à (on french keyboard) before the variable name).&lt;br /&gt;
Example : collision%=0  used in function like @collision%&lt;br /&gt;
When SPRCOLL is used with all parameters, the collision process is automatic, and so independant of locomotive basic program. But it's possible to control manually each collision test using the instruction without parameters (at this time, the automatic mode is disactivated). If the user wants to cancel a collision process, he must use the instruction with 2 parameters  : SPRCOLL,NumDef,255 (This will help the cpu ;-)) &lt;br /&gt;
 &lt;br /&gt;
'''WARNING about SPRCOLL:'''&lt;br /&gt;
SPRCOLL use a locomotive basic variable given by address. And this address is stored by B-Asic when SPRCOLL is called with all parameters. So the user needs ABSOLUTLY keep in mind the two following situation :&lt;br /&gt;
* When SPRCOLL is used in automatic mode (e.g B-Asic store automatically the collision test result at each frame), you  must absolutly replace the instruction in manual mode (by using SPRCOLL without parameter) before to modify your basic program because the variable is stored and moved in the basic area.&lt;br /&gt;
* When you have just stopped your basic program, NEVER modify the program and do a GOTO through a SPRCOLL instruction used without parameters. (the SPRCOLL must be called before with all parameters to give to B-Asic the new address of the variable)&lt;br /&gt;
'''You must respect ABSOLUTLY these 2 rules to avoid a destruction of some part of your basic program. (I will solve the problem of first case later.''' I need to know when the locomotive basic interpreter is not running. Help appreciate)&lt;br /&gt;
----&lt;br /&gt;
'''DEFORGXY,SpriteNumber,XPos,YPos'''&lt;br /&gt;
* SpriteNumber=[0..15] XPos=[-256..767] YPos=[-256..255]&lt;br /&gt;
* Define absolute origin position of the specified sprite&lt;br /&gt;
* That means that real sprite position take care of this defined coordinates.&lt;br /&gt;
* Example : DEFORGXY,1,10,20:SPRXY,1,5,3 display sprite at 15,23&lt;br /&gt;
* Note : It's possible to define an origin position for a sprite following a path (see SPRTDEF)&lt;br /&gt;
* The default of origin at B-Asic reset is 0,0&lt;br /&gt;
----&lt;br /&gt;
'''DEFORGSPR,SpriteSlave,SpriteMaster'''&lt;br /&gt;
* SpriteSlave=[0..15] SpriteMaster=[0..15]&lt;br /&gt;
* Define the origin position of SpriteSlave with the position of SpriteMaster.&lt;br /&gt;
* Note : It's possible to define a sprite relative position for a sprite following a path (see SPRTDEF)&lt;br /&gt;
* It's possible to generate complex definitions of sprites movments.&lt;br /&gt;
* If a sprite 1 use a path 1 and a sprite 2 use a path 2, if the sprite 2 is the slave of sprite 1, then&lt;br /&gt;
* the path 2 will be relative to path 1.&lt;br /&gt;
* To erase the slavery of a sprite, use DEFORGXY instruction&lt;br /&gt;
----&lt;br /&gt;
'''DEFKBDSPR, NumDef, SpriteNumber, KeyUp, StepUp, KeyDown, StepDown, KeyLeft, StepLeft, KeyRight, StepRight'''&lt;br /&gt;
'''DEFKBDSPR,NumDef,255'''&lt;br /&gt;
'''DEFKBDSPR'''&lt;br /&gt;
* Associate the sprite coordinates to keyboard keys&lt;br /&gt;
* NumDef =[0..1] It's possible to define keys for 2 sprites /  SpriteNumber=[0..15] Sprite number / Keyxxxxx=[Key number] (see table), Stepxxxx=value 0..255 : Step in mode 2 pixel to add or substract associated value to corresponding key.&lt;br /&gt;
* A key 0 indicate to do not test the key. When DEFKBDSPR is defined with all parameters, the sprite process is automatic, and so independent from basic program. It is possible to control manually the sprite movment by using the instruction without parameters (the automatic mode is disactivated). &lt;br /&gt;
* Note : If the user wants to cancel a definition, it's better to disactivate the sprite with DEFKBDSPR,NumDef,255 instead of defining all keys with 0 (The B-Asic will gain cpu-speed).&lt;br /&gt;
---&lt;br /&gt;
=== Others Instructions Set ===&lt;br /&gt;
----&lt;br /&gt;
'''POKEASIC,Address,val1,...,valx'''&lt;br /&gt;
* Address=[&amp;amp;4000..&amp;amp;7FFF] Valx=[&amp;amp;00..&amp;amp;FF]&lt;br /&gt;
* Poke one or more bytes in Asic I/O page&lt;br /&gt;
* Instruction reserved to experimented users.&lt;br /&gt;
----&lt;br /&gt;
'''POKEVR,Address,val1,...,valn'''&lt;br /&gt;
* Address=[&amp;amp;4000..&amp;amp;7FFF] Valx=[&amp;amp;00..&amp;amp;FF]&lt;br /&gt;
* Poke one or more bytes in second video page&lt;br /&gt;
* Instruction reserved to experimented users.&lt;br /&gt;
----&lt;br /&gt;
'''DOKE,Address,value16bits'''&lt;br /&gt;
* Address=[&amp;amp;4000..&amp;amp;7FFF] value16bits=[&amp;amp;0000..&amp;amp;FFFF] &lt;br /&gt;
* Double Poke in user memory &lt;br /&gt;
---- &lt;br /&gt;
'''SCREENCOPY,direction '''&lt;br /&gt;
* direction=[0..1] &lt;br /&gt;
* 0 : Copy the main videoram  to videoram 2&lt;br /&gt;
* 1 : Copy the videoram2 to main videoram&lt;br /&gt;
&lt;br /&gt;
== Error Messages ==&lt;br /&gt;
'''Bad arguments number'''&lt;br /&gt;
* Bad number of arguments used in the instruction&lt;br /&gt;
&lt;br /&gt;
'''Invalid Argument'''&lt;br /&gt;
* An invalid value is used in one or more arguments of the instruction&lt;br /&gt;
&lt;br /&gt;
'''Invalid Filename'''&lt;br /&gt;
* A bad filename was used in a SPRSAVE or SPRLOAD instruction&lt;br /&gt;
&lt;br /&gt;
'''Disc Error'''&lt;br /&gt;
* An I/O error has occured in a SPRSAVE or SPRLOAD instruction.&lt;br /&gt;
* Disc is missing, or the disk has a wrong or damaged format.&lt;br /&gt;
&lt;br /&gt;
'''Not a Sprite file'''&lt;br /&gt;
* The size of the file specified in SPRLOAD is not correct.&lt;br /&gt;
* See if you do no use the SPRLOAD with a block instead of a single sprite (or the opposite)&lt;br /&gt;
&lt;br /&gt;
'''Same Sprites Numbers'''&lt;br /&gt;
* An instruction SPRLINK or SPRUNLINK is attempted with 2 identical sprite numbers.&lt;br /&gt;
&lt;br /&gt;
'''Bad Graphic Mode'''&lt;br /&gt;
* Instruction CATCH is not used in MODE 0&lt;br /&gt;
&lt;br /&gt;
'''Invalid Moving List'''&lt;br /&gt;
* An invalid table is created for SPRTDEF &lt;br /&gt;
* (e.g. the first coordinate is the path end)&lt;br /&gt;
&lt;br /&gt;
'''Link Table Full'''&lt;br /&gt;
* The link table is full.&lt;br /&gt;
* Normally this error cannot occur in a well built program.&lt;br /&gt;
&lt;br /&gt;
'''Sprites not Linked'''&lt;br /&gt;
* Instruction SPRUNLINK is used with sprites not linked.&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
[http://logon.system.free.fr/html/downloadlogon.htm Download B-Asic]&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming software]]&lt;br /&gt;
[[Category:CPC Plus]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Rex&amp;diff=101545</id>
		<title>Rex</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Rex&amp;diff=101545"/>
				<updated>2018-04-21T16:52:55Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Image:rex.jpg|thumb|Rex as he usually was, 10 years ago (!)]]&lt;br /&gt;
&lt;br /&gt;
'''Rex''' is a graphic artist of the greek CPC scene.&lt;br /&gt;
&lt;br /&gt;
== Groups ==&lt;br /&gt;
&lt;br /&gt;
* [[BENG!]]&lt;br /&gt;
&lt;br /&gt;
== Productions ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* [[Prehistorik 2]] (intro screen only)&lt;br /&gt;
* [[Mega Blasters]] (game)&lt;br /&gt;
* [[Painting Fantasy]] (slide show)&lt;br /&gt;
* [[S.E.X]] (discmag)&lt;br /&gt;
* [[Amstrad Expo 2010]] (slide show)&lt;br /&gt;
* [[Relentless]] game&lt;br /&gt;
* [[Megablasters : Escape From Castle In The Clouds]] (game)&lt;br /&gt;
* [[Dragon Attack]] (game)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
plus many other contributions in various productions:&lt;br /&gt;
&lt;br /&gt;
* [[30 Years Amstrad Megademo]] megademo&lt;br /&gt;
* [[Bombastic]] demo&lt;br /&gt;
* [[Color Lines]] game&lt;br /&gt;
* [[Edge Grinder]] game&lt;br /&gt;
* [[ReAct 2003]] (slide show)&lt;br /&gt;
* [[ReSeT 0 - Outer World Music]] music&lt;br /&gt;
* [[Ze Meeting 2003]] demo&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:cimg0709.jpg|thumb|Rex today]]&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC scene members]]&lt;br /&gt;
[[Category:Stub]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Rex&amp;diff=101544</id>
		<title>Rex</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Rex&amp;diff=101544"/>
				<updated>2018-04-21T16:51:20Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Production */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Image:rex.jpg|thumb|Rex as he usually was, 10 years ago (!)]]&lt;br /&gt;
&lt;br /&gt;
'''Rex''' is a graphic artist of the greek CPC scene.&lt;br /&gt;
&lt;br /&gt;
== Groups ==&lt;br /&gt;
&lt;br /&gt;
* [[BENG!]]&lt;br /&gt;
&lt;br /&gt;
== Production ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* [[Prehistorik 2]] (intro screen only)&lt;br /&gt;
* [[Mega Blasters]] (game)&lt;br /&gt;
* [[Painting Fantasy]] (slide show)&lt;br /&gt;
* [[S.E.X]] (discmag)&lt;br /&gt;
* [[Amstrad Expo 2010]] (slide show)&lt;br /&gt;
* [[Relentless]] game&lt;br /&gt;
* [[Megablasters : Escape From Castle In The Clouds]] (game)&lt;br /&gt;
* [[Dragon Attack]] (game)&lt;br /&gt;
&lt;br /&gt;
plus many other contributions in various productions:&lt;br /&gt;
* [[30 Years Amstrad Megademo]] megademo&lt;br /&gt;
* [[Bombastic]] demo&lt;br /&gt;
* [[Color Lines]] game&lt;br /&gt;
* [[Edge Grinder]] game&lt;br /&gt;
* [[ReAct 2003]] (slide show)&lt;br /&gt;
* [[ReSeT 0 - Outer World Music]] music&lt;br /&gt;
* [[Ze Meeting 2003]] demo&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:cimg0709.jpg|thumb|Rex today]]&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC scene members]]&lt;br /&gt;
[[Category:Stub]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Digiblaster&amp;diff=101461</id>
		<title>Digiblaster</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Digiblaster&amp;diff=101461"/>
				<updated>2018-04-08T10:48:43Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Utilities */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The '''Digiblaster''' is a small hardware device plugged into the CPC's printer port to play 8-bit mono sound samples. It was designed by [[Face Hugger]] and printed in the German magazine [[CPC Amstrad International]] in issue 8-9/1991. In 1995(?) [[Joshua]] made a redesign for better sound quality. [[Bryce]] made a redesign with even better sound quality.&lt;br /&gt;
&lt;br /&gt;
== Software supporting the Digiblaster ==&lt;br /&gt;
&lt;br /&gt;
=== Demos ===&lt;br /&gt;
&lt;br /&gt;
* [[Bordelik Demo 4]] (1995) &lt;br /&gt;
* [[Digital Orgasm]] (by [[Prodatron]]) (1994) &lt;br /&gt;
* Meg Ryan Sample (by [[TFM]] of [[FutureSoft]]) &lt;br /&gt;
* Start Trek Sample (by TFM of FutureSoft)&lt;br /&gt;
&lt;br /&gt;
=== Utilities ===&lt;br /&gt;
&lt;br /&gt;
* [[Cocoon Player]] (by [[One]]) (1995) &lt;br /&gt;
* [[Digitracker]] (by Prodatron) (1993) &lt;br /&gt;
* [[FuturePlayer]] (by TFM of FutureSoft)&lt;br /&gt;
* [[Octwaver]] (by [[OCT]]) (1994)&lt;br /&gt;
* [[Protracker]] (by [[Crown]]) (1993)&lt;br /&gt;
* [[The Drumming CPC]] (by Andreas Stroiczek, aka Face Hugger) - published as a listing in [[CPC Amstrad International, 1992, Issue 4|issue 4/5'92]] of [[CPC Schneider International|CPC Amstrad International]], and on the DATABOX cassette/disc for that issue&lt;br /&gt;
&lt;br /&gt;
=== OS ===&lt;br /&gt;
* [[FutureOS]]&lt;br /&gt;
&lt;br /&gt;
== DigiBlaster V2 ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;Soundplayer pictures (a Digiblaster based card by [[Futurs']])&amp;quot;&amp;gt;&lt;br /&gt;
Image:soundplayer 2.JPG|The Soundplayer for classic CPCs&lt;br /&gt;
Image:soundplayer 3.JPG|The Soundplayer+ for CPC+&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*[http://cepece.info/amstrad/docs/digibl.html Schematics and additional information (Versions 1 + 2]&lt;br /&gt;
&lt;br /&gt;
== DigiBlaster V3  ==&lt;br /&gt;
&lt;br /&gt;
The main difference with this version of DigiBlaster is the additional Line-in connector which allows the user to feed the AY output through the card so that both sound sources are played through the same speakers. The DigiBlaster has been made dual-mono so that both speakers play the sample as is done with the AY-3-8912 Channel B. The variable resistor RV1 adjusts the Digiblasters output level to balance it to the AY level. Unlike V1 + 2, which can be used with a passive mono speaker, the output of V3 has been brought down to Line-out levels and so should be connected to active stereo speakers.&lt;br /&gt;
&lt;br /&gt;
[[Image:DigiBlaster3_Schematic.PNG|600px|centre]]&lt;br /&gt;
&lt;br /&gt;
The diodes in the original version have been removed, because they served no meaningful purpose and an R2R ladder design was used for the DA conversion. This not only improves the linearity of the DAC greatly, but also ensures that the output impedance remains stable and of course means not having to buy 8 or 9 different non-standard value resistors. Pin 14 has also been chosen as ground instead of pin 9 to make it compatible with printer ports that have been converted to 8-Bit. The completed devices look like this:&lt;br /&gt;
&lt;br /&gt;
[[Image:DigiBlaster3_Types.jpg|700px|centre]]&lt;br /&gt;
&lt;br /&gt;
Track layouts have been made for both Centronics and Edge-connector. As seen in the picture above, the layouts use isolation displacement connectors (the type usually intended for flat cable) which have been modified (ie: the plastic band and clips removed) so that it can be mounted directly to the PCB. 1.5mm FR4 PCB should be used preferably to give the circuit stability.&lt;br /&gt;
&lt;br /&gt;
== Resources ==&lt;br /&gt;
&lt;br /&gt;
[[File:DB3_Edge_Layout.pdf]]  - PCB Track Layout for Edge Connector Version&lt;br /&gt;
&lt;br /&gt;
[[File:DB3_Cent_Layout.pdf]]  - PCB Track Layout for Centronics Connector Version&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[Digiblaster howto]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Digiblaster]]&lt;br /&gt;
[[Category:DIY]] &lt;br /&gt;
[[Category:FutureOS]] &lt;br /&gt;
[[Category:Music_and_sound]]&lt;br /&gt;
[[Category:Peripherals]] &lt;br /&gt;
[[Category:Printers and printer ports]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems_MIDI_Interface&amp;diff=101460</id>
		<title>Silicon Systems MIDI Interface</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems_MIDI_Interface&amp;diff=101460"/>
				<updated>2018-04-08T10:47:46Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Silicon Systems MIDI Interface ==&lt;br /&gt;
&lt;br /&gt;
A [[MIDI]] interface for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Software =&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
File:Silicon Systems DX7.jpg|Review in AA issue 26&lt;br /&gt;
File:Silicon Systems ESQ1 Data Dump, Editor &amp;amp; Sequencer.jpg|Review in AA issue 27&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Music and sound]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101459</id>
		<title>Dhcp electronics</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101459"/>
				<updated>2018-04-08T10:44:48Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== DHCP Electronics ==&lt;br /&gt;
&lt;br /&gt;
Creator of various [[MIDI]] hardware addons along with software for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Hardware ==&lt;br /&gt;
[[DHCP MIDI Interface]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Software ==&lt;br /&gt;
&lt;br /&gt;
*  [[Casio CZ101 Voice Editor]]&lt;br /&gt;
*  [[8 Track MIDI Sequencer]]&lt;br /&gt;
&lt;br /&gt;
== Review in Amstrad Action ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
Image:DHCP software AA.jpg|Revies in Amstrad Action issue 33&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Music and sound]] [[Category:Serial interfaces]]&lt;br /&gt;
[[Category:CPC related companies]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems_MIDI_Interface&amp;diff=101458</id>
		<title>Silicon Systems MIDI Interface</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems_MIDI_Interface&amp;diff=101458"/>
				<updated>2018-04-08T10:43:35Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Created page with &amp;quot;== Silicon Systems MIDI Interface ==  A MIDI interface for Amstrad CPC.   = Software = &amp;lt;gallery&amp;gt; File:Silicon Systems DX7.jpg|Review in AA issue 26 File:Silicon Systems ES...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Silicon Systems MIDI Interface ==&lt;br /&gt;
&lt;br /&gt;
A [[MIDI]] interface for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Software =&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
File:Silicon Systems DX7.jpg|Review in AA issue 26&lt;br /&gt;
File:Silicon Systems ESQ1 Data Dump, Editor &amp;amp; Sequencer.jpg|Review in AA issue 27&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=File:Silicon_Systems_ESQ1_Data_Dump,_Editor_%26_Sequencer.jpg&amp;diff=101457</id>
		<title>File:Silicon Systems ESQ1 Data Dump, Editor &amp; Sequencer.jpg</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=File:Silicon_Systems_ESQ1_Data_Dump,_Editor_%26_Sequencer.jpg&amp;diff=101457"/>
				<updated>2018-04-08T10:40:03Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Silicon Systems' software for ESQ1 review in Amstrad Action, Issue 27, December 1987&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Silicon Systems' software for ESQ1 review in Amstrad Action, Issue 27, December 1987&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=File:Silicon_Systems_DX7.jpg&amp;diff=101456</id>
		<title>File:Silicon Systems DX7.jpg</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=File:Silicon_Systems_DX7.jpg&amp;diff=101456"/>
				<updated>2018-04-08T10:34:55Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Review in Amstrad Action, Issue 26, November 1987&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Review in Amstrad Action, Issue 26, November 1987&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems&amp;diff=101455</id>
		<title>Silicon Systems</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Silicon_Systems&amp;diff=101455"/>
				<updated>2018-04-08T10:30:49Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Products */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Silicon Systems''' was a company that manufactured hardware for the CPC&lt;br /&gt;
&lt;br /&gt;
== Products ==&lt;br /&gt;
&lt;br /&gt;
* [[AMRAM]]&lt;br /&gt;
* [[AMRAM2]]&lt;br /&gt;
* [[AMDRIVE]] - Second 3&amp;quot; disc drive (according to adverts in 1/87 and 12/86, it was featured &amp;quot;last month&amp;quot; in ACU)&lt;br /&gt;
* [[MEGADRIVE]]&lt;br /&gt;
* [[AMSCASE]]&lt;br /&gt;
* [[Silicon Systems MIDI Interface]]&lt;br /&gt;
&lt;br /&gt;
== Adverts ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
File:ACU8701034.jpg|Advert (ACU, January 1987)&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC related companies]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=EMR_MIDI_Interface&amp;diff=101454</id>
		<title>EMR MIDI Interface</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=EMR_MIDI_Interface&amp;diff=101454"/>
				<updated>2018-04-08T10:29:44Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Other MIDI solutions for the CPC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A [[MIDI]] Interface for the Amstrad CPC.&lt;br /&gt;
Manufactured by the British company [[EMR]] (Electro Music Research).&lt;br /&gt;
&lt;br /&gt;
== Technical specs ==&lt;br /&gt;
&lt;br /&gt;
== Software using the EMR Interface ==&lt;br /&gt;
&lt;br /&gt;
[[EMR Miditrack Performer]]&lt;br /&gt;
&lt;br /&gt;
== Other MIDI solutions for the CPC ==&lt;br /&gt;
&lt;br /&gt;
* [[Music Machine]] (Sampling/Playback/MIDI)&lt;br /&gt;
* [[DHCP_MIDI_Interface]]&lt;br /&gt;
* [[Silicon Systems MIDI interface]]&lt;br /&gt;
&lt;br /&gt;
== Reviews ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
image:Amstrad Computer User8608042.jpg|ACU Aug.1986 1/3&lt;br /&gt;
image:Amstrad Computer User8608043.jpg|ACU Aug.1986 2/3&lt;br /&gt;
image:Amstrad Computer User8608044.jpg|ACU Aug.1986 3/3&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
image:CWTA-AE-Aug87Page58.JPG|CWTA-AE- Aug.1987 1/5&lt;br /&gt;
image:CWTA-AE-Aug87Page59.JPG|CWTA-AE- Aug.1987 2/5&lt;br /&gt;
image:CWTA-AE-Aug87Page60.JPG|CWTA-AE- Aug.1987 3/5&lt;br /&gt;
image:CWTA-AE-Aug87Page61.JPG|CWTA-AE- Aug.1987 4/5&lt;br /&gt;
image:CWTA-AE-Aug87Page62.JPG|CWTA-AE- Aug.1987 5/5&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Pictures ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;EMR Midi Interface&amp;quot;&amp;gt;&lt;br /&gt;
Image:emr midi 1.JPG|&lt;br /&gt;
Image:emr midi 2.JPG|Connectors&lt;br /&gt;
Image:emr midi 3.JPG|Top view&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
File:Amstrad EMR MIDI Track.jpg&lt;br /&gt;
File:Emr midi performer 1.png&lt;br /&gt;
File:Emr midi performer 2.png&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
File:EMR_MIDI_Interface_Box.jpg|Box&lt;br /&gt;
File:EMR_MIDI_Interface_Top.jpg|Interface Top&lt;br /&gt;
File:EMR_MIDI_Interface_Bottom.jpg|Interface Bottom&lt;br /&gt;
File:EMR_MIDI_Interface_Front.jpg|Interface Front&lt;br /&gt;
File:EMR_MIDI_Interface_PCB_Top.jpg|PCB Top&lt;br /&gt;
File:EMR_MIDI_Interface_PCB_Bottom.jpg|PCB Bottom&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Advertisements ==&lt;br /&gt;
* [[Amstrad Computer User]] (June 1986):&lt;br /&gt;
[[image:EMR ACU ad June1986.jpg|thumb|none]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== I/O Ports ==&lt;br /&gt;
&lt;br /&gt;
Uses port #F8F2&lt;br /&gt;
&lt;br /&gt;
[[Category:Serial interfaces]] [[Category:Music and sound]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101453</id>
		<title>Dhcp electronics</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101453"/>
				<updated>2018-04-08T10:20:21Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Review in Amstrad Action */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== DHCP Electronics ==&lt;br /&gt;
&lt;br /&gt;
Creator of various [[MIDI]] hardware addons along with software for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Hardware ==&lt;br /&gt;
[[DHCP MIDI Interface]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Software ==&lt;br /&gt;
&lt;br /&gt;
*  [[Casio CZ101 Voice Editor]]&lt;br /&gt;
*  [[8 Track MIDI Sequencer]]&lt;br /&gt;
&lt;br /&gt;
== Review in Amstrad Action ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
Image:DHCP software AA.jpg|Revies in Amstrad Action issue 33&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Music and sound]] [[Category:Serial interfaces]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=File:DHCP_software_AA.jpg&amp;diff=101452</id>
		<title>File:DHCP software AA.jpg</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=File:DHCP_software_AA.jpg&amp;diff=101452"/>
				<updated>2018-04-08T10:17:22Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: DHCP software review in Amstrad Action, Issue 33, June 1988&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;DHCP software review in Amstrad Action, Issue 33, June 1988&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101451</id>
		<title>Dhcp electronics</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101451"/>
				<updated>2018-04-08T10:14:36Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Software */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== DHCP Electronics ==&lt;br /&gt;
&lt;br /&gt;
Creator of various [[MIDI]] hardware addons along with software for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Hardware ==&lt;br /&gt;
[[DHCP MIDI Interface]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Software ==&lt;br /&gt;
&lt;br /&gt;
*  [[Casio CZ101 Voice Editor]]&lt;br /&gt;
*  [[8 Track MIDI Sequencer]]&lt;br /&gt;
&lt;br /&gt;
== Review in Amstrad Action ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Music and sound]] [[Category:Serial interfaces]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101450</id>
		<title>Dhcp electronics</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Dhcp_electronics&amp;diff=101450"/>
				<updated>2018-04-08T10:11:38Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Created page with &amp;quot;== DHCP Electronics ==  Creator of various MIDI hardware addons along with software for Amstrad CPC.    == Hardware == DHCP MIDI Interface   == Software ==  Casio CZ...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== DHCP Electronics ==&lt;br /&gt;
&lt;br /&gt;
Creator of various [[MIDI]] hardware addons along with software for Amstrad CPC.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Hardware ==&lt;br /&gt;
[[DHCP MIDI Interface]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Software ==&lt;br /&gt;
&lt;br /&gt;
[[Casio CZ101 Voice Editor]]&lt;br /&gt;
[[8 Track MIDI Sequencer]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Review in Amstrad Action ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Music and sound]] [[Category:Serial interfaces]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99687</id>
		<title>CNGSoft</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99687"/>
				<updated>2017-10-21T07:48:38Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Tools */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''CNGSoft''' (César Nicolás González) is the Spanish programmer who has been writing and releasing versions of the emulator [[CPCE]] since August 1st 1997.&lt;br /&gt;
&lt;br /&gt;
His other especially notable project is ''[[BB4CPC]]''[http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311], an enhanced remake of ''[[Bubble Bobble]]'' for the CPC. The system already had a CPC version released during its official heyday, but many players felt that it was not as good a port as it could have been; CNGSoft, being a big fan of the ''Bubble Bobble''/''[[Rainbow Islands]]'' franchise, wanted to release a version that took more advantage of the Amstrad's hardware and provided the best experience possible.&lt;br /&gt;
&lt;br /&gt;
He has made a very interesting tool for the CPC, LZ2PACKER, a [http://en.wikipedia.org/wiki/Self-extracting_archive self-extracting archive], as seen in the binary [ftp://ftp.nvg.ntnu.no/pub/cpc/games/arcade/jetsetff.zip JSW2]. The compression method is based on [http://genesis8.free.fr/frontend/misc/demopack.zip Demoniak's packer] and fully compatible with it.&lt;br /&gt;
&lt;br /&gt;
His most quoted ''excusatio non petita'' is &amp;quot;English isn't my first language, I apologize for using it so poorly.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Releases==&lt;br /&gt;
&lt;br /&gt;
===Games===&lt;br /&gt;
* ''[[Justin]]''&lt;br /&gt;
* ''[[BB4CPC]]''&lt;br /&gt;
* ''[[Frogalot]]''&lt;br /&gt;
* ''[[Hire Hare]]''&lt;br /&gt;
&lt;br /&gt;
===Emulator===&lt;br /&gt;
* [[CPCE]]&lt;br /&gt;
&lt;br /&gt;
===Tools===&lt;br /&gt;
* [[LZ2PACKER]] (see above)&lt;br /&gt;
* [[CSW2CDT]]&lt;br /&gt;
* [[CHIPNSFX]]&lt;br /&gt;
&lt;br /&gt;
==Links==&lt;br /&gt;
* [http://cngsoft.no-ip.org/ Homepage]&lt;br /&gt;
* [http://cngsoft.no-ip.org/cng_bb4cpc.htm Home of ''BB4CPC'']&lt;br /&gt;
* [http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311 Topic on the CPC Wiki's forum about the release of ''BB4CPC'']&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC scene members]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99686</id>
		<title>CNGSoft</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99686"/>
				<updated>2017-10-21T07:45:30Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Games */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''CNGSoft''' (César Nicolás González) is the Spanish programmer who has been writing and releasing versions of the emulator [[CPCE]] since August 1st 1997.&lt;br /&gt;
&lt;br /&gt;
His other especially notable project is ''[[BB4CPC]]''[http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311], an enhanced remake of ''[[Bubble Bobble]]'' for the CPC. The system already had a CPC version released during its official heyday, but many players felt that it was not as good a port as it could have been; CNGSoft, being a big fan of the ''Bubble Bobble''/''[[Rainbow Islands]]'' franchise, wanted to release a version that took more advantage of the Amstrad's hardware and provided the best experience possible.&lt;br /&gt;
&lt;br /&gt;
He has made a very interesting tool for the CPC, LZ2PACKER, a [http://en.wikipedia.org/wiki/Self-extracting_archive self-extracting archive], as seen in the binary [ftp://ftp.nvg.ntnu.no/pub/cpc/games/arcade/jetsetff.zip JSW2]. The compression method is based on [http://genesis8.free.fr/frontend/misc/demopack.zip Demoniak's packer] and fully compatible with it.&lt;br /&gt;
&lt;br /&gt;
His most quoted ''excusatio non petita'' is &amp;quot;English isn't my first language, I apologize for using it so poorly.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Releases==&lt;br /&gt;
&lt;br /&gt;
===Games===&lt;br /&gt;
* ''[[Justin]]''&lt;br /&gt;
* ''[[BB4CPC]]''&lt;br /&gt;
* ''[[Frogalot]]''&lt;br /&gt;
* ''[[Hire Hare]]''&lt;br /&gt;
&lt;br /&gt;
===Emulator===&lt;br /&gt;
* [[CPCE]]&lt;br /&gt;
&lt;br /&gt;
===Tools===&lt;br /&gt;
* LZ2PACKER (see above)&lt;br /&gt;
&lt;br /&gt;
==Links==&lt;br /&gt;
* [http://cngsoft.no-ip.org/ Homepage]&lt;br /&gt;
* [http://cngsoft.no-ip.org/cng_bb4cpc.htm Home of ''BB4CPC'']&lt;br /&gt;
* [http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311 Topic on the CPC Wiki's forum about the release of ''BB4CPC'']&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC scene members]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99685</id>
		<title>CNGSoft</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=CNGSoft&amp;diff=99685"/>
				<updated>2017-10-21T07:44:48Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Games */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''CNGSoft''' (César Nicolás González) is the Spanish programmer who has been writing and releasing versions of the emulator [[CPCE]] since August 1st 1997.&lt;br /&gt;
&lt;br /&gt;
His other especially notable project is ''[[BB4CPC]]''[http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311], an enhanced remake of ''[[Bubble Bobble]]'' for the CPC. The system already had a CPC version released during its official heyday, but many players felt that it was not as good a port as it could have been; CNGSoft, being a big fan of the ''Bubble Bobble''/''[[Rainbow Islands]]'' franchise, wanted to release a version that took more advantage of the Amstrad's hardware and provided the best experience possible.&lt;br /&gt;
&lt;br /&gt;
He has made a very interesting tool for the CPC, LZ2PACKER, a [http://en.wikipedia.org/wiki/Self-extracting_archive self-extracting archive], as seen in the binary [ftp://ftp.nvg.ntnu.no/pub/cpc/games/arcade/jetsetff.zip JSW2]. The compression method is based on [http://genesis8.free.fr/frontend/misc/demopack.zip Demoniak's packer] and fully compatible with it.&lt;br /&gt;
&lt;br /&gt;
His most quoted ''excusatio non petita'' is &amp;quot;English isn't my first language, I apologize for using it so poorly.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Releases==&lt;br /&gt;
&lt;br /&gt;
===Games===&lt;br /&gt;
* ''[[Justin]]''&lt;br /&gt;
* ''[[BB4CPC]]''&lt;br /&gt;
* ''[[Frogalot]]''&lt;br /&gt;
* ''[[Hirehare]]''&lt;br /&gt;
&lt;br /&gt;
===Emulator===&lt;br /&gt;
* [[CPCE]]&lt;br /&gt;
&lt;br /&gt;
===Tools===&lt;br /&gt;
* LZ2PACKER (see above)&lt;br /&gt;
&lt;br /&gt;
==Links==&lt;br /&gt;
* [http://cngsoft.no-ip.org/ Homepage]&lt;br /&gt;
* [http://cngsoft.no-ip.org/cng_bb4cpc.htm Home of ''BB4CPC'']&lt;br /&gt;
* [http://www.cpcwiki.eu/forum/games/bubble-bobble-remake-(bb4cpc)/msg36311/#msg36311 Topic on the CPC Wiki's forum about the release of ''BB4CPC'']&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC scene members]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Sprites_Multiplexing&amp;diff=97329</id>
		<title>Sprites Multiplexing</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Sprites_Multiplexing&amp;diff=97329"/>
				<updated>2017-02-26T09:56:02Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Examples of Sprites Multiplexing on an Amstrad Plus */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Sprites Multiplexing is a technic often used on other machines with Hardware Sprite Capability. &lt;br /&gt;
&lt;br /&gt;
It was often used on the [[Commodore 64|C64]].&lt;br /&gt;
&lt;br /&gt;
On the Amstrad [[Plus]] range, it couldn't be used as well. But some possibilities exist.&lt;br /&gt;
&lt;br /&gt;
It allows to &amp;quot;Multiplex&amp;quot; the same Sprite at different rasters lines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Limitations of Sprites Multiplexing on Amstrad Plus==&lt;br /&gt;
&lt;br /&gt;
The technic impose some limitations due to the somewhat unachieved design of the Amstrad Plus and the complex specificity of the [[ASIC]] :&lt;br /&gt;
&lt;br /&gt;
* The same Sprite is simply copied/duplicated as it is.&lt;br /&gt;
* No multiplexed sprites can be at the same Line.&lt;br /&gt;
&lt;br /&gt;
Multiplexing on the PLUS is much more difficult than on the C64. The reason is that the location for the graphics are fixed on the PLUS. e.g. Sprite 0 always looks at &amp;amp;4000 in the ASIC sprite RAM. This can't be changed.&lt;br /&gt;
&lt;br /&gt;
On the PLUS however you can freely change the X,Y position so it is possible to perform some multiplexing of the sprites.&lt;br /&gt;
&lt;br /&gt;
Another way to multiplex sprites is to use screen rupture, because the sprite X,Y coordinate is based on the CRTC's Raster and Line Counter.&lt;br /&gt;
&lt;br /&gt;
==Possible uses==&lt;br /&gt;
&lt;br /&gt;
This can then be used for games like Shoot'emups... as the sprites don't always need to be well animated (just moved) and as enemies waves are often pre-determined (R-Type is the typical example).&lt;br /&gt;
&lt;br /&gt;
So it fit well for Vertical Waves of enemies.&lt;br /&gt;
&lt;br /&gt;
Also for vertical or even diagonal special effects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Examples of Sprites Multiplexing on an Amstrad Plus ==&lt;br /&gt;
 &lt;br /&gt;
This Technic wasn't really exploited on the amstrad Plus, mainly because the Amstrad Plus wasn't really exploited.&lt;br /&gt;
&lt;br /&gt;
* [[Black Sabbath]] by [[BDC-Iron]] (first harwired sprites multiplexing demo as claimed by its author)&lt;br /&gt;
*[[ Delirium Tremens]] preview by BDC-Iron (32 Harware sprites per line with actually only 8 sprites slots used)&lt;br /&gt;
&lt;br /&gt;
* [[Synergy]] demo. by [[AsT/Impact]]  (ndAsT : Yes this demo uses Sprites Multiplexing ! For example, the wobbler only uses 1 sprite line !!!... and have you ever count the balls displayed on the screen ?)&lt;br /&gt;
*[[XMas 2008 Dentro]] by [[AsT/impact]] (The christmas balls are composed of 4 sprites... copied 4 times on your screen)&lt;br /&gt;
* Probably [[It was so nice before the crash of the mir station]]&lt;br /&gt;
&lt;br /&gt;
In games, [[Prehistorik 2]] by [[Titus Software]] uses sprite multiplexing for the (second) big cloud/rocks that appear in the front. Did you notice that there are always 2 identical big clouds/rocks on screen at once..? Each one is drawn using all 16 hardware sprites.&lt;br /&gt;
&lt;br /&gt;
==Video==&lt;br /&gt;
&lt;br /&gt;
*Sprite Multiplexing on C64 : http://www.youtube.com/watch?v=oyf2W239eRY&lt;br /&gt;
*Synergy Demo on Amstrad Plus : http://www.youtube.com/watch?v=YGH5JIPWQ2I&lt;br /&gt;
&lt;br /&gt;
==Other Sources and links ==&lt;br /&gt;
&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites]]&lt;br /&gt;
&lt;br /&gt;
*[http://codebase64.org/doku.php?id=base:sprite_multiplexing Sprite Multiplexing Article at a C64wiki]&lt;br /&gt;
*[http://lywenn.eu.org/projets/mtpx/mtpx.pdf Sprite Multiplexing project on Nintendo DS]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC Plus]][[Category:Programming]][[Category:Graphic]][[Category:Stub]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Sprites_Multiplexing&amp;diff=97328</id>
		<title>Sprites Multiplexing</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Sprites_Multiplexing&amp;diff=97328"/>
				<updated>2017-02-26T09:54:40Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Examples of Sprites Multiplexing on an Amstrad Plus */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Sprites Multiplexing is a technic often used on other machines with Hardware Sprite Capability. &lt;br /&gt;
&lt;br /&gt;
It was often used on the [[Commodore 64|C64]].&lt;br /&gt;
&lt;br /&gt;
On the Amstrad [[Plus]] range, it couldn't be used as well. But some possibilities exist.&lt;br /&gt;
&lt;br /&gt;
It allows to &amp;quot;Multiplex&amp;quot; the same Sprite at different rasters lines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Limitations of Sprites Multiplexing on Amstrad Plus==&lt;br /&gt;
&lt;br /&gt;
The technic impose some limitations due to the somewhat unachieved design of the Amstrad Plus and the complex specificity of the [[ASIC]] :&lt;br /&gt;
&lt;br /&gt;
* The same Sprite is simply copied/duplicated as it is.&lt;br /&gt;
* No multiplexed sprites can be at the same Line.&lt;br /&gt;
&lt;br /&gt;
Multiplexing on the PLUS is much more difficult than on the C64. The reason is that the location for the graphics are fixed on the PLUS. e.g. Sprite 0 always looks at &amp;amp;4000 in the ASIC sprite RAM. This can't be changed.&lt;br /&gt;
&lt;br /&gt;
On the PLUS however you can freely change the X,Y position so it is possible to perform some multiplexing of the sprites.&lt;br /&gt;
&lt;br /&gt;
Another way to multiplex sprites is to use screen rupture, because the sprite X,Y coordinate is based on the CRTC's Raster and Line Counter.&lt;br /&gt;
&lt;br /&gt;
==Possible uses==&lt;br /&gt;
&lt;br /&gt;
This can then be used for games like Shoot'emups... as the sprites don't always need to be well animated (just moved) and as enemies waves are often pre-determined (R-Type is the typical example).&lt;br /&gt;
&lt;br /&gt;
So it fit well for Vertical Waves of enemies.&lt;br /&gt;
&lt;br /&gt;
Also for vertical or even diagonal special effects.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Examples of Sprites Multiplexing on an Amstrad Plus ==&lt;br /&gt;
 &lt;br /&gt;
This Technic wasn't really exploited on the amstrad Plus, mainly because the Amstrad Plus wasn't really exploited.&lt;br /&gt;
&lt;br /&gt;
* [[Black Sabbath]] by [[BDC-Iron]] (first harwired sprites multiplexing demo as claimed by its author)&lt;br /&gt;
*[[ Delirium Tremens]] preview by BDC-Iron (32 Harware sprites per line with actually only 8 sprites slots used)&lt;br /&gt;
&lt;br /&gt;
* [[Synergy]] demo. by [[AsT/Impact]]  (ndAsT : Yes this demo uses Sprites Multiplexing ! For example, the wobbler only uses 1 sprite line !!!... and have you ever count the balls displayed on the screen ?)&lt;br /&gt;
*[[XMas 2008 Dentro]] by [[AsT/impact]] (The christmas balls are composed of 4 sprites... copied 4 times on your screen)&lt;br /&gt;
* Probably [[It was so nice before the crash of the mir station]]&lt;br /&gt;
&lt;br /&gt;
In games, [[Prehistorik 2]] by [[Titus]] uses sprite multiplexing for the (second) big cloud/rocks that appear in the front. Did you notice that there are always 2 identical big clouds/rocks on screen at once..? Each one is drawn using all 16 hardware sprites.&lt;br /&gt;
&lt;br /&gt;
==Video==&lt;br /&gt;
&lt;br /&gt;
*Sprite Multiplexing on C64 : http://www.youtube.com/watch?v=oyf2W239eRY&lt;br /&gt;
*Synergy Demo on Amstrad Plus : http://www.youtube.com/watch?v=YGH5JIPWQ2I&lt;br /&gt;
&lt;br /&gt;
==Other Sources and links ==&lt;br /&gt;
&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites]]&lt;br /&gt;
&lt;br /&gt;
*[http://codebase64.org/doku.php?id=base:sprite_multiplexing Sprite Multiplexing Article at a C64wiki]&lt;br /&gt;
*[http://lywenn.eu.org/projets/mtpx/mtpx.pdf Sprite Multiplexing project on Nintendo DS]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:CPC Plus]][[Category:Programming]][[Category:Graphic]][[Category:Stub]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Mission_Genocide&amp;diff=97016</id>
		<title>Mission Genocide</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Mission_Genocide&amp;diff=97016"/>
				<updated>2016-12-26T08:54:55Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Reviews */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{|align=&amp;quot;right&amp;quot; valign=&amp;quot;top&amp;quot;&lt;br /&gt;
|{{Infobox Game&lt;br /&gt;
|Image = [[Image:Mission genocide (K7) (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case) - (Front).jpg|center|300px|Titlescreen of the game]]&lt;br /&gt;
|Company = [[Firebird]]&lt;br /&gt;
|Developer = [http://www.dadgum.com/halcyon/BOOK/SHIRLEY.HTM Paul Shirley] a.k.a. Rotovision&lt;br /&gt;
|Publisher = [[Firebird]]&lt;br /&gt;
|Musician = Unknown&lt;br /&gt;
|Release = [[:Category:Games 1987|1987]]&lt;br /&gt;
|Platform = [[Amstrad CPC|CPC]], [[Commodore 64]]&lt;br /&gt;
|Genre = Shoot'Em Up&lt;br /&gt;
|GameModes = Unknown&lt;br /&gt;
|Controls = {{Keyboard}} {{Joystick}}&lt;br /&gt;
|Media = {{Disk}} {{Tape}}&lt;br /&gt;
|Language = {{EN}}&lt;br /&gt;
|Info = Unknown&lt;br /&gt;
}}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
'''''Mission Genocide''''', originally titled '''''ZTB''''' (for ''Zap the Bastards'' and later ''Badstars'' [http://www.dadgum.com/halcyon/BOOK/SHIRLEY.HTM]) and still named thusly on the loading screen and elsewhere, is a game by Paul Shirley (a.k.a. Rotovision) for the old generation of CPCs, released on both tape and disc and compatible with all models.&lt;br /&gt;
&lt;br /&gt;
The game is mentioned fairly often for its smooth and pixel-perfect vertical scrolling, which is done in hardware using the [[CRTC]]. It is also notable in using a very fast method of plotting sprites, which takes advantage of the 16 colours of graphical Mode 0 by using 3 for sprites, Ink 0 for transparency, and the remaining 12 as 3 duplicate sets of 4 colours for the background: the roles of these Inks are arranged according to binary logic so that sprites can be ORd onto the background and ANDed to remove them, a method that is much faster and more memory-efficient than storing a sprite and a masking table and then performing all the relevant masking operations between these and the background. The name Rotovision has been used to refer to either of these techniques, but this seems actually to be an alias of the game’s programmer Paul Shirley: different ROMs of the game display one of these two names.&lt;br /&gt;
&lt;br /&gt;
Shirley later ported ''Mission Genocide'' from the CPC to the [[Commodore 64]], although he says that version is “not worth the tape it's saved on”, unlike the “technically impressive” original version.&lt;br /&gt;
&lt;br /&gt;
== Covertapes ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;Mission Genocide&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Image:Mission genocide (K7) (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case) - (Back).jpg|Back Covertape&lt;br /&gt;
Image:Mission genocide (K7) (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case) - (Front).jpg|Front Covertape&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Tape ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;gallery caption=&amp;quot;Mission Genocide&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Image:Mission genocide (K7) (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case) - (Media).jpg|Tape&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download ==&lt;br /&gt;
&lt;br /&gt;
* [[Media:Mission genocide (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case).cdt.zip|Mission genocide (Firebird Software) (199 Silver Range) (1987) (Standard Jewel Case).cdt.zip]] (CDT for Emulators)&lt;br /&gt;
&lt;br /&gt;
== Reviews ==&lt;br /&gt;
&lt;br /&gt;
* [[Amstrad Computer User]] July of 1987:&lt;br /&gt;
&amp;lt;gallery&amp;gt;&lt;br /&gt;
image:MissionGenocide ACU July1987 p1.jpg|page 40&lt;br /&gt;
image:MissionGenocide ACU July1987 p2.jpg|page 41&lt;br /&gt;
&amp;lt;/gallery&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* [[Amstrad Action]] October of 1987: Pages 40-41&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
* [http://www.cpc-power.com/index.php?page=detail&amp;amp;num=99 CPC game base from CPC Power]&lt;br /&gt;
* [http://tacgr.emuunlim.com/downloads/filedetail.php?recid=580 The Amstrad CPC Games Resource]&lt;br /&gt;
* [http://www.dadgum.com/halcyon/BOOK/SHIRLEY.HTM Interview with coder Paul Shirley], in which he discusses the alternative titles, his lack of faith in his conversion of the game to the Commodore 64, and topics about other projects.&lt;br /&gt;
&lt;br /&gt;
[[Category:Games]] [[Category:Games 1987]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96761</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96761"/>
				<updated>2016-10-11T07:24:44Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Fastest_Character_Print_in_Mode_2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96760</id>
		<title>Fastest Character Print in Mode 2</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96760"/>
				<updated>2016-10-11T07:24:00Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Fastest Character Print in Mode 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
Is it possible to print a character in Mode 2 in less than a raster line time (64nops)?&lt;br /&gt;
&lt;br /&gt;
YES, using RES and SET commands to calculate next line screen address!!&lt;br /&gt;
&lt;br /&gt;
This routine works in all vertical positions. It automatically calculates from which raster line of character we start to plot (CRTC reg. 9) and it uses special routine for each (0 - 7 lines).&lt;br /&gt;
&lt;br /&gt;
Code is MAXAM compatible / timed and documented to my best..&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;FASTEST CHARACTER PRINTER IN ALL Y COORDINATES&lt;br /&gt;
;takes less time than a raster line per char. in mode 2&lt;br /&gt;
;9.10.2016&lt;br /&gt;
;FG Brain&lt;br /&gt;
&lt;br /&gt;
org &amp;amp;7000 : RUN $ :nolist&lt;br /&gt;
&lt;br /&gt;
;INPUT HL = Screen Address to PLOT&lt;br /&gt;
&lt;br /&gt;
ld a,h&lt;br /&gt;
and %00111000&lt;br /&gt;
rra&lt;br /&gt;
rra&lt;br /&gt;
; A=no of raster line (0-7) of char. we plot&lt;br /&gt;
;[ rra NEEDED but destroyed then with add a,a ]&lt;br /&gt;
ld hl,tablinerout&lt;br /&gt;
ld b,0:ld c,a&lt;br /&gt;
add hl,bc&lt;br /&gt;
ld de,jphere+1&lt;br /&gt;
ldi:ldi&lt;br /&gt;
LD DE,&amp;amp;C850&lt;br /&gt;
LD BC,font&lt;br /&gt;
adr  ld hl,0&lt;br /&gt;
jphere jp jphere             ;get adr to jump according to A&lt;br /&gt;
&lt;br /&gt;
ret&lt;br /&gt;
&lt;br /&gt;
tablinerout&lt;br /&gt;
dw line0,line1,line2,line3,line4,line5,line6,line7&lt;br /&gt;
&lt;br /&gt;
;===PLOT 8 BYTES VERTICAL FROM ALL LINES===&lt;br /&gt;
;input DE = &amp;amp;C850  BC=font adr  HL=screen adr to print char.font&lt;br /&gt;
&lt;br /&gt;
line0 ;LINE 0&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
RET	;3&lt;br /&gt;
;=64 NOPs&lt;br /&gt;
&lt;br /&gt;
line1 ;LINE 1&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a	;7&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line2 ;LINE 2&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
Ret	;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line3 ;LINE 3&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line4 ;LINE 4&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
ret	;3&lt;br /&gt;
;=61 NOPs&lt;br /&gt;
&lt;br /&gt;
line5 ;LINE 5&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a	;10&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line6 ;LINE 6&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a ;6&lt;br /&gt;
ret ;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line7 ;LINE 7&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
align 256&lt;br /&gt;
FONT&lt;br /&gt;
DB 200,100,200,100,200,100,200,100&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Compare with the normal routine (but much smaller in size), which needs at least 104 nops!!&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ldi:   ;5&lt;br /&gt;
dec hl ;2&lt;br /&gt;
ld a,h:add 8:ld h,a ;4&lt;br /&gt;
jr nc,okk  ;2 / 3   13*8=104 NOPs&lt;br /&gt;
ld bc,&amp;amp;c050 ; 3&lt;br /&gt;
add hl,bc ; 3&lt;br /&gt;
jr okk ;3 ;  104+9=113 nops&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96759</id>
		<title>Fastest Character Print in Mode 2</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96759"/>
				<updated>2016-10-11T07:23:02Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Fastest Character Print in Mode 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Fastest Character Print in Mode 2==&lt;br /&gt;
&lt;br /&gt;
Is it possible to print a character in Mode 2 in less than a raster line time (64nops)?&lt;br /&gt;
&lt;br /&gt;
YES, using RES and SET commands to calculate next line screen address!!&lt;br /&gt;
&lt;br /&gt;
This routine works in all vertical positions. It automatically calculates from which raster line of character we start to plot (CRTC reg. 9) and it uses special routine for each (0 - 7 lines).&lt;br /&gt;
&lt;br /&gt;
Code is MAXAM compatible / timed and documented to my best..&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;FASTEST CHARACTER PRINTER IN ALL Y COORDINATES&lt;br /&gt;
;takes less time than a raster line per char. in mode 2&lt;br /&gt;
;9.10.2016&lt;br /&gt;
;FG Brain&lt;br /&gt;
&lt;br /&gt;
org &amp;amp;7000 : RUN $ :nolist&lt;br /&gt;
&lt;br /&gt;
;INPUT HL = Screen Address to PLOT&lt;br /&gt;
&lt;br /&gt;
ld a,h&lt;br /&gt;
and %00111000&lt;br /&gt;
rra&lt;br /&gt;
rra&lt;br /&gt;
; A=no of raster line (0-7) of char. we plot&lt;br /&gt;
;[ rra NEEDED but destroyed then with add a,a ]&lt;br /&gt;
ld hl,tablinerout&lt;br /&gt;
ld b,0:ld c,a&lt;br /&gt;
add hl,bc&lt;br /&gt;
ld de,jphere+1&lt;br /&gt;
ldi:ldi&lt;br /&gt;
LD DE,&amp;amp;C850&lt;br /&gt;
LD BC,font&lt;br /&gt;
adr  ld hl,0&lt;br /&gt;
jphere jp jphere             ;get adr to jump according to A&lt;br /&gt;
&lt;br /&gt;
ret&lt;br /&gt;
&lt;br /&gt;
tablinerout&lt;br /&gt;
dw line0,line1,line2,line3,line4,line5,line6,line7&lt;br /&gt;
&lt;br /&gt;
;===PLOT 8 BYTES VERTICAL FROM ALL LINES===&lt;br /&gt;
;input DE = &amp;amp;C850  BC=font adr  HL=screen adr to print char.font&lt;br /&gt;
&lt;br /&gt;
line0 ;LINE 0&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
RET	;3&lt;br /&gt;
;=64 NOPs&lt;br /&gt;
&lt;br /&gt;
line1 ;LINE 1&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a	;7&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line2 ;LINE 2&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
Ret	;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line3 ;LINE 3&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line4 ;LINE 4&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
ret	;3&lt;br /&gt;
;=61 NOPs&lt;br /&gt;
&lt;br /&gt;
line5 ;LINE 5&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a	;10&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line6 ;LINE 6&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a ;6&lt;br /&gt;
ret ;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line7 ;LINE 7&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
align 256&lt;br /&gt;
FONT&lt;br /&gt;
DB 200,100,200,100,200,100,200,100&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Compare with the normal routine (but much smaller in size), which needs at least 104 nops!!&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ldi:   ;5&lt;br /&gt;
dec hl ;2&lt;br /&gt;
ld a,h:add 8:ld h,a ;4&lt;br /&gt;
jr nc,okk  ;2 / 3   13*8=104 NOPs&lt;br /&gt;
ld bc,&amp;amp;c050 ; 3&lt;br /&gt;
add hl,bc ; 3&lt;br /&gt;
jr okk ;3 ;  104+9=113 nops&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96758</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96758"/>
				<updated>2016-10-11T07:20:35Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fastest_Character_Print_in_Mode_2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96757</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96757"/>
				<updated>2016-10-11T07:19:22Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:http://www.cpcwiki.eu/index.php/Fastest_Character_Print_in_Mode_2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96751</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96751"/>
				<updated>2016-10-09T11:02:10Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fastest Character Print in Mode 2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96750</id>
		<title>Source Codes</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Source_Codes&amp;diff=96750"/>
				<updated>2016-10-09T10:52:52Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Graphics */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Category:Programming]]&lt;br /&gt;
''This article contains source codes and programming examples. You may also have a look at''&lt;br /&gt;
* [[Programming software]]&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Technical documentation]]s&lt;br /&gt;
* [[Locomotive BASIC]]&lt;br /&gt;
* [[Type Ins]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Assembler ==&lt;br /&gt;
*[[Z80_-_undocumented_opcodes|Z80 - undocumented opcodes]]&lt;br /&gt;
*[[Where to learn?]]&lt;br /&gt;
&lt;br /&gt;
== Algorithms ==&lt;br /&gt;
*[[Programming:Bubble sort|Bubble sort]]&lt;br /&gt;
*[[Programming:CPC OS floating point routines|CPC OS floating point routines]]&lt;br /&gt;
*[[Programming:CRC16|CRC16]]&lt;br /&gt;
*[[Programming:CRC32|CRC32]]&lt;br /&gt;
*[[Programming:Integer Division|Integer Division]]&lt;br /&gt;
*[[Programming:Integer Multiplication|Integer Multiplication]]&lt;br /&gt;
*[[Programming:Logarithm|Logarithm]]&lt;br /&gt;
*[[Programming:Ultrafast Multiplication|Ultrafast Multiplication]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fast Square Root|Fast Square Root]]&lt;br /&gt;
*[[Programming:Fast 16 bit Square Root|Fast 16 bit Square Root]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Filling memory with a byte|Filling memory with a byte]]&lt;br /&gt;
*[[Programming:Square Root|Square Root]]&lt;br /&gt;
*[[Programming:Precalculated square|Precalculated square]]&lt;br /&gt;
*[[Programming:Random Number Generator|Random Number Generator]]&lt;br /&gt;
*[[Programming:Reverse A|Reverse A]]&lt;br /&gt;
*[[Programming:Quicksort|Quicksort]]&lt;br /&gt;
*[[Programming:Sin/Cos calculation|Sin/Cos calculation]]&lt;br /&gt;
&lt;br /&gt;
== CP/M ==&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BDOS|A simple 'Hello World' program for CP/M using BDOS]]&lt;br /&gt;
*[[Programming:A simple 'Hello World' program for CP/M using BIOS|A simple 'Hello World' program for CP/M using BIOS]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1 or CP/M plus|Executing firmware functions from within CP/M 2.1 or CP/M plus]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M 2.1|Executing firmware functions from within CP/M 2.1]]&lt;br /&gt;
*[[Programming:Executing firmware functions from within CP/M plus|Executing firmware functions from within CP/M plus]]&lt;br /&gt;
&lt;br /&gt;
== CPC Plus ==&lt;br /&gt;
*[[Amstrad CPC plus sprite format]]&lt;br /&gt;
*[[Programming:Convert CPC sprites to Plus hardware sprites|Convert CPC sprites to Plus hardware sprites]]&lt;br /&gt;
*[[Sprites Multiplexing]]&lt;br /&gt;
*[[Programming:CPC Plus Hardware Sprites|Hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Horizontal scroll|Horizontal scroll]]&lt;br /&gt;
*[[Programming:CPC Plus RLE Hardware Sprites|RLE hardware sprites]]&lt;br /&gt;
*[[Programming:CPC Plus Screen Splitting|Screen splitting]]&lt;br /&gt;
*[[Programming:CPC Plus Vertical scroll|Vertical scroll]]&lt;br /&gt;
*[[Operation of Z80 interrupt mode 0 in the CPC plus design]]&lt;br /&gt;
*[[Programming:Simple Raster Example 2 (uses CPC plus features)|Simple Raster Example 1 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Simple Raster Example 3 (uses CPC plus features)|Simple Raster Example 2 (uses CPC plus features)]]&lt;br /&gt;
*[[Programming:Unlocking ASIC|Unlocking ASIC]]&lt;br /&gt;
&lt;br /&gt;
== Devices ==&lt;br /&gt;
*[[Programming:CPC Booster|CPC Booster]]&lt;br /&gt;
*[[Programming:Digiblaster|Digiblaster]]&lt;br /&gt;
*[[Programming:Program to save the ROM of the Multiface 2|Program to save the ROM of the Multiface 2]]&lt;br /&gt;
*[[Programming:SYMBiFACE II|SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== File access ==&lt;br /&gt;
*[[Programming:An example to read a file byte-by-byte|An example to read a file byte-by-byte]]&lt;br /&gt;
*[[Programming:An example to write a file byte-by-byte|An example to write a file byte-by-byte]]&lt;br /&gt;
*[[Programming:A simple file copier using firmware functions (copies byte-by-byte)|A simple file copier using firmware functions (copies byte-by-byte)]]&lt;br /&gt;
*[[Programming:Loading a file|Loading a file]]&lt;br /&gt;
*[[Programming:Saving a file|Saving a file]]&lt;br /&gt;
*[[Programming:Unlocking a protected basic file|Unlocking a protected basic file]]&lt;br /&gt;
*[[Programming:Undo delete of file|Undo delete of file]]&lt;br /&gt;
&lt;br /&gt;
== Floppy disk ==&lt;br /&gt;
*[[Programming:A simple disc copier using BDOS functions|A simple disc copier using BDOS functions]]&lt;br /&gt;
*[[Programming:A simple disc formatter using BDOS functions|A simple disc formatter using BDOS functions]]&lt;br /&gt;
*[[Programming:An example loader|An example loader]]&lt;br /&gt;
*[[Programming:Catalog a disc and retrieve a directory|Catalog a disc and retrieve a directory]]&lt;br /&gt;
*[[Programming:Detecting an Amstrad or Vortex disc controler|Detecting an Amstrad or Vortex disc controler]]&lt;br /&gt;
*[[Programming:Formatting a track on a disc|Formatting a track on a disc]]&lt;br /&gt;
*[[Programming:Reading a sector from a disc|Reading a sector from a disc]]&lt;br /&gt;
*[[Programming:Reading and writing the boot sector of a SYSTEM/VENDOR disc|Reading and writing the boot sector of a SYSTEM/VENDOR disc]]&lt;br /&gt;
*[[Programming:Writing a sector to disc|Writing a sector to disc]]&lt;br /&gt;
&lt;br /&gt;
== Graphics ==&lt;br /&gt;
*[[Programming:Display a 8-bit number in binary|Display a 8-bit number in binary]]&lt;br /&gt;
*[[Programming:Display a 8-bit number in hex|Display a 8-bit number in hex]]&lt;br /&gt;
*[[Programming:Display a byte as a 3-digit decimal number|Display a byte as a 3-digit decimal number]]&lt;br /&gt;
*[[Programming:Display and update Scores|Display and update Scores]]&lt;br /&gt;
*[[Programming:Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)|Distorting the screen using register 2 of the CRTC (Horizontal Sync Position)]]&lt;br /&gt;
*[[Programming:Fast plot|Fast plot]]&lt;br /&gt;
*[[Programming:Fast Sprites|Fast Sprites]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Fast Textoutput|Fast Textoutput]] by [[Prodatron]]&lt;br /&gt;
*[[Programming:Fastest_Character_Print_in_Mode 2|Fastest Character Print in Mode 2 in all screen positions]] by [[FG Brain]]&lt;br /&gt;
*[[Programming:Hardware scrolling|Hardware Scrolling]] by [[User:Executioner|Executioner]]&lt;br /&gt;
*[[Programming:Hardware scrolling 2|Hardware Scrolling 2]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen horizontally byte-by-byte using the CRTC|Hardware scrolling the screen horizontally byte-by-byte using the CRTC]]&lt;br /&gt;
*[[Programming:Hardware scrolling the screen using the CRTC|Hardware scrolling the screen using the CRTC]]&lt;br /&gt;
*[[Programming:Next / previous line calculation|Next / previous line calculation]]&lt;br /&gt;
*[[Programming:Overscan|Overscan]]&lt;br /&gt;
*[[Programming:Plotting a sprite using character matrices|Plotting a sprite using character matrices]]&lt;br /&gt;
*[[Mode 4 (two bitplane emulation)| 4th Mode of CPCs: Plotting sprites on 2 bitplanes]]&lt;br /&gt;
*[[Screen refresh rate|Set the screen refresh rate]]&lt;br /&gt;
*[[Programming:Simple Raster Example 1|Simple Raster Example]]&lt;br /&gt;
*[[Programming:Simple Split Raster Example 1|Simple Split Raster Example]]&lt;br /&gt;
*[[Synchronising with the CRTC and display]]&lt;br /&gt;
*[[CRTC change colour (fill) test with precise timing]] by [[User:Matahari|Matahari]]&lt;br /&gt;
*[[256 byte Overscan MEGATEXT Intro - (features 50Hz fullscreen scroll)]] by [[User:Matahari|Matahari]]&lt;br /&gt;
&lt;br /&gt;
== Interrupts ==&lt;br /&gt;
* [[Reliable use of interrupt mode 2 on the CPC]]&lt;br /&gt;
&lt;br /&gt;
== Keyboard ==&lt;br /&gt;
*[[Programming:Keyboard scanning|Keyboard scanning]]&lt;br /&gt;
*[[Programming:Keyboard_redefinition|Keyboard redefinition]]&lt;br /&gt;
&lt;br /&gt;
== Other routines ==&lt;br /&gt;
*[[Programming:An example boot sector (executed with rsx command CPM)|An example boot sector (executed with rsx command CPM)]]&lt;br /&gt;
*[[Programming:An example to define a RSX|An example to define a RSX]]&lt;br /&gt;
*[[Programming:Calling a RSX from outside of BASIC|Calling a RSX from outside of BASIC]]&lt;br /&gt;
*[[Programming:Dumping the data of BASIC or AMSDOS or an expansion rom|Dumping the data of BASIC or AMSDOS or an expansion rom]]&lt;br /&gt;
*[[Programming:Dumping the data of the lower rom|Dumping the data of the lower rom]]&lt;br /&gt;
&lt;br /&gt;
== Sound ==&lt;br /&gt;
*[[How to access the PSG via PPI]]&lt;br /&gt;
*[[Programming:Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE|Tutorial - Understanding the fundamentals of BASIC SOUND and the Firmware SOUND QUEUE]]&lt;br /&gt;
*[[Programming:Source code to show 0x0ff is always returned when reading PSG port B|Source code to show 0x0ff is always returned when reading PSG port B]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)|Source code to show it is possible to store data in PSG register 14 and 15 (port A and port B)]]&lt;br /&gt;
*[[Programming:Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input|Source code to show it is possible to store data in PSG register 14 and 15 even if the port has been set to input]]&lt;br /&gt;
*[[Programming:Source code to show that some registers always return 0 in some bits|Source code to show that some registers always return 0 in some bits]]&lt;br /&gt;
*[[Programming:Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port|Source code to show that when a port is read in output mode; the data read will be ANDed with the inputs to that port]]&lt;br /&gt;
&lt;br /&gt;
== Cross Development ==&lt;br /&gt;
*[[Programming:Cross Development|Cross Development]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Source code]]&lt;br /&gt;
&lt;br /&gt;
== General Notes ==&lt;br /&gt;
&lt;br /&gt;
* Memory range for programs is &amp;amp;0040-&amp;amp;a700. This avoids firmware and memory allocated by AMSDOS disc ROM.&lt;br /&gt;
This is safe for the purpose of loading and being compatible with the firmware.&lt;br /&gt;
After loading, if you disable the firmware, you can re-use the firmware areas as you want, but you need to do everything yourself (scanning keyboard, drawing, sound etc).If you need to use these areas, a common thing to do is to load most into the safe area, some into the screen, and relocate it after loading.&lt;br /&gt;
* Programs on cassette and disc have a header that define the load address, length and execution address.&lt;br /&gt;
&lt;br /&gt;
In Pasmo assembler use the &amp;quot;end&amp;quot; mnemonic to define the label which is the execution address and use &amp;quot;--amsdos&amp;quot; to put an AMSDOS header on it.&lt;br /&gt;
&lt;br /&gt;
* Basic programs start at &amp;amp;170.&lt;br /&gt;
* Firmware uses interrupt mode 1 of the Z80 (interrupts jump to &amp;amp;0038)&lt;br /&gt;
* Lowest place you can LOAD a binary file to with BASIC is &amp;amp;389 e.g.:&lt;br /&gt;
&lt;br /&gt;
 openout&amp;quot;d&amp;quot;&lt;br /&gt;
 memory &amp;lt;address&amp;gt;-1&lt;br /&gt;
 closeout&lt;br /&gt;
 load &amp;quot;code&amp;quot;,&amp;lt;address&amp;gt;&lt;br /&gt;
 call &amp;lt;exec&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Screen is normally at &amp;amp;c000-&amp;amp;ffff. (It can be changed using firmware, or using CRTC R12/R13)&lt;br /&gt;
*Stack is normally at &amp;amp;c000 and goes down.&lt;br /&gt;
*Extra registers (BC', AF', HL', DE' are reserved by the firmware). Avoid if you are using firmware functions.&lt;br /&gt;
*Lower rom (containing OS) can be paged into memory between &amp;amp;0000-&amp;amp;3fff.&lt;br /&gt;
*Upper rom is selectable, examples are BASIC and AMSDOS. They can be paged into memory between &amp;amp;c000-&amp;amp;ffff.&lt;br /&gt;
*From basic, a game is run with:&lt;br /&gt;
&lt;br /&gt;
 RUN&amp;quot;&amp;lt;filename&amp;gt;&lt;br /&gt;
&lt;br /&gt;
keep it in the safe memory ranges and it'll run from cassette and disc.&lt;br /&gt;
*Screen is normally 40 crtc chars wide (CRTC R1=40), 25 crtc chars tall (CRTC R6=25). 8 scan lines per char (R9=7). Firmware functions assume this.&lt;br /&gt;
*Screen is bitmapped. You must draw/erase your own sprites and text.&lt;br /&gt;
*Firmware refreshes the palette every 50th of a second, so you need to turn off the firmware and use the hardware directly, or set the colours using firmware.&lt;br /&gt;
*Firmware can be &amp;quot;turned off&amp;quot;, by disabling lower ROM, redirecting interrupts and not calling firmware functions.&lt;br /&gt;
*Screen can be resized the same as the Spectrum. Provided you do not use hardware scrolling, this gives you extra space although because of the layout of the screen, it's not continuous, it's in 8 seperate blocks, but it's enough to store data and code.&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96749</id>
		<title>Fastest Character Print in Mode 2</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Fastest_Character_Print_in_Mode_2&amp;diff=96749"/>
				<updated>2016-10-09T10:45:57Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: Created page with &amp;quot;==Fastest Character Print in Mode 2==  It is possible to print a character in Mode 2 in less than a raster line time (64nops)?  YES, using RES and SET commands to calculate ne...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Fastest Character Print in Mode 2==&lt;br /&gt;
&lt;br /&gt;
It is possible to print a character in Mode 2 in less than a raster line time (64nops)?&lt;br /&gt;
&lt;br /&gt;
YES, using RES and SET commands to calculate next line screen address!!&lt;br /&gt;
&lt;br /&gt;
This routine works in all vertical positions. It automatically calculates from which raster line of character we start to plot (CRTC reg. 9) and it uses special routine for each (0 - 7 lines).&lt;br /&gt;
&lt;br /&gt;
Code is MAXAM compatible / timed and documented to my best..&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;FASTEST CHARACTER PRINTER IN ALL Y COORDINATES&lt;br /&gt;
;takes less time than a raster line per char. in mode 2&lt;br /&gt;
;9.10.2016&lt;br /&gt;
;FG Brain&lt;br /&gt;
&lt;br /&gt;
org &amp;amp;7000 : RUN $ :nolist&lt;br /&gt;
&lt;br /&gt;
;INPUT HL = Screen Address to PLOT&lt;br /&gt;
&lt;br /&gt;
ld a,h&lt;br /&gt;
and %00111000&lt;br /&gt;
rra&lt;br /&gt;
rra&lt;br /&gt;
; A=no of raster line (0-7) of char. we plot&lt;br /&gt;
;[ rra NEEDED but destroyed then with add a,a ]&lt;br /&gt;
ld hl,tablinerout&lt;br /&gt;
ld b,0:ld c,a&lt;br /&gt;
add hl,bc&lt;br /&gt;
ld de,jphere+1&lt;br /&gt;
ldi:ldi&lt;br /&gt;
LD DE,&amp;amp;C850&lt;br /&gt;
LD BC,font&lt;br /&gt;
adr  ld hl,0&lt;br /&gt;
jphere jp jphere             ;get adr to jump according to A&lt;br /&gt;
&lt;br /&gt;
ret&lt;br /&gt;
&lt;br /&gt;
tablinerout&lt;br /&gt;
dw line0,line1,line2,line3,line4,line5,line6,line7&lt;br /&gt;
&lt;br /&gt;
;===PLOT 8 BYTES VERTICAL FROM ALL LINES===&lt;br /&gt;
;input DE = &amp;amp;C850  BC=font adr  HL=screen adr to print char.font&lt;br /&gt;
&lt;br /&gt;
line0 ;LINE 0&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
RET	;3&lt;br /&gt;
;=64 NOPs&lt;br /&gt;
&lt;br /&gt;
line1 ;LINE 1&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
res 3,h:set 4,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a	;7&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line2 ;LINE 2&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
Ret	;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line3 ;LINE 3&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line4 ;LINE 4&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a	;6&lt;br /&gt;
ret	;3&lt;br /&gt;
;=61 NOPs&lt;br /&gt;
&lt;br /&gt;
line5 ;LINE 5&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a	;10&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
line6 ;LINE 6&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a ;6&lt;br /&gt;
ret ;3&lt;br /&gt;
;=63 NOPs&lt;br /&gt;
&lt;br /&gt;
line7 ;LINE 7&lt;br /&gt;
ld a,(bc):ld(hl),a:inc c	;5&lt;br /&gt;
add hl,de:ld a,(bc):ld(hl),a:inc c	;8&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;9&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 5,h:res 4,h:res 3,h:ld a,(bc):ld(hl),a:inc c	;11&lt;br /&gt;
set 3,h:ld a,(bc):ld(hl),a:inc c	;7&lt;br /&gt;
set 4,h:res 3,h:ld a,(bc):ld(hl),a	;8&lt;br /&gt;
ret	;3&lt;br /&gt;
;=65 NOPs&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
align 256&lt;br /&gt;
FONT&lt;br /&gt;
DB 200,100,200,100,200,100,200,100&lt;br /&gt;
&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Compare with the normal routine (but much smaller in size), which needs at least 104 nops!!&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ldi:   ;5&lt;br /&gt;
dec hl ;2&lt;br /&gt;
ld a,h:add 8:ld h,a ;4&lt;br /&gt;
jr nc,okk  ;2 / 3   13*8=104 NOPs&lt;br /&gt;
ld bc,&amp;amp;c050 ; 3&lt;br /&gt;
add hl,bc ; 3&lt;br /&gt;
jr okk ;3 ;  104+9=113 nops&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95464</id>
		<title>Programming methods used in games</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95464"/>
				<updated>2016-04-03T12:46:23Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Hardware Scrolling */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This section describes specific programming methods which are used in games and the games that use them.&lt;br /&gt;
&lt;br /&gt;
=== Sampled Sound ===&lt;br /&gt;
&lt;br /&gt;
Sampled music:&lt;br /&gt;
* Prehistorik 2&lt;br /&gt;
* Xyphoes Fantasy&lt;br /&gt;
&lt;br /&gt;
The sampled speech is often stored as 4-bit values with 2 values packed into each byte. Each value is sent to one of the AY volume registers at a fixed rate.&lt;br /&gt;
&lt;br /&gt;
Sampled speech:&lt;br /&gt;
* Chase HQ &lt;br /&gt;
* Bad Dudes vs Dragon Ninja&lt;br /&gt;
* Robocop&lt;br /&gt;
&lt;br /&gt;
=== Rasters ===&lt;br /&gt;
&lt;br /&gt;
[[Rasters]] is a colour changing effect.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
Zynaps.&lt;br /&gt;
&lt;br /&gt;
=== Hardware Double Buffer  ===&lt;br /&gt;
&lt;br /&gt;
Most good CPC games use the hardware double buffer technique in order to display sprites and/or to scroll the play area smoothly. &lt;br /&gt;
&lt;br /&gt;
In particular, two memory areas (instead of one) are reserved for the screen ram. &lt;br /&gt;
&lt;br /&gt;
In each frame, one of the two screens is displayed while the other is not visible but is drawn to. After the draw is done, the screens are exchanged using the hardware, so that the previously invisible one is now visible and the previously visible one is invisible.&lt;br /&gt;
&lt;br /&gt;
The exchange is done using the hardware specifically by changing the screen-offset, Reg 12 and 13 of the [[CRTC|CRTC]]). &lt;br /&gt;
&lt;br /&gt;
This process is repeated. &lt;br /&gt;
&lt;br /&gt;
The big advantage of this technique is that we can use a whole frame (or more) machine-time for our code (with no problems that arise when we alter screen ram at the same time the electron beam displays it on the monitor such as tearing or flickering). &lt;br /&gt;
&lt;br /&gt;
However, page flipping eats up a lot of memory area (which is crucial especially for 64Kb machines). This explains why a lot of games can have small game-areas&amp;amp;nbsp;!&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
Pac-Man Emulator&lt;br /&gt;
&lt;br /&gt;
=== Scrolling ===&lt;br /&gt;
&lt;br /&gt;
The following types of scroll are used:&lt;br /&gt;
&lt;br /&gt;
1. The player controls a character on the screen. When the character is moved the screen scrolls but the character remains in the same position on the screen. If they get to the edge of the map, they may walk up to the sides of the screen. If they walk back the other way when they reach a particular point on the screen it starts to scroll again and they remain in the same position.&lt;br /&gt;
&lt;br /&gt;
2. The player controls a character on the screen. When the character is moved towards the edges of the screen, the scroll moves a whole screen in width or height. The character is now on the opposite side. e.g. the character moves left, the screen scrolls by a whole screen width, the character is now on the right. The screen only scrolls when they get close to the sides.&lt;br /&gt;
&lt;br /&gt;
3. The screen always scrolls. The player controls a character who is either static or moves freely around the screen.&lt;br /&gt;
&lt;br /&gt;
=== Parallax/Multi Layer Scroll===&lt;br /&gt;
&lt;br /&gt;
Parallax or Multi Layer Scroll is an effect where there are 2 layers of tiles which scroll, one has priority over the other and often they move at different scroll rates.&lt;br /&gt;
&lt;br /&gt;
For example, the following games have parallax or multi layer scroll:&lt;br /&gt;
&lt;br /&gt;
* Wizard Willy&lt;br /&gt;
* Teenage Mutant Hero Turtles&lt;br /&gt;
* Astro Marine Corps (AMC)&lt;br /&gt;
* Turrican I and II&lt;br /&gt;
* Shadow Dancer &lt;br /&gt;
&lt;br /&gt;
==== Software Scrolling ====&lt;br /&gt;
&lt;br /&gt;
The screen is scrolled using the CPU only. This can be done by moving the data on the screen, or re-drawing it in a different position to give the illusion of scrolling.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
* Robocop&lt;br /&gt;
* Batman the Movie.&lt;br /&gt;
&lt;br /&gt;
==== Hardware Scrolling  ====&lt;br /&gt;
&lt;br /&gt;
Hardware scrolling is performed by changing the CRTC registers R12 and R13 to define the start address of the screen. The display is automatically wrapped at 16K, so continuous incrementation of these values will scroll the screen and wrap around. The code must then update the display for new graphics. &lt;br /&gt;
&lt;br /&gt;
The scrolling is in CRTC character sizes. &lt;br /&gt;
* 1 CRTC char horizontally is 2 bytes of RAM at a time which corresponds to 4 mode 0 pixels, 8 mode 1 pixels or 16 mode 2 pixels.&lt;br /&gt;
* The height of a CRTC char is defined by CRTC Register 9 (Max Raster), which is normally set to 7. Resulting in 8 scanlines per character.&lt;br /&gt;
&lt;br /&gt;
Horizontal scrolling can be made smoother by using R3 (Hsync Width), in addition to using R12 and R13 and makes the scrolling effectively half a CRTC char (therefore 2 mode 0 pixels, 4 mode 1 pixels or 8 mode 2 pixels). This can be done by changing the HSYNC width values between 5 and 6. The movement is an effect of how the monitor handles the HSYNC. This effect works well on Amstrad monitors, doesn't work on modern TFT screens and produces a black and white image on a MP-2 modulator because of the adjusted HSYNC timing. &lt;br /&gt;
&lt;br /&gt;
Vertical scrolling can be made smoother by using R5 (Vertical Adjust). This works on all monitors.&lt;br /&gt;
&lt;br /&gt;
More recent games (e.g. Prehistorik 2, Super Cauldron) use the rupture technique when doing vertical scroll to ensure the display is a constant number of scan lines in height, and so the refresh rate is always the same. &lt;br /&gt;
&lt;br /&gt;
Older games adjust R5 and don't use rupture (e.g. LED Storm, Legend of Kage), the time for a frame therefore varies by up to 7 extra scan-lines. This means the VSYNC to the monitor also varies in position by up to 7 extra scan-lines, and the stability of the image is then dependent on how the monitor handles the VSYNC. &lt;br /&gt;
&lt;br /&gt;
If the game uses a status panel, there are 2 ways to handle this.&lt;br /&gt;
# Redraw the panel when the screen is scrolled to compensate for it.&lt;br /&gt;
# Use rupture technique, the panel is in a different part of RAM and will not be affected by the scroll.&lt;br /&gt;
&lt;br /&gt;
This following is an incomplete list of games using hardware scrolling. From this list it can be seen that hardware scrolling has been used from 1984 :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Vertical'' &lt;br /&gt;
| ''Horizontal'' &lt;br /&gt;
| ''R3'' &lt;br /&gt;
| ''R5'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[3D Stunt Rider]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Amazing Shrinking Man|Amazing Shrinking Man (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Anarchy]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[BMX Kidz]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Bob Morane Science Fiction]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Boulder Dash]] &lt;br /&gt;
| 1984&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Builderland]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Canadair]] &lt;br /&gt;
| 1987&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Cessna Over Moscow]] &lt;br /&gt;
| 1987&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| [[Cyborgs]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Doctor Who and the Mines of Terror]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Edge Grinder]] &lt;br /&gt;
| 2011&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[FlySpy]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Fusion 2]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Glen Hoddle Soccer]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Gothic]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghosts 'n' Goblins]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghouls 'n' Ghosts]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Into The Eagle's Nest]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Jinks]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Killer Cobra]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Led Storm]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Legend of Kage]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Leviathan]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Le 5eme Axe]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Monty Python's Flying Circus]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes(?) &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Out of This World]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Paraplane]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Plate-Forme]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Profanation]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prohibition]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Realm!]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
|-&lt;br /&gt;
| [[Rick Dangerous 2]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Rig Attack]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Roland on the Ropes]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[The Sentinel|Sentinel (The)]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Star Sabre]] &lt;br /&gt;
| 2007&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Return of the Jedi|Return of the Jedi (The)]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Thing on a Spring]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Rock]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Wars]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Sly Spy Secret Agent]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Avenger]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Sabre]] &lt;br /&gt;
| 2007&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Street Machine]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Striker in the Crypts of Trogan]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Titan]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[T.L.L. - Tornado Low Level|Tornado Low Level]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Top Level]]&lt;br /&gt;
|  &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Twin World]] &lt;br /&gt;
| 1990&lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Ultima Ratio]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Unitrax]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vector Ball]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vikings (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Wonderboy]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xeno]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Rupture (or splitscreen)  ===&lt;br /&gt;
&lt;br /&gt;
A CRTC programming technique used to split the screen into more than one block vertically. &lt;br /&gt;
&lt;br /&gt;
The sizes of each block are defined using CRTC register R4. Vsync is turned off in all but one block (by setting CRTC R7 to a value larger than R4).&lt;br /&gt;
The start address of each block can be changed using CRTC registers R12 and R13.&lt;br /&gt;
&lt;br /&gt;
This allows each block to reference different ram or to hardware scroll one block while another is static.&lt;br /&gt;
&lt;br /&gt;
This method requires careful timing for the CRTC register updates, it also needs testing on all CRTC because there are differences of when each will accept and use the values programmed. However, the result can be made to work on all with more simple ruptures. Care must also be taken to ensure the timings are setup for a 50Hz screen.&lt;br /&gt;
&lt;br /&gt;
It is worth noting that some monitors are more tolerant to longer or shorter frames so the result may appear correctly on them and not on others.&lt;br /&gt;
In addition some games may have been programmed and tested on only 1 CRTC type so may not work on others.&lt;br /&gt;
&lt;br /&gt;
Wonderboy sets R4 every frame to the same value - reason unknown. But it doesn't use Rupture, because if this code is removed it works fine.&lt;br /&gt;
&lt;br /&gt;
This is a an incomplete list of games that use this technique, but according to this list the earliest games used this technique was 1987:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force|Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle|Axys]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Dynamic Duo|Dynamic Duo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior|Energy Warrior]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Enlightenment: Druid 2|Enlightenment: Druid 2]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[F1 Tornado Simulator]] &lt;br /&gt;
| 1991&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Grell and Falla|Grell and Falla]] &lt;br /&gt;
| 1992&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide|Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex|Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Para Academy]] &lt;br /&gt;
| 1990&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2|Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Q10 Tank Buster]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Santa's Christmas Capers]] &lt;br /&gt;
| 1990&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball|Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skatewars|Skatewars]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz|Skateboard Kidz]]&lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Snowstrike|Snowstrike]] &lt;br /&gt;
| 1990&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Storm Warrior|Storm Warrior]] &lt;br /&gt;
| 1989&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron|Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Turrican|Turrican]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Twin World (Ubi Soft)|Twin World (Ubi Soft)]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Usagi Yojimbo|Usagi Yojimbo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk|Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xyphoes Fantasy|Xyphoes Fantasy]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Firmware==&lt;br /&gt;
&lt;br /&gt;
The following games are known to use firmware functions. This probably explains why they are poor. If the programmer had used the hardware directly they would have lots more cycles free which they could have used to make the game better.&lt;br /&gt;
&lt;br /&gt;
This list is not exhaustive.&lt;br /&gt;
&lt;br /&gt;
*Xevious&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95463</id>
		<title>Programming methods used in games</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95463"/>
				<updated>2016-04-03T12:36:09Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Hardware Scrolling */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This section describes specific programming methods which are used in games and the games that use them.&lt;br /&gt;
&lt;br /&gt;
=== Sampled Sound ===&lt;br /&gt;
&lt;br /&gt;
Sampled music:&lt;br /&gt;
* Prehistorik 2&lt;br /&gt;
* Xyphoes Fantasy&lt;br /&gt;
&lt;br /&gt;
The sampled speech is often stored as 4-bit values with 2 values packed into each byte. Each value is sent to one of the AY volume registers at a fixed rate.&lt;br /&gt;
&lt;br /&gt;
Sampled speech:&lt;br /&gt;
* Chase HQ &lt;br /&gt;
* Bad Dudes vs Dragon Ninja&lt;br /&gt;
* Robocop&lt;br /&gt;
&lt;br /&gt;
=== Rasters ===&lt;br /&gt;
&lt;br /&gt;
[[Rasters]] is a colour changing effect.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
Zynaps.&lt;br /&gt;
&lt;br /&gt;
=== Hardware Double Buffer  ===&lt;br /&gt;
&lt;br /&gt;
Most good CPC games use the hardware double buffer technique in order to display sprites and/or to scroll the play area smoothly. &lt;br /&gt;
&lt;br /&gt;
In particular, two memory areas (instead of one) are reserved for the screen ram. &lt;br /&gt;
&lt;br /&gt;
In each frame, one of the two screens is displayed while the other is not visible but is drawn to. After the draw is done, the screens are exchanged using the hardware, so that the previously invisible one is now visible and the previously visible one is invisible.&lt;br /&gt;
&lt;br /&gt;
The exchange is done using the hardware specifically by changing the screen-offset, Reg 12 and 13 of the [[CRTC|CRTC]]). &lt;br /&gt;
&lt;br /&gt;
This process is repeated. &lt;br /&gt;
&lt;br /&gt;
The big advantage of this technique is that we can use a whole frame (or more) machine-time for our code (with no problems that arise when we alter screen ram at the same time the electron beam displays it on the monitor such as tearing or flickering). &lt;br /&gt;
&lt;br /&gt;
However, page flipping eats up a lot of memory area (which is crucial especially for 64Kb machines). This explains why a lot of games can have small game-areas&amp;amp;nbsp;!&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
Pac-Man Emulator&lt;br /&gt;
&lt;br /&gt;
=== Scrolling ===&lt;br /&gt;
&lt;br /&gt;
The following types of scroll are used:&lt;br /&gt;
&lt;br /&gt;
1. The player controls a character on the screen. When the character is moved the screen scrolls but the character remains in the same position on the screen. If they get to the edge of the map, they may walk up to the sides of the screen. If they walk back the other way when they reach a particular point on the screen it starts to scroll again and they remain in the same position.&lt;br /&gt;
&lt;br /&gt;
2. The player controls a character on the screen. When the character is moved towards the edges of the screen, the scroll moves a whole screen in width or height. The character is now on the opposite side. e.g. the character moves left, the screen scrolls by a whole screen width, the character is now on the right. The screen only scrolls when they get close to the sides.&lt;br /&gt;
&lt;br /&gt;
3. The screen always scrolls. The player controls a character who is either static or moves freely around the screen.&lt;br /&gt;
&lt;br /&gt;
=== Parallax/Multi Layer Scroll===&lt;br /&gt;
&lt;br /&gt;
Parallax or Multi Layer Scroll is an effect where there are 2 layers of tiles which scroll, one has priority over the other and often they move at different scroll rates.&lt;br /&gt;
&lt;br /&gt;
For example, the following games have parallax or multi layer scroll:&lt;br /&gt;
&lt;br /&gt;
* Wizard Willy&lt;br /&gt;
* Teenage Mutant Hero Turtles&lt;br /&gt;
* Astro Marine Corps (AMC)&lt;br /&gt;
* Turrican I and II&lt;br /&gt;
* Shadow Dancer &lt;br /&gt;
&lt;br /&gt;
==== Software Scrolling ====&lt;br /&gt;
&lt;br /&gt;
The screen is scrolled using the CPU only. This can be done by moving the data on the screen, or re-drawing it in a different position to give the illusion of scrolling.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
* Robocop&lt;br /&gt;
* Batman the Movie.&lt;br /&gt;
&lt;br /&gt;
==== Hardware Scrolling  ====&lt;br /&gt;
&lt;br /&gt;
Hardware scrolling is performed by changing the CRTC registers R12 and R13 to define the start address of the screen. The display is automatically wrapped at 16K, so continuous incrementation of these values will scroll the screen and wrap around. The code must then update the display for new graphics. &lt;br /&gt;
&lt;br /&gt;
The scrolling is in CRTC character sizes. &lt;br /&gt;
* 1 CRTC char horizontally is 2 bytes of RAM at a time which corresponds to 4 mode 0 pixels, 8 mode 1 pixels or 16 mode 2 pixels.&lt;br /&gt;
* The height of a CRTC char is defined by CRTC Register 9 (Max Raster), which is normally set to 7. Resulting in 8 scanlines per character.&lt;br /&gt;
&lt;br /&gt;
Horizontal scrolling can be made smoother by using R3 (Hsync Width), in addition to using R12 and R13 and makes the scrolling effectively half a CRTC char (therefore 2 mode 0 pixels, 4 mode 1 pixels or 8 mode 2 pixels). This can be done by changing the HSYNC width values between 5 and 6. The movement is an effect of how the monitor handles the HSYNC. This effect works well on Amstrad monitors, doesn't work on modern TFT screens and produces a black and white image on a MP-2 modulator because of the adjusted HSYNC timing. &lt;br /&gt;
&lt;br /&gt;
Vertical scrolling can be made smoother by using R5 (Vertical Adjust). This works on all monitors.&lt;br /&gt;
&lt;br /&gt;
More recent games (e.g. Prehistorik 2, Super Cauldron) use the rupture technique when doing vertical scroll to ensure the display is a constant number of scan lines in height, and so the refresh rate is always the same. &lt;br /&gt;
&lt;br /&gt;
Older games adjust R5 and don't use rupture (e.g. LED Storm, Legend of Kage), the time for a frame therefore varies by up to 7 extra scan-lines. This means the VSYNC to the monitor also varies in position by up to 7 extra scan-lines, and the stability of the image is then dependent on how the monitor handles the VSYNC. &lt;br /&gt;
&lt;br /&gt;
If the game uses a status panel, there are 2 ways to handle this.&lt;br /&gt;
# Redraw the panel when the screen is scrolled to compensate for it.&lt;br /&gt;
# Use rupture technique, the panel is in a different part of RAM and will not be affected by the scroll.&lt;br /&gt;
&lt;br /&gt;
This following is an incomplete list of games using hardware scrolling. From this list it can be seen that hardware scrolling has been used from 1984 :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Vertical'' &lt;br /&gt;
| ''Horizontal'' &lt;br /&gt;
| ''R3'' &lt;br /&gt;
| ''R5'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[3D Stunt Rider]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Amazing Shrinking Man|Amazing Shrinking Man (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Anarchy]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[BMX Kidz]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Bob Morane Science Fiction]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Boulder Dash]] &lt;br /&gt;
| 1984&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Builderland]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Canadair]] &lt;br /&gt;
| 1987&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Cessna Over Moscow]] &lt;br /&gt;
| 1987&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
| [[Cyborgs]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Doctor Who and the Mines of Terror]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Edge Grinder]] &lt;br /&gt;
|  &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[FlySpy]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Fusion 2]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Glen Hoddle Soccer]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Gothic]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghosts 'n' Goblins]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghouls 'n' Ghosts]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Into The Eagle's Nest]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Jinks]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Killer Cobra]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Led Storm]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Legend of Kage]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Leviathan]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Le 5eme Axe]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Monty Python's Flying Circus]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes(?) &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Out of This World]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Paraplane]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Plate-Forme]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Profanation]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prohibition]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Realm!]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Rig Attack]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Sabre]] &lt;br /&gt;
| 2007&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Return of the Jedi|Return of the Jedi (The)]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Thing on a Spring]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rick Dangerous 2]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Rig Attack]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Roland on the Ropes]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[The Sentinel|Sentinel (The)]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Rock]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Wars]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Sly Spy Secret Agent]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Avenger]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Street Machine]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Striker in the Crypts of Trogan]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Titan]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[T.L.L. - Tornado Low Level|Tornado Low Level]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Top Level]]&lt;br /&gt;
|  &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Ultima Ratio]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Unitrax]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vector Ball]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vikings (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Wonderboy]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xeno]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Rupture (or splitscreen)  ===&lt;br /&gt;
&lt;br /&gt;
A CRTC programming technique used to split the screen into more than one block vertically. &lt;br /&gt;
&lt;br /&gt;
The sizes of each block are defined using CRTC register R4. Vsync is turned off in all but one block (by setting CRTC R7 to a value larger than R4).&lt;br /&gt;
The start address of each block can be changed using CRTC registers R12 and R13.&lt;br /&gt;
&lt;br /&gt;
This allows each block to reference different ram or to hardware scroll one block while another is static.&lt;br /&gt;
&lt;br /&gt;
This method requires careful timing for the CRTC register updates, it also needs testing on all CRTC because there are differences of when each will accept and use the values programmed. However, the result can be made to work on all with more simple ruptures. Care must also be taken to ensure the timings are setup for a 50Hz screen.&lt;br /&gt;
&lt;br /&gt;
It is worth noting that some monitors are more tolerant to longer or shorter frames so the result may appear correctly on them and not on others.&lt;br /&gt;
In addition some games may have been programmed and tested on only 1 CRTC type so may not work on others.&lt;br /&gt;
&lt;br /&gt;
Wonderboy sets R4 every frame to the same value - reason unknown. But it doesn't use Rupture, because if this code is removed it works fine.&lt;br /&gt;
&lt;br /&gt;
This is a an incomplete list of games that use this technique, but according to this list the earliest games used this technique was 1987:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force|Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle|Axys]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Dynamic Duo|Dynamic Duo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior|Energy Warrior]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Enlightenment: Druid 2|Enlightenment: Druid 2]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[F1 Tornado Simulator]] &lt;br /&gt;
| 1991&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Grell and Falla|Grell and Falla]] &lt;br /&gt;
| 1992&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide|Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex|Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Para Academy]] &lt;br /&gt;
| 1990&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2|Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Q10 Tank Buster]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Santa's Christmas Capers]] &lt;br /&gt;
| 1990&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball|Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skatewars|Skatewars]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz|Skateboard Kidz]]&lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Snowstrike|Snowstrike]] &lt;br /&gt;
| 1990&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Storm Warrior|Storm Warrior]] &lt;br /&gt;
| 1989&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron|Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Turrican|Turrican]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Twin World (Ubi Soft)|Twin World (Ubi Soft)]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Usagi Yojimbo|Usagi Yojimbo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk|Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xyphoes Fantasy|Xyphoes Fantasy]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Firmware==&lt;br /&gt;
&lt;br /&gt;
The following games are known to use firmware functions. This probably explains why they are poor. If the programmer had used the hardware directly they would have lots more cycles free which they could have used to make the game better.&lt;br /&gt;
&lt;br /&gt;
This list is not exhaustive.&lt;br /&gt;
&lt;br /&gt;
*Xevious&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95462</id>
		<title>Programming methods used in games</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming_methods_used_in_games&amp;diff=95462"/>
				<updated>2016-04-03T12:30:29Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Hardware Scrolling */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This section describes specific programming methods which are used in games and the games that use them.&lt;br /&gt;
&lt;br /&gt;
=== Sampled Sound ===&lt;br /&gt;
&lt;br /&gt;
Sampled music:&lt;br /&gt;
* Prehistorik 2&lt;br /&gt;
* Xyphoes Fantasy&lt;br /&gt;
&lt;br /&gt;
The sampled speech is often stored as 4-bit values with 2 values packed into each byte. Each value is sent to one of the AY volume registers at a fixed rate.&lt;br /&gt;
&lt;br /&gt;
Sampled speech:&lt;br /&gt;
* Chase HQ &lt;br /&gt;
* Bad Dudes vs Dragon Ninja&lt;br /&gt;
* Robocop&lt;br /&gt;
&lt;br /&gt;
=== Rasters ===&lt;br /&gt;
&lt;br /&gt;
[[Rasters]] is a colour changing effect.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
Zynaps.&lt;br /&gt;
&lt;br /&gt;
=== Hardware Double Buffer  ===&lt;br /&gt;
&lt;br /&gt;
Most good CPC games use the hardware double buffer technique in order to display sprites and/or to scroll the play area smoothly. &lt;br /&gt;
&lt;br /&gt;
In particular, two memory areas (instead of one) are reserved for the screen ram. &lt;br /&gt;
&lt;br /&gt;
In each frame, one of the two screens is displayed while the other is not visible but is drawn to. After the draw is done, the screens are exchanged using the hardware, so that the previously invisible one is now visible and the previously visible one is invisible.&lt;br /&gt;
&lt;br /&gt;
The exchange is done using the hardware specifically by changing the screen-offset, Reg 12 and 13 of the [[CRTC|CRTC]]). &lt;br /&gt;
&lt;br /&gt;
This process is repeated. &lt;br /&gt;
&lt;br /&gt;
The big advantage of this technique is that we can use a whole frame (or more) machine-time for our code (with no problems that arise when we alter screen ram at the same time the electron beam displays it on the monitor such as tearing or flickering). &lt;br /&gt;
&lt;br /&gt;
However, page flipping eats up a lot of memory area (which is crucial especially for 64Kb machines). This explains why a lot of games can have small game-areas&amp;amp;nbsp;!&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
Pac-Man Emulator&lt;br /&gt;
&lt;br /&gt;
=== Scrolling ===&lt;br /&gt;
&lt;br /&gt;
The following types of scroll are used:&lt;br /&gt;
&lt;br /&gt;
1. The player controls a character on the screen. When the character is moved the screen scrolls but the character remains in the same position on the screen. If they get to the edge of the map, they may walk up to the sides of the screen. If they walk back the other way when they reach a particular point on the screen it starts to scroll again and they remain in the same position.&lt;br /&gt;
&lt;br /&gt;
2. The player controls a character on the screen. When the character is moved towards the edges of the screen, the scroll moves a whole screen in width or height. The character is now on the opposite side. e.g. the character moves left, the screen scrolls by a whole screen width, the character is now on the right. The screen only scrolls when they get close to the sides.&lt;br /&gt;
&lt;br /&gt;
3. The screen always scrolls. The player controls a character who is either static or moves freely around the screen.&lt;br /&gt;
&lt;br /&gt;
=== Parallax/Multi Layer Scroll===&lt;br /&gt;
&lt;br /&gt;
Parallax or Multi Layer Scroll is an effect where there are 2 layers of tiles which scroll, one has priority over the other and often they move at different scroll rates.&lt;br /&gt;
&lt;br /&gt;
For example, the following games have parallax or multi layer scroll:&lt;br /&gt;
&lt;br /&gt;
* Wizard Willy&lt;br /&gt;
* Teenage Mutant Hero Turtles&lt;br /&gt;
* Astro Marine Corps (AMC)&lt;br /&gt;
* Turrican I and II&lt;br /&gt;
* Shadow Dancer &lt;br /&gt;
&lt;br /&gt;
==== Software Scrolling ====&lt;br /&gt;
&lt;br /&gt;
The screen is scrolled using the CPU only. This can be done by moving the data on the screen, or re-drawing it in a different position to give the illusion of scrolling.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
&lt;br /&gt;
* Robocop&lt;br /&gt;
* Batman the Movie.&lt;br /&gt;
&lt;br /&gt;
==== Hardware Scrolling  ====&lt;br /&gt;
&lt;br /&gt;
Hardware scrolling is performed by changing the CRTC registers R12 and R13 to define the start address of the screen. The display is automatically wrapped at 16K, so continuous incrementation of these values will scroll the screen and wrap around. The code must then update the display for new graphics. &lt;br /&gt;
&lt;br /&gt;
The scrolling is in CRTC character sizes. &lt;br /&gt;
* 1 CRTC char horizontally is 2 bytes of RAM at a time which corresponds to 4 mode 0 pixels, 8 mode 1 pixels or 16 mode 2 pixels.&lt;br /&gt;
* The height of a CRTC char is defined by CRTC Register 9 (Max Raster), which is normally set to 7. Resulting in 8 scanlines per character.&lt;br /&gt;
&lt;br /&gt;
Horizontal scrolling can be made smoother by using R3 (Hsync Width), in addition to using R12 and R13 and makes the scrolling effectively half a CRTC char (therefore 2 mode 0 pixels, 4 mode 1 pixels or 8 mode 2 pixels). This can be done by changing the HSYNC width values between 5 and 6. The movement is an effect of how the monitor handles the HSYNC. This effect works well on Amstrad monitors, doesn't work on modern TFT screens and produces a black and white image on a MP-2 modulator because of the adjusted HSYNC timing. &lt;br /&gt;
&lt;br /&gt;
Vertical scrolling can be made smoother by using R5 (Vertical Adjust). This works on all monitors.&lt;br /&gt;
&lt;br /&gt;
More recent games (e.g. Prehistorik 2, Super Cauldron) use the rupture technique when doing vertical scroll to ensure the display is a constant number of scan lines in height, and so the refresh rate is always the same. &lt;br /&gt;
&lt;br /&gt;
Older games adjust R5 and don't use rupture (e.g. LED Storm, Legend of Kage), the time for a frame therefore varies by up to 7 extra scan-lines. This means the VSYNC to the monitor also varies in position by up to 7 extra scan-lines, and the stability of the image is then dependent on how the monitor handles the VSYNC. &lt;br /&gt;
&lt;br /&gt;
If the game uses a status panel, there are 2 ways to handle this.&lt;br /&gt;
# Redraw the panel when the screen is scrolled to compensate for it.&lt;br /&gt;
# Use rupture technique, the panel is in a different part of RAM and will not be affected by the scroll.&lt;br /&gt;
&lt;br /&gt;
This following is an incomplete list of games using hardware scrolling. From this list it can be seen that hardware scrolling has been used from 1984 :&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Vertical'' &lt;br /&gt;
| ''Horizontal'' &lt;br /&gt;
| ''R3'' &lt;br /&gt;
| ''R5'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[3D Stunt Rider]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Amazing Shrinking Man|Amazing Shrinking Man (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Anarchy]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[BMX Kidz]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Bob Morane Science Fiction]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Boulder Dash]] &lt;br /&gt;
| 1984&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Builderland]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Canadair]] &lt;br /&gt;
| 1987&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Cyborgs]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Doctor Who and the Mines of Terror]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Edge Grinder]] &lt;br /&gt;
|  &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[FlySpy]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Fusion 2]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Glen Hoddle Soccer]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Gothic]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghosts 'n' Goblins]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Ghouls 'n' Ghosts]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Into The Eagle's Nest]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Jinks]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Killer Cobra]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Led Storm]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Legend of Kage]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Leviathan]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Le 5eme Axe]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Monty Python's Flying Circus]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes(?) &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Out of This World]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Paraplane]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Plate-Forme]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| No&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Profanation]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Prohibition]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Realm!]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Rig Attack]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Sabre]] &lt;br /&gt;
| 2007&lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[The Return of the Jedi|Return of the Jedi (The)]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Thing on a Spring]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rick Dangerous 2]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Rig Attack]] &lt;br /&gt;
| 1985&lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No&lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Roland on the Ropes]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[The Sentinel|Sentinel (The)]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Rock]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Wars]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Sly Spy Secret Agent]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Star Avenger]] &lt;br /&gt;
| 1984 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Street Machine]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Striker in the Crypts of Trogan]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Titan]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[T.L.L. - Tornado Low Level|Tornado Low Level]] &lt;br /&gt;
| 1985 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Top Level]]&lt;br /&gt;
|  &lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Ultima Ratio]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Unitrax]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vector Ball]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Diagonal &lt;br /&gt;
| scroll! &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Vikings (The)]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| Yes&lt;br /&gt;
| Yes&lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Wonderboy]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xeno]] &lt;br /&gt;
| 1986 &lt;br /&gt;
| No &lt;br /&gt;
| Yes &lt;br /&gt;
| No &lt;br /&gt;
| No &lt;br /&gt;
| Yes&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Rupture (or splitscreen)  ===&lt;br /&gt;
&lt;br /&gt;
A CRTC programming technique used to split the screen into more than one block vertically. &lt;br /&gt;
&lt;br /&gt;
The sizes of each block are defined using CRTC register R4. Vsync is turned off in all but one block (by setting CRTC R7 to a value larger than R4).&lt;br /&gt;
The start address of each block can be changed using CRTC registers R12 and R13.&lt;br /&gt;
&lt;br /&gt;
This allows each block to reference different ram or to hardware scroll one block while another is static.&lt;br /&gt;
&lt;br /&gt;
This method requires careful timing for the CRTC register updates, it also needs testing on all CRTC because there are differences of when each will accept and use the values programmed. However, the result can be made to work on all with more simple ruptures. Care must also be taken to ensure the timings are setup for a 50Hz screen.&lt;br /&gt;
&lt;br /&gt;
It is worth noting that some monitors are more tolerant to longer or shorter frames so the result may appear correctly on them and not on others.&lt;br /&gt;
In addition some games may have been programmed and tested on only 1 CRTC type so may not work on others.&lt;br /&gt;
&lt;br /&gt;
Wonderboy sets R4 every frame to the same value - reason unknown. But it doesn't use Rupture, because if this code is removed it works fine.&lt;br /&gt;
&lt;br /&gt;
This is a an incomplete list of games that use this technique, but according to this list the earliest games used this technique was 1987:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;FCK__ShowTableBorders&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ''Title'' &lt;br /&gt;
| ''Year'' &lt;br /&gt;
| ''Confirmed''&lt;br /&gt;
|-&lt;br /&gt;
| [[Action Force|Action Force]] &lt;br /&gt;
| 1988 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Axys: The Last Battle|Axys]] &lt;br /&gt;
| 1991 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Dynamic Duo|Dynamic Duo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[DJ Puff's Volcanic Eruption]] &lt;br /&gt;
| 1992&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Energy Warrior|Energy Warrior]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Enlightenment: Druid 2|Enlightenment: Druid 2]] &lt;br /&gt;
| 1988&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[F1 Tornado Simulator]] &lt;br /&gt;
| 1991&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Grell and Falla|Grell and Falla]] &lt;br /&gt;
| 1992&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Mission Genocide|Mission Genocide]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Octoplex|Octoplex]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Para Academy]] &lt;br /&gt;
| 1990&lt;br /&gt;
| No&lt;br /&gt;
|-&lt;br /&gt;
| [[Prehistorik 2|Prehistorik 2]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Q10 Tank Buster]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Rastan]] &lt;br /&gt;
| 1987&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Rockford]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes &lt;br /&gt;
|-&lt;br /&gt;
| [[Santa's Christmas Capers]] &lt;br /&gt;
| 1990&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skate Ball|Skate Ball]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Skatewars|Skatewars]] &lt;br /&gt;
| 1989 &lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Skateboard Kidz|Skateboard Kidz]]&lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Snowstrike|Snowstrike]] &lt;br /&gt;
| 1990&lt;br /&gt;
| &lt;br /&gt;
|-&lt;br /&gt;
| [[Storm Warrior|Storm Warrior]] &lt;br /&gt;
| 1989&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Super Cauldron|Super Cauldron]] &lt;br /&gt;
| 1992 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Turrican|Turrican]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
| [[Twin World (Ubi Soft)|Twin World (Ubi Soft)]] &lt;br /&gt;
| 1990 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Usagi Yojimbo|Usagi Yojimbo]] &lt;br /&gt;
| 1988&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Warhawk|Warhawk]] &lt;br /&gt;
| 1987 &lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
| [[Xyphoes Fantasy|Xyphoes Fantasy]] &lt;br /&gt;
| 1991&lt;br /&gt;
| Yes&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Firmware==&lt;br /&gt;
&lt;br /&gt;
The following games are known to use firmware functions. This probably explains why they are poor. If the programmer had used the hardware directly they would have lots more cycles free which they could have used to make the game better.&lt;br /&gt;
&lt;br /&gt;
This list is not exhaustive.&lt;br /&gt;
&lt;br /&gt;
*Xevious&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Peripherals&amp;diff=95026</id>
		<title>Peripherals</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Peripherals&amp;diff=95026"/>
				<updated>2016-01-29T17:55:14Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''You can also check the Category : Peripherals for a complete list of CPCwiki pages on the matter.'''&lt;br /&gt;
&lt;br /&gt;
* [[I/O Port Summary]]&lt;br /&gt;
&lt;br /&gt;
''Please try to keep things in alphabetical order.''&lt;br /&gt;
&lt;br /&gt;
== Built-in Peripherals ==&lt;br /&gt;
&lt;br /&gt;
=== Built-in Chipset ===&lt;br /&gt;
&lt;br /&gt;
* [[765 FDC]] - Floppy Disc Controller&lt;br /&gt;
* [[8255]] - PIO - I/O controller&lt;br /&gt;
* [[Arnold V Specs Revised]] - Arnold V (CPC+) Technical Specification&lt;br /&gt;
* [[AY-3-8912]] - Sound chip / keyboard controller&lt;br /&gt;
* [[CRTC]] - Video chip&lt;br /&gt;
* [[Gate Array]] - Custom chip (frequency generation, colors, bank switching)&lt;br /&gt;
* [[Power Supply for CPC and CPC plus]]&lt;br /&gt;
* [[Printer Port]]&lt;br /&gt;
&lt;br /&gt;
=== Built-in connectors: pinout ===&lt;br /&gt;
&lt;br /&gt;
* [[Connector:2nd disc drive (CPC664, CPC6128, CPC6128+)|2nd disc drive (CPC664, CPC6128, CPC6128+)]]&lt;br /&gt;
* [[Connector:Analogue joystick (CPC Plus only)|Analogue joystick (CPC Plus only)]]&lt;br /&gt;
* [[Connector:Aux socket (CPC Plus only)|Aux socket (CPC Plus only)]] (Lightgun)&lt;br /&gt;
* [[Connector:Cartridge Slot (CPC Plus only)|Cartridge Slot (CPC Plus only)]]&lt;br /&gt;
* [[Connector:Cassette recorder|Cassette recorder]]&lt;br /&gt;
* [[Connector:Digital joystick|Digital joystick]]&lt;br /&gt;
* [[Connector:Expansion port|Expansion port]]&lt;br /&gt;
* [[Connector:Monitor|Monitor]]&lt;br /&gt;
* [[Connector:Printer port|Printer port]]&lt;br /&gt;
* [[Connector:Stereo sound|Stereo sound]]&lt;br /&gt;
&lt;br /&gt;
=== Built-in Firmware ===&lt;br /&gt;
&lt;br /&gt;
* [[BIOS Functions]]&lt;br /&gt;
* [[Locomotive BASIC]] (reference for BASIC commands, functions and error messages)&lt;br /&gt;
* [[Technical information about Locomotive BASIC]] (encoding of BASIC programs in memory)&lt;br /&gt;
&lt;br /&gt;
== Data transfer ==&lt;br /&gt;
&lt;br /&gt;
=== Modems ===&lt;br /&gt;
&lt;br /&gt;
* [[Cirkit_Prestel_Link_Amstrad_Interface]] (acoustic coupler bundled with [[Cirkit serial interface]]) ([[Cirkit]])&lt;br /&gt;
* [[Commstar v21/23 modem]] ([[PACE]])&lt;br /&gt;
* [[Data Research CH301S modem]] (greek company)&lt;br /&gt;
* [[Digitelec DTL 2000/2100 Modem]]&lt;br /&gt;
* [[EPTA modem]] (sold by Greek mag ΕΠΤΑ)&lt;br /&gt;
* [[KDS Communicator 104]] (connects directly to expansion port) ([[KDS Electronics]])&lt;br /&gt;
* [[Loritel]] (for french Minitel) ([[Loriciel|Loriciels]])&lt;br /&gt;
* [[Mini-Max Modem|KDS Mini-Max Modem]] (connects via RS232 interface) ([[KDS Electronics]])&lt;br /&gt;
* [[MicroLink Dual-Speed Modem]] ([[MicroLink]]) [[File:Microlink.pdf|Mircolink Manual]] and [[File:Micronet.pdf|Micronet manual]], provided by ''Spookspring''&lt;br /&gt;
* [[MicroLink Multi-Speed Modem]] ([[MicroLink]])&lt;br /&gt;
* [[Nightingale_modem]] ([[PACE]])&lt;br /&gt;
* [[Schneider BTX Modul]] (for German Bildschirmtext) ([[Schneider]])&lt;br /&gt;
&lt;br /&gt;
=== Serial Interfaces ===&lt;br /&gt;
&lt;br /&gt;
* ([[RS232|overview of RS232 interfaces]])&lt;br /&gt;
* [[Albireo]] (serial to USB on-board) ([[PulkoTronics]] / DIY)&lt;br /&gt;
* [[Aleste 520EX]] (a CPC clone with built-in RS232, intended for serial mouse) ([[Patisonic]])&lt;br /&gt;
* [[AMSSIO]] (four different versions) (RS232 interface) (DIY) (Martin Zacho)&lt;br /&gt;
* [[Amstrad Serial Interface]] ([[Amstrad]])&lt;br /&gt;
* [[Cirkit serial interface]] ([[Cirkit]])&lt;br /&gt;
* Cirkit twin-port serial interface (resold by [[Microstyle]])&lt;br /&gt;
* [[CPC Booster|CPC Booster/CPC Booster+]] (modern multifunction expansion, including RS232)&lt;br /&gt;
* [[CPCI RS232 Interface]] (DIY) ([[CPC Schneider International Sonderheft]])&lt;br /&gt;
* [[Data Media Disc System]] (disc drive with built-in RS232 interface) ([[Data Media]])&lt;br /&gt;
* [[KDS Electronics Serial Interface|KDS Serial Interface]] ([[KDS Electronics]])&lt;br /&gt;
* [[Panda Electronics Communications Interface Unit]] (dual RS232 plus 8bit printer port) (Panda Electronics Ltd)&lt;br /&gt;
* [[RS-232 para Amstrad]] ([[MHT Ingenieros]])&lt;br /&gt;
* [[SCA CPC Prolink]] ([[SCA Products]])&lt;br /&gt;
* [[Schneider RS232 Interface]] ([[Schneider]])&lt;br /&gt;
* [[Schneiderware V/24 Interface]] (DIY) ([[CPC Schneider International]])&lt;br /&gt;
* [[Simple RS232 for Printer usage]] (DIY) (one-directional, transmit only)&lt;br /&gt;
* [[Spectre Comms Serial Interface]] with Cage Comms software ([[Spectre Communications Ltd]])&lt;br /&gt;
* [[Vortex Disc Drives]] (disc drive/interface with optional RS232 port) ([[Vortex Computersysteme]])&lt;br /&gt;
* [[Z80-SIO dual ports RS232 interface for CPC (French)]] (DIY) (Philippe Lebel)&lt;br /&gt;
* [[Dual RS232]] ([[Timatic Systems]])&lt;br /&gt;
&lt;br /&gt;
=== Teletext ===&lt;br /&gt;
&lt;br /&gt;
* [[Teletext adaptor]] ([[Microtext Ltd.]])&lt;br /&gt;
* [[Volex TTX 2000a|Volex TTX 2000a Teletext-Telesoftware Adaptor]] (Volex Electronics)&lt;br /&gt;
&lt;br /&gt;
=== Others ===&lt;br /&gt;
&lt;br /&gt;
* [[CPC Booster|CPC Booster/CPC Booster+]]&lt;br /&gt;
* [[Virtual Net 96]] ([[Wizcat]])&lt;br /&gt;
* [[Red Box]] ([[General Information Systems]])&lt;br /&gt;
* [[CPC-ENet|CPC Ethernet Card]] ([[rpalmer]])&lt;br /&gt;
&lt;br /&gt;
== Digitizer / Scanner ==&lt;br /&gt;
&lt;br /&gt;
* [[ARA Video Digitizer]] ([[Jagot &amp;amp; Leon]])&lt;br /&gt;
* [[Electric Studio C6]] ([[Electric Studio]])&lt;br /&gt;
* [[Dart Scanner for DMP-Printers]] (the optics are attached to the printer head) ([[Dart Electronics]])&lt;br /&gt;
* [[Omni-Reader]] (Oberon International) (scanner with text recognition) (advert on ACU 1-1987, page 83)&lt;br /&gt;
* [[VIDI digitizer]] ([[Rombo Productions]])&lt;br /&gt;
&lt;br /&gt;
== Drives ==&lt;br /&gt;
&lt;br /&gt;
=== Disc Drives ===&lt;br /&gt;
&lt;br /&gt;
* [[3½&amp;quot; &amp;amp; 5¼&amp;quot; Disk Drives]]&lt;br /&gt;
* [[Amstrad Disk Drive|Amstrad DDI-1 / FD-1 Disk Drive]] ([[Amstrad]])&lt;br /&gt;
* [[Cumana 3&amp;quot; Disk Drive]] ([[Cumana]])&lt;br /&gt;
* [[Data Media Disc System]] ([[Data Media]])&lt;br /&gt;
* [[Jasmin AM5D 5 &amp;quot;1/4 floppy drive]]&lt;br /&gt;
* [[KDS 5¼&amp;quot; Disc Drive]] ([[KDS Electronics]])&lt;br /&gt;
* [[TIMDISC 5¼&amp;quot; 2nd Disc Drive]] ([[Timatic Systems]])&lt;br /&gt;
* [[F1|Vortex Disc Drives]] ([[Vortex Computersysteme|Vortex]])&lt;br /&gt;
* [[Four floppy drives with Amstrad disc interface]]&lt;br /&gt;
&lt;br /&gt;
=== Exotic Drives ===&lt;br /&gt;
&lt;br /&gt;
* [[Albireo]] (USB mass storage, SD card) ([[PulkoTronics]] / DIY)&lt;br /&gt;
* [[Codemasters CD]] (loads games from Audio CD via joystick port) ([[Codemasters]])&lt;br /&gt;
* [[Draysoft Doubler]] (external tape input, for tape-to-tape transfers) ([[Evesham Micros]])&lt;br /&gt;
* [[X-Mass]] (Solid-state disk on module)&lt;br /&gt;
&lt;br /&gt;
=== Hard Disc Drives ===&lt;br /&gt;
&lt;br /&gt;
* [[CPC-IDE]] (modern) (discontinued prototype)&lt;br /&gt;
* [[Dobbertin Harddisc]] ([[Dobbertin]])&lt;br /&gt;
* [[IDE8255]] internal/extrernal IDE/CF interface ([[Yarek]])&lt;br /&gt;
* [[SYMBiFACE II]] (modern) (IDE and various other features)&lt;br /&gt;
* [[Vortex Winchester Drive]] ([[Vortex Computersysteme|Vortex]])&lt;br /&gt;
* [[IDE/8255]] external IDE Interface ([[rpalmer]])&lt;br /&gt;
&lt;br /&gt;
=== Drive Emulators ===&lt;br /&gt;
&lt;br /&gt;
* [[HxC Floppy Emulator]]&lt;br /&gt;
* [[SDiskEmul]]&lt;br /&gt;
* [[TFE Floppy Emulator]]&lt;br /&gt;
* [[VDrive]]&lt;br /&gt;
&lt;br /&gt;
== Hardware debuggers/Hacking devices ==&lt;br /&gt;
&lt;br /&gt;
* [[Action Replay]] (whatever snapshot) ([[Datel Electronics]])&lt;br /&gt;
* [[Disc Wizard]] (whatever snapshot) ([[Evesham Micros]])&lt;br /&gt;
* [[Hackit|Hackit / Le Hacker]] (allows to view RAM at 0040h..AF00h) ([[Siren Software]])&lt;br /&gt;
* [[Mirage Imager]] (RAM-only snapshot) (Mirage Microcomputer Limited)&lt;br /&gt;
* [[Multiface II]] (RAM-and-I/O snapshot) ([[Romantic Robot]])&lt;br /&gt;
* [[PDS development system]] (old devkit been used for commercial games) (PD Systems/Andy Glaister)&lt;br /&gt;
* [[RAM7 Cartridge Hacker]] (for CPC+/GX4000 cartridges) ([[RAM7]])&lt;br /&gt;
* [[Transtape]] (whatever snapshot) (Hard Micro)&lt;br /&gt;
&lt;br /&gt;
== Input devices ==&lt;br /&gt;
&lt;br /&gt;
=== Joysticks ===&lt;br /&gt;
&lt;br /&gt;
* [[Analog Joysticks]] (CPC Plus only)&lt;br /&gt;
* [[Digital Joysticks]]&lt;br /&gt;
* [[Amstrad JY-1/JY-2 joysticks]]&lt;br /&gt;
* [[Joystick Y-cables]]&lt;br /&gt;
&lt;br /&gt;
=== Light-Guns ===&lt;br /&gt;
&lt;br /&gt;
* [[Gunstick]] ([[MHT Ingenieros]])&lt;br /&gt;
* [[Amstrad Magnum Phaser|Magnum Light Phaser]] ([[Amstrad]] and [[Trojan]])&lt;br /&gt;
* [[Trojan Light Phazer]] ([[Trojan]]) (CPC+)&lt;br /&gt;
* [[Loriciel Phaser (West Phaser)|West Phaser]] ([[Loriciel]])&lt;br /&gt;
&lt;br /&gt;
=== Light-Pens ===&lt;br /&gt;
&lt;br /&gt;
* [[Amstrad LP-1 light pen]] (Amstrad/Amsoft/Trojan) aka Trojan CAD-Master Lightpen (Trojan)&lt;br /&gt;
* [[ASS Light-Pen]] ([[ASS]])&lt;br /&gt;
* [[Dart Light Pen]] ([[Dart Electronics]])&lt;br /&gt;
* [[Datapen]] ([[Datapen Microtechnology Ltd]])&lt;br /&gt;
* [[dk'tronics Lightpen|Dk'tronics Light Pen]] ([[Dk'tronics]])&lt;br /&gt;
* [[Happy Computer Light Pen]] (DIY from german magazine)&lt;br /&gt;
* [[Light Pen Professional / Mark II (Electric Studio)|Light Pen Professional / Mark II]] ([[Electric Studio]])&lt;br /&gt;
* [[Lindy Light Pen]] ([[Lindy]])&lt;br /&gt;
&lt;br /&gt;
=== Mouse ===&lt;br /&gt;
&lt;br /&gt;
* [[Albireo]] with USB mouse ([[PulkoTronics]] / DIY)&lt;br /&gt;
* [[AMX Mouse]] (Advanced Memory Systems)&lt;br /&gt;
* [[PS2Mouse|AMX Compatible PS/2 and USB Mouse Adapter]] (DIY)&lt;br /&gt;
* [[Atari-ST mouse adapter]] (DIY) ([[Schneider Magazin]])&lt;br /&gt;
* [[dk'tronics Mouse Interface|Dk'tronics Mouse Interface]] ([[Dk'tronics]])&lt;br /&gt;
* [[CPC-Mousepack 2.0]] (Gerdes/Centaur/Reis-ware/ASS)&lt;br /&gt;
* [[Electric Studio Mouse]] ([[Electric Studio]])&lt;br /&gt;
* [[GEOS mouse|GEOS mouse]] ([[Commodore 64|C64]])&lt;br /&gt;
* [[Genius mouse]] ([[Datel Electronics]])&lt;br /&gt;
* [[Kempston Mouse]] (Kempston)&lt;br /&gt;
* [[Marconi|Marconi trackball]]&lt;br /&gt;
* [[Serial RS232 Mouse]]&lt;br /&gt;
* [[SYMBiFACE II:PS/2 mouse|PS/2 mouse]] of [[SYMBiFACE II]]&lt;br /&gt;
* [[Wireless mouse (DIY)]] (what is this?) (added 19 August 2006 by CPCLER)&lt;br /&gt;
&lt;br /&gt;
=== Others ===&lt;br /&gt;
&lt;br /&gt;
* [[CPCKey|Attaching an AT keyboard to the CPC]]&lt;br /&gt;
* [[Grafpad II]] (Hegotron/British Micro/Grafsales)&lt;br /&gt;
* [[Graphiscop II]] (M.M.C.)&lt;br /&gt;
* [[Keyboard Membrane Repair/Replacement Guide|Keyboard Repair/Replacement]]&lt;br /&gt;
&lt;br /&gt;
== Memory expansions / ROM boxes ==&lt;br /&gt;
&lt;br /&gt;
=== Memory Expansions / RAM discs ===&lt;br /&gt;
&lt;br /&gt;
* ([[Standard Memory Expansions]])&lt;br /&gt;
* [[ANTA 64K Memory Expansion]] ([[MHT Ingenieros]])&lt;br /&gt;
* [[CPC4MB| CPC4MB - 4 MB memory expansion]] ([[Yarek]])&lt;br /&gt;
* [[c't 512 KB internal RAM expansion]] (DIY) (c't magazine)&lt;br /&gt;
* [[Data Media Memory Expansion]] ([[Data Media]])&lt;br /&gt;
* [[Dk'tronics memory expansion‎|Dk'tronics Memory Expansion and Silicon Disc]] ([[Dk'tronics]])&lt;br /&gt;
* [[Dobbertin Memory Expansion]] ([[Dobbertin]]) - 64 KB to 512 KB RAM&lt;br /&gt;
* [[Inicron RAM-Box]] (Inicron) - 512 KB RAM&lt;br /&gt;
* [[Otten &amp;amp; Fecht 1 MB RAM-Disc]] ([[Otten/Fecht]])&lt;br /&gt;
* [[Phoenix M64]] - 64 KB RAM&lt;br /&gt;
* [[RAM BOX]] 512 KB memory expansion&lt;br /&gt;
* [[RAM7 2MB memory expansion]] ([[RAM7]]) - 2 MB RAM&lt;br /&gt;
* [[SYMBiFACE II]] - 512 KB RAM&lt;br /&gt;
* [[Vortex Expansions RAM card]] ([[Vortex Computersysteme|Vortex]]) - 512 KB RAM&lt;br /&gt;
&lt;br /&gt;
=== ROM Box / ROM Board ===&lt;br /&gt;
&lt;br /&gt;
* [[ACU Romboard (DIY)|ACU Romboard]] (DIY) ([[Phil Craven]]/[[Amstrad Computer User|ACU]])&lt;br /&gt;
* [[ACU Romchanger]] (DIY) ([[Phil Craven]]/[[Amstrad Computer User|ACU]]) - a CPC6128 ROM (BIOS v3, BASIC v1.1) upgrade for the CPC464&lt;br /&gt;
* [[AD1 ROM Cartridge]] ([[Arnor]])&lt;br /&gt;
* [[AMRAM]] ([[Silicon Systems]])&lt;br /&gt;
* [[AMRAM2]] ([[Silicon Systems]])&lt;br /&gt;
* [[Amstrad ROM Expander]] (DIY) (Practical Electronics/Simon Dean)&lt;br /&gt;
* [[Britannia ROM Board]] aka ROM Plus ([[Britannia Software Ltd]])&lt;br /&gt;
* [[Cirkit HX-RX1 Rom Expansion Card]] ([[Cirkit]]) (what is this?) (added  3 September 2006 by Torn) (also listed on [[Hwlist from retroisle]])&lt;br /&gt;
* [[CPC.Flash]] internal/external 4MB ROM upgrade ([[Yarek]])&lt;br /&gt;
* [[CPC GX4000-Multi EPROM Cartridge]] Use a GX cartridge for modified ROM software&lt;br /&gt;
* [[Dobbertin EPROM 224]] ([[Dobbertin]])&lt;br /&gt;
* [[Fleet EPROM Programmer|Fleet EPROM Programmer]] (F.Kup and Fleet Microsystems Ltd.)&lt;br /&gt;
* [[FO-DOS|FO-DOS Cartridge]] - a CPC6128 ROM (BIOS v3, BASIC v1.1) upgrade for the CPC464 ([[Duchet Computers]])&lt;br /&gt;
* [[Hexam]] ([[Ace Software]])&lt;br /&gt;
* [[Honeysoft ROM Board]] ([[HoneySoft]])&lt;br /&gt;
* [[Inicron ROM-RAM-Box]] (Inicron)&lt;br /&gt;
* [[KDS Sideways ROM Board]] ([[KDS Electronics]])&lt;br /&gt;
* [[LowerROM]] ([[Bryce]])&lt;br /&gt;
* [[Maplin ROM Box]] ([[Maplin]])&lt;br /&gt;
* [[MegaFlash]] (DIY - Bryce) 512 KB ROM simulator using Flash, in-system programmable&lt;br /&gt;
* [[MegaROM]] (DIY - Bryce) 128K / 256K ROMBoard&lt;br /&gt;
* [[Microgenic ROM Board]] ([[Microgenic Systems]])&lt;br /&gt;
* [[Microgenic EPROM Programmer]] ([[Microgenic Systems]])&lt;br /&gt;
* [[Microstyle RAMROM]] ([[Microstyle]])&lt;br /&gt;
* [[Microstyle ROM Board Xtra]] ([[Microstyle]])&lt;br /&gt;
* [[POKROM]] (DIY) (Electronique Radio Plans, issue 517)&lt;br /&gt;
* [[Ramcard 128]] (a ROM emulator) ([[RAM7]])&lt;br /&gt;
* [[Rombo Rombox]] ([[Rombo Productions]])&lt;br /&gt;
* [[Schneiderware EPROM Burner]] (DIY) ([[CPC Schneider International]])&lt;br /&gt;
* [[Schneiderware Pseudo ROM]] (DIY) ([[CPC Schneider International]])&lt;br /&gt;
* [[Sideways ram]] (Paul Townsend)&lt;br /&gt;
* [[SuperPower ROM Box]] ([[Micro Power Ltd.]])&lt;br /&gt;
* [[Universeller EPROM Programmer 4004]] ([[Dobbertin]])&lt;br /&gt;
* [[X-MEM]] ([[ACME]])&lt;br /&gt;
* [[X-ROM]] Eprom programmer and ROM Board ([[Timatic Systems]])&lt;br /&gt;
&lt;br /&gt;
== Monitors ==&lt;br /&gt;
* Computers [[monitor_compatible|compatible]] with Amstrad Monitors&lt;br /&gt;
* [[CM14|Amstrad CM14]] Colour Monitor (for CPC Plus)&lt;br /&gt;
* [[CTM640/CTM644|Amstrad CTM640/CTM644]] Color Monitor (for CPC 464/664/6128)&lt;br /&gt;
* [[GT64/GT65|Amstrad GT64/GT65]] Green Monitor (for CPC 464/664/6128)&lt;br /&gt;
* [[MM12|Amstrad MM12]] Monochrome Monitor (for CPC Plus)&lt;br /&gt;
* [[Amstrad MP1/MP2 modulator]]&lt;br /&gt;
* [[Amstrad MPV 001 modulator]] (Spanish MP1)&lt;br /&gt;
* [[MP2F|Amstrad MP-2F Scart Adapter]] (French MP2)&lt;br /&gt;
* [[MP-3|Amstrad MP-3 TV Tuner for CTM 644]]&lt;br /&gt;
* [[MPS Modulator]] Modulator made in Greece from MPS&lt;br /&gt;
* [[Dk'tronics TV Tuner]] ([[Dk'tronics]]) (similar to MP-3)&lt;br /&gt;
* [[Screenvision TV Tuner]] (Screens Microcomputers &amp;amp; Electronics Ltd.) (similar to MP-3)&lt;br /&gt;
* CPCI HF-modulator (CPC Schneider International 11/1986, Page 78ff. Someone please scan it, my issue lacks those pages!)&lt;br /&gt;
* [[TV SCART cable]] (DIY)&lt;br /&gt;
* [[LCD And Plasma TV Solution]] (DIY)&lt;br /&gt;
* [[Videomaster]] Modulator made in 1993 by Campursoft&lt;br /&gt;
&lt;br /&gt;
== Multi function expansions ==&lt;br /&gt;
&lt;br /&gt;
* [[Albireo]] ([[PulkoTronics]] / DIY)&lt;br /&gt;
* [[CPC Booster|CPC Booster/CPC Booster+]]&lt;br /&gt;
* [[CPCISA by Yarek]] ([[Yarek]])&lt;br /&gt;
* [[CPCMax!]]&lt;br /&gt;
* [[CPCX]]&lt;br /&gt;
* [[Full Expandable Interface]] ([[Timatic Systems]])&lt;br /&gt;
* [[PlayCity]]&lt;br /&gt;
* [[SYMBiFACE II]]&lt;br /&gt;
&lt;br /&gt;
== Printers ==&lt;br /&gt;
&lt;br /&gt;
* ([[8bit Printer Ports]])&lt;br /&gt;
* ([[Amstrad Printers]])&lt;br /&gt;
* [[DMP1]] printer ([[Amstrad]]) ([[Seikosha]] Unihammer printer)&lt;br /&gt;
* [[DMP2000]] printer ([[Amstrad]]/[[Schneider]]) ([[Epson]]-compatible 9-pin printer)&lt;br /&gt;
* [[DMP2160]] printer ([[Amstrad]]/[[Schneider]]) (fast version of DMP2000)&lt;br /&gt;
* [[DMP3000]] printer ([[Amstrad]]/[[Schneider]]) (gray PC-version of DMP2000 with more ROM/RAM and IBM charset)&lt;br /&gt;
* [[DMP3160]] printer ([[Amstrad]]/[[Schneider]]) (fast version of DMP3000)&lt;br /&gt;
* [[DMP3250]]di printer ([[Amstrad]]) (dual interface version of DMP3160) (centronics + RS232)&lt;br /&gt;
* [[DMP4000]] printer ([[Amstrad]]/[[Schneider]]) ([[Epson]]-compatible 9-pin 16&amp;quot; wide printer)&lt;br /&gt;
* [[LD6000]] laser printer ([[Amstrad GmbH]]) (re-badgered Sharp printer, for German market only)&lt;br /&gt;
* [[LQ3500]](di) printer ([[Amstrad]]/[[Schneider]]) ([[Epson]]-compatible 24-pin printer)&lt;br /&gt;
* [[LQ5000]]di printer ([[Amstrad]]) ([[Epson]]-compatible 24-pin 16&amp;quot; wide printer)&lt;br /&gt;
* [[Robotron 6313|EuroPrint FT80X, Robotron 6313, Präsident 6320]] (east German)&lt;br /&gt;
* [[NLQ401|Schneider NLQ401]] ([[Schneider]]) (custom 9-pin printer, German counterpart of the DMP1)&lt;br /&gt;
* [[Star Printers]] (Star Micronics Co., Ltd.)&lt;br /&gt;
&lt;br /&gt;
== Real Time Clocks ==&lt;br /&gt;
&lt;br /&gt;
* [[ACU Real Time Clock (DIY)|ACU Real Time Clock]] (DIY) (without year counter) ([[Amstrad Computer User|ACU]])&lt;br /&gt;
* [[Aleste 520EX]] (a CPC clone with built-in RTC) ([[Patisonic]])&lt;br /&gt;
* [[Real Time Clock|CPCI Real Time Clock]] (DIY) ([[CPC Schneider International Sonderheft]])&lt;br /&gt;
* [[Dk'tronics Real Time Clock]] ([[Dk'tronics]])&lt;br /&gt;
* [[Dobbertin Smart Watch]] (the RTC itself is inserted like a ROM) ([[Dobbertin]])&lt;br /&gt;
* [[Schneiderware Real Time Clock]] (DIY) ([[CPC Schneider International]])&lt;br /&gt;
* [[SYMBiFACE_II:Realtime_clock|Realtime Clock]] of [[SYMBiFACE_II]] (modern RTC with bugged century counter)&lt;br /&gt;
&lt;br /&gt;
== Synthesizer, sampler and music related ==&lt;br /&gt;
&lt;br /&gt;
* [[Amdrum]] (Playback) ([[Cheetah]])&lt;br /&gt;
* [[Amstrad SSA-1 Speech Synthesizer]] (Speech) ([[Amstrad]])&lt;br /&gt;
* [[CPC Booster|CPC Booster/CPC Booster+]] (Stereo Sampling/Playback) ([[Antitec]]/[[Dirty Minds]])&lt;br /&gt;
* [[Datel Digital Sound Sampler]]/[[Datel Electronics]]&lt;br /&gt;
* [[Digiblaster]] (Playback) (DIY) (8bit DAC on printer port) ([[CPC Amstrad International]])&lt;br /&gt;
* [[Digivox sampler]] (EMM)&lt;br /&gt;
* [[Dk'tronics Speech Synthesizer]] (Speech) ([[Dk'tronics]])&lt;br /&gt;
* [[DHCP MIDI Interface]] (DHCP Electronics)&lt;br /&gt;
* [[EMR MIDI Interface]] (MIDI) ([[EMR|ElectroMusic Research]])&lt;br /&gt;
* [[FuturePlayer]] (modern MP3 playback, max 128kbps) (Hard: Dr.Zed, Soft: TFM)&lt;br /&gt;
* [[Maestro]] (Amplifier/Speakers) (Vanguard Leisure Ltd.)&lt;br /&gt;
* [[Magic Sound Board]] for [[Aleste 520EX]] (four channel DMA playback) ([[Patisonic]])&lt;br /&gt;
* [[Mini Interface for connection to MK5 MIDI Keyboard]] ([[Cheetah]])&lt;br /&gt;
* [[Music Machine]] (Sampling/Playback/MIDI) ([[Ram Electronics]])&lt;br /&gt;
* [[MHT Speech Synthesizer]] (Speech) ([[MHT Ingenieros]])&lt;br /&gt;
* [[Silicon Systems MIDI Interface]] ([[Silicon Systems]]) (what is this?) (added 3 September 2006 by Torn) (also listed on [[Hwlist from retroisle]])&lt;br /&gt;
* [[Sound Blaster]] (Amplifier/Speakers) ([[Siren Software]]&lt;br /&gt;
* [[Soundplayer]] (many different versions exist) (Playback) ([[Futurs']])&lt;br /&gt;
* [[TechniMusique Synthetiseur Musical|TMPI musical synthesizer]] (12 voices) ([[TechniMusique]])&lt;br /&gt;
* [[TMPI speech synthesizer]] (Speech) ([[TechniMusique]])&lt;br /&gt;
* [[Unconventional use of hardware to produce sounds]]&lt;br /&gt;
&lt;br /&gt;
== Cartridge ==&lt;br /&gt;
&lt;br /&gt;
* [[C4CPC|C4CPC]]  a modern cartridge replacement for the Amstrad Plus range and the GX4000.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Miscellaneous ==&lt;br /&gt;
&lt;br /&gt;
* 64 Kb Printer Buffer (DIY) (what is this?) (added 19 August 2006 by CPCLER)&lt;br /&gt;
* [[Ambug|Ambug Robot]] (DIY) ([[Magenta Electronics Ltd.]])&lt;br /&gt;
* [[Amstore]] (network with 20MB harddisk) (Northern Computers)&lt;br /&gt;
* [[Amstrad Autofire Interface and Combined Mouse Interface|Amstrad Autofire Interface and Combined Mouse Interface]] (Unknown firm??)&lt;br /&gt;
* Amstrad Expansion System Part 2 ([[Maplin]]) - appeared in Project book 19 (for Part 1 see [[Maplin ROM Box]])&lt;br /&gt;
* [[Amstrad CT-1 Radio/Alarm-Clock]] ([[Amstrad]])&lt;br /&gt;
* [[CPCISA by Yarek|CPCISA]] ([[Yarek]])&lt;br /&gt;
* [[Data Media Printerinterface]] (printer splitter for connecting 2 or 3 software-selectable printers to the CPC) ([[Data Media]])&lt;br /&gt;
* [[DCP Interpacks]] (DCP Microdevelopments)&lt;br /&gt;
* [[Dust Covers]]&lt;br /&gt;
* [[Fischertechnik Interface]] for use with the [[Fischertechnik Trainingsrobot]], the [[Fischertechnik Plotter/Scanner]], and the [[Fischertechnik Computing Experimental]] kit.&lt;br /&gt;
* [[HDCPC]] (what is this?) (added 21 August 2006 by 85.218.166.50) (according to [[Dobbertin Harddisc|this page]], HDCPC is a modern IDE harddisk interace, but it's unknown who developed that thing?)&lt;br /&gt;
* [[Hexam]] ([[ACE Software]])&lt;br /&gt;
* [[Jagot &amp;amp; Leon Interface Cards]] ([[Jagot &amp;amp; Leon]])&lt;br /&gt;
* [[KDS Power Controller]] (a box with eight relays) ([[KDS Electronics]])&lt;br /&gt;
* [[Kersten PC Emulator]]&lt;br /&gt;
* [[Maplins 8bit Input Port]] ([[Maplin]]) (among others for use with Maplin's Weather Satellite Decoder)&lt;br /&gt;
* [[Maplin ROM Box|Maplins 6x8bit Input/Output Port]] ([[Maplin]]) (an extension to Maplin's &amp;quot;Rombox&amp;quot; project)&lt;br /&gt;
* [[Maplins Weather Satellite Receiver]] ([[Maplin]])&lt;br /&gt;
* [[Oktett]] (multimeter/oscilloscope) ([[Otten/Fecht]])&lt;br /&gt;
* [[Peripheral Soft Reset]] (System BIOS Feature for Peripherals)&lt;br /&gt;
* [[Schneiderware]] (a series of [[ECB Bus]] based DIY projects that were released in [[CPC Schneider International]] magazine)&lt;br /&gt;
* [[Split Extension Connector|Cheetah Marketing Split Extension Connector]] ([[Cheetah]])&lt;br /&gt;
* Teleterminal 300s (reportedly &amp;quot;simulates&amp;quot; rs232; connects to printer port; for use with acoustic coupler, see review in CPCI 8-1985, page 55-56)&lt;br /&gt;
* [[Slomo]] A device to reduce the execution speed of the Amstrad CPC (also available for other machines) by [[Nidd Valley Micro Products]], Ltd. (UK)&lt;br /&gt;
&lt;br /&gt;
Some further (unsorted) peripherals are found here: [[Hwlist from retroisle]]. More DIYs are listed on [[Happy Computer (Schneider Sonderheft)]] (those german magazine articles aren't yet scanned).&lt;br /&gt;
&lt;br /&gt;
[[Category:Peripherals| ]][[Category:Hardware|*]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94926</id>
		<title>Programming:Next / previous line calculation</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94926"/>
				<updated>2016-01-16T11:11:34Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Fastest way to print a character in Mode 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Next line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the next line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_NEXT_LINE equ #BC26&lt;br /&gt;
&lt;br /&gt;
call SCR_NEXT_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC26 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:add #08:ld h,a:and #38:ret nz&lt;br /&gt;
ld a,h:sub #40:ld h,a:ld a,l:add reg1*2:ld l,a:ret nc  ;reg1= CRTC reg.1 value&lt;br /&gt;
inc h:ld a,h:and #07:ret nz&lt;br /&gt;
ld a,h:sub #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Without Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF,BC&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
; Richard Fairhurst &lt;br /&gt;
; October 1997 &lt;br /&gt;
; &lt;br /&gt;
;*** Next line down from HL *** &lt;br /&gt;
&lt;br /&gt;
.nline  ld a,8 &lt;br /&gt;
        add h &lt;br /&gt;
        ld h,a &lt;br /&gt;
        ret nc&lt;br /&gt;
        ld bc,#c050&lt;br /&gt;
        add hl,bc &lt;br /&gt;
        ret&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Previous line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the previous line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the previous line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_PREV_LINE equ #BC29&lt;br /&gt;
&lt;br /&gt;
call SCR_PREV_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC29 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:sub #08:ld h,a:and #38:cp #38:ret nz&lt;br /&gt;
ld a,h:add #40:ld h,a:ld a,l:sub reg1*2:ld l,a:ret nc ; reg1= CRTC reg.1 value&lt;br /&gt;
ld a,h:dec h:and #07:ret nz&lt;br /&gt;
ld a,h:add #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Fastest way to print a character in Mode 2 =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address of sprite/char.data    DE=screen address (works for every first line of screen !! For example: &amp;amp;C000, &amp;amp;C050, &amp;amp;C0A0 etc..)&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF, C&lt;br /&gt;
&lt;br /&gt;
'''Unchanged:''' DE returns to its input value (through C register)&lt;br /&gt;
&lt;br /&gt;
''''If HL is not page aligned, INC HL must be used instead of INC L (1 NOP SLOWER!)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ld c,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:ld d,c:set 4,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:ld d,c:set 5,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 4,d:res 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a&lt;br /&gt;
ld d,c&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94925</id>
		<title>Programming:Next / previous line calculation</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94925"/>
				<updated>2016-01-16T11:07:53Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Next line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the next line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_NEXT_LINE equ #BC26&lt;br /&gt;
&lt;br /&gt;
call SCR_NEXT_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC26 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:add #08:ld h,a:and #38:ret nz&lt;br /&gt;
ld a,h:sub #40:ld h,a:ld a,l:add reg1*2:ld l,a:ret nc  ;reg1= CRTC reg.1 value&lt;br /&gt;
inc h:ld a,h:and #07:ret nz&lt;br /&gt;
ld a,h:sub #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Without Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF,BC&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
; Richard Fairhurst &lt;br /&gt;
; October 1997 &lt;br /&gt;
; &lt;br /&gt;
;*** Next line down from HL *** &lt;br /&gt;
&lt;br /&gt;
.nline  ld a,8 &lt;br /&gt;
        add h &lt;br /&gt;
        ld h,a &lt;br /&gt;
        ret nc&lt;br /&gt;
        ld bc,#c050&lt;br /&gt;
        add hl,bc &lt;br /&gt;
        ret&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Previous line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the previous line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the previous line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_PREV_LINE equ #BC29&lt;br /&gt;
&lt;br /&gt;
call SCR_PREV_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC29 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:sub #08:ld h,a:and #38:cp #38:ret nz&lt;br /&gt;
ld a,h:add #40:ld h,a:ld a,l:sub reg1*2:ld l,a:ret nc ; reg1= CRTC reg.1 value&lt;br /&gt;
ld a,h:dec h:and #07:ret nz&lt;br /&gt;
ld a,h:add #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Fastest way to print a character in Mode 2 =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address  DE=screen address (works for every first line of screen !! For example: &amp;amp;C000, &amp;amp;C050, &amp;amp;C0A0 etc..)&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF, C&lt;br /&gt;
&lt;br /&gt;
'''Unchanged:''' DE returns to its input value (through C register)&lt;br /&gt;
&lt;br /&gt;
''''If HL is not page aligned, INC HL must be used instead of INC L (1 NOP SLOWER!)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ld c,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:ld d,c:set 4,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:ld d,c:set 5,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 4,d:res 3,d&lt;br /&gt;
ld a,(hl):ld(de),a:inc l:set 3,d&lt;br /&gt;
ld a,(hl):ld(de),a&lt;br /&gt;
ld d,c&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	<entry>
		<id>https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94922</id>
		<title>Programming:Next / previous line calculation</title>
		<link rel="alternate" type="text/html" href="https://oldwiki.cpcwiki.eu/index.php?title=Programming:Next_/_previous_line_calculation&amp;diff=94922"/>
				<updated>2016-01-16T10:46:25Z</updated>
		
		<summary type="html">&lt;p&gt;Fgbrain: /* Firmware */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Next line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the next line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_NEXT_LINE equ #BC26&lt;br /&gt;
&lt;br /&gt;
call SCR_NEXT_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC26 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:add #08:ld h,a:and #38:ret nz&lt;br /&gt;
ld a,h:sub #40:ld h,a:ld a,l:add reg1*2:ld l,a:ret nc  ;reg1= CRTC reg.1 value&lt;br /&gt;
inc h:ld a,h:and #07:ret nz&lt;br /&gt;
ld a,h:sub #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Without Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the next line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF,BC&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
; Richard Fairhurst &lt;br /&gt;
; October 1997 &lt;br /&gt;
; &lt;br /&gt;
;*** Next line down from HL *** &lt;br /&gt;
&lt;br /&gt;
.nline  ld a,8 &lt;br /&gt;
        add h &lt;br /&gt;
        ld h,a &lt;br /&gt;
        ret nc&lt;br /&gt;
        ld bc,#c050&lt;br /&gt;
        add hl,bc &lt;br /&gt;
        ret&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Previous line =&lt;br /&gt;
&lt;br /&gt;
This routines calculate the previous line from the given address.&lt;br /&gt;
&lt;br /&gt;
== Firmware ==&lt;br /&gt;
&lt;br /&gt;
'''Input:''' HL=Address&lt;br /&gt;
&lt;br /&gt;
'''Output:''' HL=Address of the previous line&lt;br /&gt;
&lt;br /&gt;
'''Destroyed:''' AF&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
SCR_PREV_LINE equ #BC29&lt;br /&gt;
&lt;br /&gt;
call SCR_PREV_LINE&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ACTUAL #BC29 ROUTINE FOLLOWS:&lt;br /&gt;
&lt;br /&gt;
ld a,h:sub #08:ld h,a:and #38:cp #38:ret nz&lt;br /&gt;
ld a,h:add #40:ld h,a:ld a,l:sub reg1*2:ld l,a:ret nc ; reg1= CRTC reg.1 value&lt;br /&gt;
ld a,h:dec h:and #07:ret nz&lt;br /&gt;
ld a,h:add #08:ld h,a:ret&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>Fgbrain</name></author>	</entry>

	</feed>