• Due to ongoing issues caused by Search, it has been temporarily disabled
  • Please excuse the mess, we're moving the furniture and restructuring the forum categories

Spectrum Next: Anybody got one?

Ian Osborne

JREF Kid
Joined
Aug 4, 2001
Messages
8,945
Does anyone here have experience with the Spectrum Next, or one of its clones? I just bought an Xberry Pi (Next clone) and would be interested in swapping ideas with other users.
 
No but it looks intriguing. I've got a preorder in on the Retro Spectrum being released next month, rubber keys and all!
 
No but it looks intriguing. I've got a preorder in on the Retro Spectrum being released next month, rubber keys and all!

The actual Spectrum Next was funded by kickstarter (twice). You can only get them second hand now, and they command ridiculous prices on eBay.

I'll probably subscribe to a third kickstarter, but in the meantime, the clone I bought – at a third of the price of the actual Next – is 100% compatible.
 
I hadn't known about the SNext - have to say even the Kickstarter prices seem a rip-off, yeah it looks quite pretty but 300 quid for a computer that cost less than that when it was first introduced? As you say some of the eBay prices take it to silly money.
 
I hadn't known about the SNext - have to say even the Kickstarter prices seem a rip-off, yeah it looks quite pretty but 300 quid for a computer that cost less than that when it was first introduced? As you say some of the eBay prices take it to silly money.

It's not just a Spectrum, it offers numerous enhancements over Sir Clive's invention. It's very well thought of among tinkerers, and there's even a magazine for it (Next magazine).

And as I said, there's a clone for less than a hundred pounds.
 
I hadn't known about the SNext - have to say even the Kickstarter prices seem a rip-off, yeah it looks quite pretty but 300 quid for a computer that cost less than that when it was first introduced? As you say some of the eBay prices take it to silly money.

To be fair, the 48K Spectrum would be nearly £800 today after accounting for inflation. Which makes me wish I could thank my parents a bit more profusely than I did back then.

I also hadn't heard of it before, but it looks like it's expensive because it's more than just a quick knockoff, and the market for it is just too small to bring the price down.
 
Last edited:
To be fair, the 48K Spectrum would be nearly £800 today after accounting for inflation. Which makes me wish I could thank my parents a bit more profusely than I did back then.

I also hadn't heard of it before, but it looks like it's expensive because it's more than just a quick knockoff, and the market for it is just too small to bring the price down.

I agree with that but you can emulate a ZX-Spectrum on very little silicon today.
 
I was wondering something, I started with a ZX-81 and did some assembly coding but that was long, long ago, I am wondering if any of the latest LLMs can create assembly code for the z80?

ETA: Copilot claims it can:

Co Pilot

Certainly! Here's an example of assembly code for the ZX Spectrum to display "Hello, World!" on the screen:

Code:
        org 32768          ; Start of the program in memory

        ld hl, message     ; Load the address of the message into HL
        ld de, 16384       ; Start of the screen memory
        ld bc, 13          ; Length of the message
        call 8252          ; ROM routine to print the string

        ret                ; Return from the program

message:
        db 'Hello, World!', 0
