The place for codemasters or beginners to talk about programming any language for the Spectrum.
-
R-Tape
- Site Admin
- Posts: 2588
- Joined: Thu Nov 09, 2017 11:46 am
Post
by R-Tape » Sun Jul 22, 2018 7:05 pm
Does anyone have any suggestions for a short machine code routine that crashes the Speccy in a visually and/or audibly impressive way, and returns it to a NEW state?
(and if yes, can I rip it off in my next game?

)
0 x
-
MatGubbins
- Manic Miner
- Posts: 537
- Joined: Mon Nov 13, 2017 11:45 am
- Location: Kent, UK
Post
by MatGubbins » Sun Jul 22, 2018 7:44 pm
Bunging a paper clip on the expansion port usually works a treat!
4 x
Bomb Munchies Ver1930 17th Nov 2017 (look for the blue download box ) If you get a time-out message and live in the UK then try after 9pm-3am.
Send me a PM and I can email it to you too. Kent, UK
-
R-Tape
- Site Admin
- Posts: 2588
- Joined: Thu Nov 09, 2017 11:46 am
Post
by R-Tape » Sun Jul 22, 2018 8:07 pm
MatGubbins wrote: ↑Sun Jul 22, 2018 7:44 pm
Bunging a paper clip on the expansion port usually works a treat!
Heh. Another Speccy to add to eBay's '
not tested but working' pile.
The best I can managed so far is a lazy border effect LDing down from the top of memory.
It might have to do, argh, in which case I should have kept it to myself

0 x
-
Ast A. Moore
- Dynamite Dan
- Posts: 1222
- Joined: Mon Nov 13, 2017 3:16 pm
Post
by Ast A. Moore » Sun Jul 22, 2018 8:32 pm
R-Tape wrote: ↑Sun Jul 22, 2018 7:05 pm
Does anyone have any suggestions for a short machine code routine that crashes the Speccy in a visually and/or audibly impressive way, and returns it to a NEW state?
(and if yes, can I rip it off in my next game?

)
Darn it. If I know you collected artsy Speccy crashes, I would have save a few for you. Just a few days ago I was making a fix for a game (don’t even remember which one), and it crashed just the way you want it: a few seconds of loading/saving sounds with the usual border animation followed by some random patterns on the screen and a reset.
2 x
-
1024MAK
- Manic Miner
- Posts: 532
- Joined: Wed Nov 15, 2017 2:52 pm
- Location: Sunny Somerset in the U.K. in Europe
Post
by 1024MAK » Mon Jul 23, 2018 5:50 am
The first year that I got my hands on a Speccy, when I had got my head around the normal BASIC commands and functions, I started playing with POKE and USR. I tried many combinations in the search for useful or interesting effects. But I did not keep much in the way of notes. And what I did keep, were typed up on said ZX Spectrum and printed on thermal paper. Paper that has not aged well...
Mark
0 x
-
dfzx
- Microbot
- Posts: 170
- Joined: Mon Nov 13, 2017 6:55 pm
- Location: New Forest, UK
-
Contact:
Post
by dfzx » Mon Jul 23, 2018 7:37 am
1024MAK wrote: ↑Mon Jul 23, 2018 5:50 am
The first year that I got my hands on a Speccy, when I had got my head around the normal BASIC commands and functions, I started playing with POKE and USR. I tried many combinations in the search for useful or interesting effects.
I used to do the same thing. I still have "RANDOMISE USR 2272" committed to memory after all these years. But it doesn't end in a reset so it's not what the OP wants.

0 x
-
djnzx48
- Manic Miner
- Posts: 564
- Joined: Wed Dec 06, 2017 2:13 am
- Location: New Zealand
Post
by djnzx48 » Mon Jul 23, 2018 8:12 am
You might get some interesting effects by messing around with the I and R registers, for example setting I to point to contended memory.
I think Tomahawk also has some screen corruption effects for when you crash.
0 x
-
PROSM
- Dizzy
- Posts: 98
- Joined: Fri Nov 17, 2017 7:18 pm
- Location: Sunderland, England
-
Contact:
Post
by PROSM » Mon Jul 23, 2018 8:33 am
djnzx48 wrote: ↑Mon Jul 23, 2018 8:12 am
You might get some interesting effects by messing around with the I and R registers, for example setting I to point to contended memory.
The problem is that altering the I register would only crash the 128K machines IIRC, whereas the 16K/48K models continue to work (albeit with the screen snow still).
Changing R would probably only cause real Spectrums to crash, I don't know of any emulator that simulates DRAM leakage.

0 x
-
Ast A. Moore
- Dynamite Dan
- Posts: 1222
- Joined: Mon Nov 13, 2017 3:16 pm
Post
by Ast A. Moore » Mon Jul 23, 2018 9:20 am
PROSM wrote: ↑Mon Jul 23, 2018 8:33 am
The problem is that altering the I register would only crash the 128K machines IIRC, whereas the 16K/48K models continue to work (albeit with the screen snow still).
I did extensive testing some time ago to verify this hypothesis (I documented in on WoS), and I was
unable to crash the 128K Speccy no matter how hard I tried. So there’s little substance to this notion.
That is not to say you can’t crash any Spectrum “the regular” way by messing with the interrupt vector register. Quite the opposite.

1 x
-
spider
- Microbot
- Posts: 112
- Joined: Wed May 01, 2019 9:59 am
- Location: UK
-
Contact:
Post
by spider » Thu Aug 29, 2019 9:41 pm
Maybe:
Code: Select all
ORG 26000
XOR (HL)
LD DE,16384
LD BC,6912
LDIR
CALL 1335
JP 26000
Change the JP 26000 to JP 0 to reset obviously! I left it at self as it then generates some slightly different patterns, just break/space a few times:
I did try a few other variations on this such as DI and/or doing something like LD A,R as well as playing with the Call address a bit, without a great deal of other effects really. I thought about more detailed border effects but it seemed a bit o.t.t.

0 x