During the development of the ZX Spectrum SE, it was originally planned to replace the ULA (which creates the display) with something a little more advanced. However, it wasn't until nearly a decade later after the ULA was reverse engineered that this actually became possible. ULAplus was finally realized in an FPGA core by Alessandro Dorigatti in February 2011. This core is used in all of the current implementations.
Currently there are emulators available for Windows, Linux, MacOS X, and iOS and ULAplus is becoming a must-have feature. Among the first emulators to offer support were BASin (the Sinclair BASIC IDE), an older version of Fuse (via patches), SpecEmu, Spud, and ZXSpin.
How do I recolour a game?
Is there a way for the Spectrum to automatically detect if ULAplus is present?
Yes. Write a palette register, PAUSE 1, and then read it back. If FFh is returned then it's a normal ULA. OUT 48955,0: OUT 65339,0: PAUSE 1: IN 65339 will return 00h if ULAplus is present.
Does it remove attribute clash?
Are there any tools for converting 24-bit images?
Yes. AY Chip has created SCRplus, a conversion tool for Linux and Windows which uses the SDL image library (and other unlisted dependencies). It is still a work in progress, but already the results are excellent. Ref and Claus Jahn have created their own Windows conversion tools based on the SCRplus code, and Dunny has created MakeSlideshow for building slideshows. Note: you can only click Add once, but you can select multiple items.
Does ULAplus work on real hardware?
ULAplus is designed to work on real hardware. It has been available as an FPGA core since February 2011, but the plug-in replacement is not yet available.
How is the BORDER colour determined?
In the standard Spectrum display it has the same value as the equivalent BRIGHT 0/FLASH 0 PAPER colour. In the Timex hi-res display it has the same value as the equivalent BRIGHT 1/FLASH 0 PAPER colour.
Does ULAplus support models besides the 48K?
In emulation all models are supported. In hardware you will need a different version depending on your machine. The 48K ULA will be the first model.
When can I get a real one to plug into my Spectrum?
When it's ready.
How will games that make active use of FLASH be affected?
FLASH doesn't work in the 64-colour mode. You get extra colours instead.
How do you switch on the 64-colour mode?
OUT 48955,64: OUT 65339,1.
OUT 48955,64: OUT 65339,0.
Why is my screen black?
The hardware can't set the palette registers by itself. By default the whole palette is black. Set some colours before turning on 64-colour mode.
What drawing tools are available?
There's the palette editor and a 6-bit RGB palette for Artist III with more in development.
How many colours can I have on screen at once?
A static screen using no CPU time can have 64 colours on screen at once. Changing the palette while the screen is drawing enables you to have 256 colours on screen at once. Switching between the 64-colour mode and the standard mode gives you an additional four colours (BRIGHT 0/FLASH 0 INKs 1, 3, 5, and 7) which are not present in the standard palette for a total of 260 colours on screen.
Could Sinclair have done this back in the day?
Yes, but more than one ULA would have been required and it would have been much more complicated and therefore expensive. It would take "...gazillions of gates and flip-flops. 64 * 8 Flip-Flop/latches for the palette storage = 512, plus a 640 2-input-nor gates for the multiplexing (4*16*8 + 16*8 ). That would take 832 matrix cells of the ULA, plus the other necessary circuitry. The 5C000 ULA had 440 matrix cells in total, so you'd need at least two ULAs of that size. This is so impractical that external memory would have been required for the palette. Propagation delay will have been the major issue, leading to other colour effects similar to the two-levels-of-intensity effect and the edge-artifact with flashing cells. As devices are much larger and efficient these days, it is likely to fit into a reasonably cheap CPLD. Worse case, a small amount of external memory may be required, or FPGA is used instead, as this will have the internal memory required. The design has been proven, but not synthesized, so I don't know how big a CPLD/FPGA is required." -- Chris Smith.
How does ULAplus work and how do you get 256 colours on screen at once?
"It's not actually that complicated. Imagine there's a little imp, whose job it is to paint whatever is in the Spectrum's memory onto your TV. He starts at the top left of the screen, looks in the first screen memory location and discovers which colour he should be painting the first pixel. He then moves onto the second pixel on the first row, looks up the colour for that pixel, paints it, and moves on and on across the first row. When he's done all that, he has a little break, then moves onto the second row, and so on. On a normal Spectrum, the imp's got a paintbox which has 16 colours in it, and you can't give him new colours. The new ULA gives two new capabilities: firstly, it expands the imp's paintbox from 16 to 64 colours, and secondly it lets the programmer change the paintbox. The second effect is what's going on here: because the imp doesn't draw the entire screen at once, but takes a certain amount of time to do it, you can change his paintbox while he's in the middle of drawing the screen. If you switch his paintbox for a different one when he's a half way down the screen, he'll paint the lower half of the screen with different colours from the top half, and you can then switch it back again before he paints the top half. That gets you from 64 to 128 colours - to get to 256, you just need to switch his paintbox when he's 1/4, 1/2 and 3/4 of the way down the screen. (The new ULA has a limit of 256 colours it can ever display, so you can't do any better than that)." -- Philip Kendall
How many colours do you get in a remapped game without hacking?
From 17 to 32 colours in games that use BRIGHT, up to 64 for those that also use FLASH.
Standard ULA timings will not change. Timings for reading and writing the palette registers are the same (and have the same contention) as reading and writing port #FE. Don't spend hours creating wonderful colour effects via palette updates until emulators have been updated to reflect the correct timing and contention.
The aim is to have a simple plug-in replacement that can be fitted by anyone who is moderately competent with a screwdriver. Fiddlyness will be kept to a minimum.
It clashes with the ZX Printer, and nothing else. This can be resolved by making sure the ZX Printer is fully decoded on port #FB, perhaps with a small hardware bridge.
The specification has been extended to include support for HSL and CMYK palettes. These are non-standard extensions and can safely be ignored by everything except the hardware that uses them. The RGB specification is mature. It will not change, even if it is "absolutely necessary" due to unforeseen issues with the hardware implementation.
Not unless there is a compelling reason to do so. However, the Timex screen modes will also work with ULAplus in the Harlequin clone. To date the only additional mode is the HSL palette mode.
It's an acronym for Colour Look-Up Table. ULAplus uses four separate CLUTs, selected using the attribute bits formerly used to select BRIGHT and FLASH.