```
This code uses the ROM routine at address 8252 to print the string to the screen. The message is stored in memory and is terminated with a null byte (0).

Feel free to ask if you need any more details or have other questions!
 
Last edited:
Interesting question. Any assembly code uses a very restricted set of allowed instructions and syntax. I'd guess once the "meaning" was derived by the LLM it should be fairly simple as these things go but could it find a data source that "explained" assembler to it? For varying values of several words used.
 
Interesting question. Any assembly code uses a very restricted set of allowed instructions and syntax. I'd guess once the "meaning" was derived by the LLM it should be fairly simple as these things go but could it find a data source that "explained" assembler to it? For varying values of several words used.

Lets see if it can handle an Atari 8-bit display list interupt coding...

"can you provide the code required for an Atari 400 to use display list interupts in screen mode 10 to set color 1 to a random value at row 80" (that is probably a very poorly worded prompt - I'm trying to recall details I've not used for 40 odd years, I think the mode would be correct - hires, 80x192 rows - quad sized pixels.)

Code:
        .org $6000          ; Start of the program in memory

        ; Set up the Display List
        lda #$70            ; LMS instruction with DLI enabled
        sta $2300           ; Store at the start of the display list
        lda #$00
        sta $2301
        lda #$40
        sta $2302
        lda #$0A            ; Mode 10 with DLI enabled
        sta $2303
        lda #$02
        sta $2304
        lda #$02
        sta $2305
        lda #$02
        sta $2306
        lda #$02
        sta $2307
        lda #$02
        sta $2308
        lda #$02
        sta $2309
        lda #$02
        sta $230A
        lda #$02
        sta $230B
        lda #$02
        sta $230C
        lda #$02
        sta $230D
        lda #$02
        sta $230E
        lda #$02
        sta $230F
        lda #$02
        sta $2310
        lda #$02
        sta $2311
        lda #$02
        sta $2312
        lda #$02
        sta $2313
        lda #$02
        sta $2314
        lda #$02
        sta $2315
        lda #$02
        sta $2316
        lda #$02
        sta $2317
        lda #$02
        sta $2318
        lda #$02
        sta $2319
        lda #$02
        sta $231A
        lda #$02
        sta $231B
        lda #$02
        sta $231C
        lda #$02
        sta $231D
        lda #$02
        sta $231E
        lda #$02
        sta $231F
        lda #$02
        sta $2320
        lda #$02
        sta $2321
        lda #$02
        sta $2322
        lda #$02
        sta $2323
        lda #$02
        sta $2324
        lda #$02
        sta $2325
        lda #$02
        sta $2326
        lda #$02
        sta $2327
        lda #$02
        sta $2328
        lda #$02
        sta $2329
        lda #$02
        sta $232A
        lda #$02
        sta $232B
        lda #$02
        sta $232C
        lda #$02
        sta $232D
        lda #$02
        sta $232E
        lda #$02
        sta $232F
        lda #$02
        sta $2330
        lda #$02
        sta $2331
        lda #$02
        sta $2332
        lda #$02
        sta $2333
        lda #$02
        sta $2334
        lda #$02
        sta $2335
        lda #$02
        sta $2336
        lda #$02
        sta $2337
        lda #$02
        sta $2338
        lda #$02
        sta $2339
        lda #$02
        sta $233A
        lda #$02
        sta $233B
        lda #$02
        sta $233C
        lda #$02
        sta $233D
        lda #$02
        sta $233E
        lda #$02
        sta $233F
        lda #$02
        sta $2340
        lda #$02
        sta $2341
        lda #$02
        sta $2342
        lda #$02
        sta $2343
        lda #$02
        sta $2344
        lda #$02
        sta $2345
        lda #$02
        sta $2346
        lda #$02
        sta $2347
        lda #$02
        sta $2348
        lda #$02
        sta $2349
        lda #$02
        sta $234A
        lda #$02
        sta $234B
        lda #$02
        sta $234C
        lda #$02
        sta $234D
        lda #$02
        sta $234E
        lda #$02
        sta $234F
        lda #$02
        sta $2350
        lda #$02
        sta $2351
        lda #$02
        sta $2352
        lda #$02
        sta $2353
        lda #$02
        sta $2354
        lda #$02
        sta $2355
        lda #$02
        sta $2356
        lda #$02
        sta $2357
        lda #$02
        sta $2358
        lda #$02
        sta $2359
        lda #$02
        sta $235A
        lda #$02
        sta $235B
        lda #$02
        sta $235C
        lda #$02
        sta $235D
        lda #$02
        sta $235E
        lda #$02
        sta $235F
        lda #$02
        sta $2360
        lda #$02
        sta $2361
        lda #$02
        sta $2362
        lda #$02
        sta $2363
        lda #$02
        sta $2364
        lda #$02
        sta $2365
        lda #$02
        sta $2366
        lda #$02
        sta $2367
        lda #$02
        sta $2368
        lda #$02
        sta $2369
        lda #$02
        sta $236A
        lda #$02
        sta $236B
        lda #$02
        sta $236C
        lda #$02
        sta $236D
        lda #$02
        sta $236E
        lda #$02
        sta $236F
        lda #$02
        sta $2370
        lda #$02
        sta $2371
        lda #$02
        sta $2372
        lda #$02
        sta $2373
        lda #$02
        sta $2374
        lda #$02
        sta $2375
        lda #$02
        sta $2376
        lda #$02
        sta $2377
        lda #$02
        sta $2378
        lda #$02
        sta $2379
        lda #$02
        sta $237A
        lda #$02
        sta $237B
        lda #$02
        sta $237C
        lda #$02
        sta $237D
        lda #$02
        sta $237E
        lda #$02
        sta $237F
        lda #$02
        sta $2380
        lda #$02
        sta $2381
        lda #$02
        sta $2382
        lda #$02
        sta $2383
        lda #$02
        sta $2384
        lda #$02
        sta $2385
        lda #$02
        sta $2386
        lda #$02
        sta $2387
        lda #$02
        sta $2388
        lda #$02
        sta $2389
        lda #$02
        sta $238A
        lda #$02
        sta $238B
        lda #$02
        sta $238C
        lda #$02
        sta $238D
        lda #$02
        sta $238E
        lda #$02
        sta $238F
        lda #$02
        sta $2390
        lda #$02
        sta $2391
        lda #$02
        sta $2392
        lda #$02
        sta $2393
        lda #$02
        sta $2394
        lda #$02
        sta $2395
        lda #$02
        sta $2396
        lda #$02
        sta $2397
        lda #$02
        sta $2398
        lda #$02
        sta $2399
        lda #$02
        sta $239A
        lda #$02
        sta $239B
        lda #$02
        sta $239C
        lda #$02
        sta $239D
        lda #$02
        sta $239E
        lda #$02
        sta $239F
        lda #$02
        sta $23A0
        lda #$02
        sta $23A1
        lda #$02

It looks the right type of format. Don't have an emulator with assembler set up at the moment to test it.

Display list interrupts were an obscure but immensely useful and powerful feature on the Atari 8-bits, it allowed you to run code everytime a scanline finished - what it meant is that you could run short bursts of code that could do things like change the display of an image in a Player Missile Graphic (what would go on to be known as sprites as the C64 popularity increased) , change the colours for the next scan line.
 
Last edited:
CALL THE BLOODY SINCLAIR ROM ROUTINE? Now I'm triggered. I'll huff and I'll puff and I'll blow your Sinclair computer off your table. The Sinclair ROMs were always optimized for size, not speed. Like, the ZX Spectrum BASIC was not just the slowest language on the Spectrum, it was even the slowest BASIC on the Spectrum. And you never knew which registers they'd use and thus push and pop for every call. And if we're talking ZX-81, what happened to just flippin' taking the address in the screen and just LDIR the string there? :p

*Walks away shaking his cane and muttering about how old people should keep off his lawn too*
 
Last edited:
CALL THE BLOODY SINCLAIR ROM ROUTINE? Now I'm triggered. I'll huff and I'll puff and I'll blow your Sinclair computer off your table. The Sinclair ROMs were always optimized for size, not speed.
Microsoft BASIC was also optimized for size, not speed. The first version - for the Altair 8800 - was squeezed into 4k bytes of memory. It had no string or integer types, only 32 bit floating point. As you can imagine, forcing an 8 bit integer-only CPU to do all numeric calculations in floating point doesn't help with speed.

The first Sinclair BASIC - for the ZX80 - also used up 4k of memory. It only had integer math, but did have strings. It also had a line editor with cursor control, unlike Microsoft BASIC (which forced you to type in the whole line again to modify it!).

ZX Spectrum BASIC was much larger at 16k, but had a lot more in it - including 40 bit floating point numbers. However it kept the same slow parser as the earlier ZX80 version, made even slower by having more to do. An empty FOR-NEXT loop is 5 times slower on the Spectrum than on the ZX80.

if we're talking ZX-81, what happened to just flippin' taking the address in the screen and just LDIR the string there?
The ZX81 doesn't have dedicated screen memory, it has a 'display file' whose position in memory can vary. During display time the CPU 'executes' the characters on the line, with the CPU data bus forced to a NOP instruction so it fetches each character in turn until the end of the line.

A stock ZX81 only has 1k of RAM, so allocating space for a full screen (32 characters x 24 lines = 768 bytes) would leave very little for user programs. The display list technique uses only one byte for blank lines and no bytes for white space at the end of each line. That can save a 'lot' of memory, but means the character positions are not at fixed memory locations.

To print a message on a line you first have to make space on the line, then insert the characters into it. A simple LDIR would work only if the line already contained at least as many characters as were being copied, otherwise it would overwrite the Newline character and corrupt the display list.

If you use the ROM routine you don't have to worry about all that. It will be slower, but uses up a lot less of your precious RAM. That's fine for just printing a 'hello world' message. For a game you would probably want to create a display list of appropriate size first, then you can poke into it knowing that the screen addresses won't change.

*Walks away shaking his cane and muttering about how old people should keep off his lawn too*
Modern computers are so incredibly powerful and inscrutable that (almost) nobody talks about coding efficiency anymore, which takes a lot of the fun out of it. That's why I prefer writing code for retro computers from the 80's and 90's. I also eschew enhanced modern recreations like the Spectrum Next for the same reason.
 
Ah, coding efficiency. I started coding on a Dragon 32 forty years ago and all the proper coding I did for the next decade was extremely resource restricted. The core executable within my MSc project work in 1992 weighed in at a highly optimised 19K.

My oldest nephew is a dev at a specialist software house and their solution to every problem is to throw more power at it. His main machine has something stupid like 64 cores and 2 tera of memory and he wouldn’t recognise optimisation if it punched him in the face.
 
Ah, coding efficiency. I started coding on a Dragon 32 forty years ago and all the proper coding I did for the next decade was extremely resource restricted. The core executable within my MSc project work in 1992 weighed in at a highly optimised 19K.

My oldest nephew is a dev at a specialist software house and their solution to every problem is to throw more power at it. His main machine has something stupid like 64 cores and 2 tera of memory and he wouldn’t recognise optimisation if it punched him in the face.

He doesn't need to recognise optimisation. He likely programs in a high level language and the compiler does a better job of optimisation than most humans could.
 
Microsoft BASIC was also optimized for size, not speed. The first version - for the Altair 8800 - was squeezed into 4k bytes of memory. It had no string or integer types, only 32 bit floating point. As you can imagine, forcing an 8 bit integer-only CPU to do all numeric calculations in floating point doesn't help with speed.

Yes, well, by the time of the Z-80 it had evolved.

The first Sinclair BASIC - for the ZX80 - also used up 4k of memory. It only had integer math, but did have strings. It also had a line editor with cursor control, unlike Microsoft BASIC (which forced you to type in the whole line again to modify it!).

Yes, I started on the ZX-80. I know. That's why I learned assembly. Well, I say "assembly", but I had to translate it into hex by hand :p

ZX Spectrum BASIC was much larger at 16k, but had a lot more in it - including 40 bit floating point numbers. However it kept the same slow parser as the earlier ZX80 version, made even slower by having more to do. An empty FOR-NEXT loop is 5 times slower on the Spectrum than on the ZX80.

Did I mention preferring assembly?

The ZX81 doesn't have dedicated screen memory, it has a 'display file' whose position in memory can vary. During display time the CPU 'executes' the characters on the line, with the CPU data bus forced to a NOP instruction so it fetches each character in turn until the end of the line.

Yeah, you could do all sorts of funky things with it. One resourceful fellow even figured out how to reprogram it to display actual graphics. Like on the Spectrum, just without the colour part. Well, if you had the 16k expansion so you'd have room for that.

Nevertheless, it doesn't change anything I've said. Not the least because unless you moved it yourself, it was at a fixed position anyway.

A stock ZX81 only has 1k of RAM, so allocating space for a full screen (32 characters x 24 lines = 768 bytes) would leave very little for user programs.

Hence converting it by hand to hex. Yeah, the damned thing didn't even have enough memory for an actual assembler,

The display list technique uses only one byte for blank lines and no bytes for white space at the end of each line. That can save a 'lot' of memory, but means the character positions are not at fixed memory locations.

So you might have to do some workarounds and maths. Whop-de-do. I can't say I remember running into that problem, tho. But maybe I already knew better or something.

To print a message on a line you first have to make space on the line, then insert the characters into it. A simple LDIR would work only if the line already contained at least as many characters as were being copied, otherwise it would overwrite the Newline character and corrupt the display list

... as I was saying.

If you use the ROM routine you don't have to worry about all that. It will be slower, but uses up a lot less of your precious RAM. That's fine for just printing a 'hello world' message. For a game you would probably want to create a display list of appropriate size first, then you can poke into it knowing that the screen addresses won't change.

I HAVE written games for it, but yeah, it's not as big a deal as you make it sound.
 
Last edited:
Ah, coding efficiency. I started coding on a Dragon 32 forty years ago and all the proper coding I did for the next decade was extremely resource restricted. The core executable within my MSc project work in 1992 weighed in at a highly optimised 19K.

My oldest nephew is a dev at a specialist software house and their solution to every problem is to throw more power at it. His main machine has something stupid like 64 cores and 2 tera of memory and he wouldn’t recognise optimisation if it punched him in the face.
FTFY
 
It's arrived! The feeling of nostalgia is overwhelming.


View attachment 57830
Never had my own Spectrum, after my ZX81 it was an Atari 400 but I can feel my hands' muscle memory causing twitches 10 ff Shift 0 1 shift 4 10 Enter 20 p shift P Hello World Shift P Enter 30 N Enter R Enter

(Please tell me that doesn't work - these days I can't remember what I go into a room for, yet 40 odd years ago coding sticks in the memory!)
 
Back
Top Bottom