World of Spectrum
  • Categories
  • Discussions
  • FAQ
  • Sign In
Home › Search
Title Search
@title beer Word 'beer' in title
User Search
  • @user admin Only posts by Admin
Text Search
  • @body beer Word 'beer' in the text
Phrase Search
"Hello World" Exact phrase match
Exclude Terms
  • car -red Search cars that are not red
"Or" Searches
  • honda | bmw 'honda' or 'bmw' results
Multi-Field
@(title,body) hello Both contain 'hello'
WildCard
  • hond* civ* Match all with an astrix
Combination
  • @title bmw @user admin
See more supported syntax examples
Search Again :: Adv Search 1000 results in 0.014s
<1234567…34>
  • Why doesn't my routine work?I have a "level" defined by 504 bytes (28 squares across x 18 squares down) I'm trying to write a routine that will take an X,Y coordinate in pixels…

    ... HL

    add hl, hl
    add hl, hl ;x4 original value
    ld de, hl ...
    sekrets sekrets December 2010 Development
  • How the spectrum generates the video from ramHi everyon, I know that most people here allready know this but i think i found out how the spectrum acctually dispalys stuff and why the LD x, (HL)…

    ... dispalys stuff and why the LD x, (HL) is used to display ... using the instruction LD x, (HL), you look at address HL (which would ...
    Robin Robin January 2011 Hardware
  • Help?Hi All, I wonder if anyone has a few minutes to look at this bit of code I'm working on. I'm trying to move to sprites and want to do it with a scr…

    ... +0) ;low byte
    ld (hl),a ;a, the screen address ... ;repeat 8 times
    ld hl,bits ;reset bits (lines of ... next from top
    ld (point),hl
    ld hl,seed ;screen address table ... /> halt
    ret
    sprite ld hl,(point) ;address of current line ...
    R-Tape R-Tape January 2011 Development
  • Small Machine Code Routines Which Maybe UsefulAs part of creating Flynn's Adventure in Bombland I created a lot of little routines to do all sorts of things. A lot of these I created based on inp…

    ... /> ld l,a ; 4t - hl=char to plot
    add hl,hl ; ... add hl,hl ; 11t - x4
    add hl,hl ; 11t - x8
    ld bc ... previous plot byte
    ld (hl),a ; 7t - plot ... 4t - down one
    ld (hl),a ; 7t - plot line ... previous plot byte
    ld (hl),a ; 7t - plot ...
    TomD TomD April 2011 Development
  • quick - Zx80 ASM questionWhile I am ploughing through lots of ASM listings, one of my earlier adaptation attempts surprised me [B][asm code][/B] [code] org 32768 start: ld…

    ... ROM

    [B]ld hl,text1 ; set HL with text1 data
    ld hl,text2 ; set HL with text2 data
    ld a,(hl) ; get character to print ...
    Zetr0 Zetr0 May 2011 Development
  • Frank N SteinThis is an improved bugfix for [URL="http://www.worldofspectrum.org/infoseekid.cgi?id=0001849"]Frank N Stein[/URL] as discussed recently in [URL="htt…

    ... : equ $5C3D ; 23613
    PATCH2: LD HL, (ERR_SP) ; 42 61 92
    DEC HL ; 43
    DEC HL ; 43
    LD SP, HL ; 249
    Einar Saukas Einar Saukas May 2011 Infoseek database
  • Back to BASIC[U][B]Archaeology guide to programs compiled used MCODERII.d[/B][/U] After various people have been talking about "Frank'n'stein" I decided to finis…

    ...
    +1 LD HL,0
    +4 LD (59346),HL
    +7 LD HL,LINES
    +10 LD A,NVARS
    +12 LD ...
    Jimmy Jimmy May 2011 Development
  • Shadow ROM partial decoding not implemented in emulatorsOr at least, not implemented in Spectaculator, and it seems that not in Fuse too. [URL="http://www.speccy.org/foro/viewtopic.php?f=8&t=408&start=53"…

    ... di
    ld hl,StartCopy
    ld (5cedh),hl
    rst ... StartCopy ld hl,0
    ld de,32768
    ld bc,16384 ...
    mcleod_ideafix mcleod_ideafix June 2011 Emulators
  • (part of) screen to UDGHere is a routine to copy a Y,X-position on screen to a UDG. 0<=y<=23 0<=x<=31 144<=udg<=165 (UDG "A" to UDG "U") [code] ; start code with ; PRINT …

    Here is a routine to copy a Y,X-position on screen to a UDG.
    0
    Dr BEEP Dr BEEP June 2011 Development
  • Nemesis the Warlock (BUGFIX)This is a bugfix for game [URL="http://www.worldofspectrum.org/infoseekid.cgi?id=0003387"]Nemesis the Warlock[/URL], please add the following "known …

    ... :
    [CODE]
    77ff: ld a,($caf3) ; exit: 0=horizontal ... jp z,$7825
    7806: ld hl,($ca56) ; oops! may reach " ... when moving up
    7809: ld ($caf4),hl
    780c: jp $7825 ... 194
    7806: ld hl,($ca56)
    7809: ld ($caf4),hl
    780c: jp ...
    Einar Saukas Einar Saukas June 2011 Infoseek database
  • Thanos (improved BUGFIX)This is an improved BUGFIX for game [URL="http://www.worldofspectrum.org/infoseekid.cgi?id=0005221"]Thanos[/URL], please replace the "known errors" d…

    ... :
    658c 216b65 ld hl,$656b
    658f 7e ld a,(hl)
    6590 ...
    65a3 218400 ld hl,$0084
    65a6 226e65 ld ($656e),hl
    65a9 ...
    65f7 211800 ld hl,$0018
    65fa 226e65 ld ($656e),hl
    65fd ...
    Einar Saukas Einar Saukas June 2011 Infoseek database
  • automatic relocating of non-relocatable codeI was pondering upon the problem of changing absolute addresses used by CALL, JP, etc. when code is moved, without reassembling at the new location; …

    ... pointer
    ld hl,CHANGE
    add hl,bc
    ld sp,hl ;point SP ...
    ld (hl),e ;DE=new value
    inc hl
    ld (hl),d
    Battle Bunny Battle Bunny August 2011 Development
  • Kiwi OS for z80 computerHi everyone, Nearly made my z80 computer with 2K ROM 32K RAM. It has an OS im still writing called Kiwi (apple, blackberry, you get the idea ;D) he…

    ... LD HL, 32800 ;LOAD HL WITH STACK POINT LOCATION
    LD SP, HL ... br />
    LD HL, 33000 ;LOAD HL WITH STARTING ADDRESS
    HL ;REMEMBER HL
    LD HL, 1527 ;LOAD HL WITH ...
    Robin Robin August 2011 Announcements
  • Keys redefine routine and key check.I have written some asm code which allows me to redefine keys (for a game etc.), and also allows me to be able to check any keypresses for the redefi…

    ... print_message
    ld hl,key_left_port
    call get_defined_key

    ld hl,msg_right
    ld hl,key_right_port
    call get_defined_key

    ld hl,msg_fire
    polomint polomint September 2011 Development
  • Tile based graphics and scrolling thingy...Here's my best attempt so far at a tile based rendering and scrolling routine. It draws in 22 8*8 graphics tiles along the top of the screen (junk i…

    ... ld hl,tile_base ; tile_base

    ld (next_tile_line),hl

    start ld b ... hl,hl ; ASCII code * 8
    add hl,hl
    add hl,hl

    ld ... />
    ld hl,16385
    ld (position_var),hl ; Reset print ...
    Zoltar Zoltar September 2011 Development
  • AND,XOR,OR,BIT,RES,SET,CPL,NEG,RLC,RRC,SLA,SRL,RL, RR,SRA for BASICAs this was drifting away from the original INKEY$ thread I thought that I'd create a new one. So here's a routine to provide all of the above mentio…

    ... /> LOGIC: ld hl,12
    add hl,sp
    ld sp,hl ;undo USR ... ld hl,OPCODES
    add hl,bc
    add hl,bc
    ld ... bc
    ld hl,OPERATE+1
    ld a,(hl)
    jr ...
    Battle Bunny Battle Bunny October 2011 Sinclair Basic
  • probably a stupid question about RST16I'm using the 'hello world' code borrowed from [url=http://equant-retrochallenge.blogspot.com/2008/07/zx-spectrum-assembly-programming-under.html]her…

    ... />
    [code]
    ld hl,line ; Print line
    call ... out a line
    ld a,(hl) ; Get character to ... in 'A'
    inc hl ; Move onto the next ...
    you can load HL and call it again immediately ...
    sack sack October 2011 Development
  • tiny routine to shift RAMTOP & stackCompressing some data areas above RAMTOP and wanting to make the released space available for BASIC arrays, I needed to move RAMTOP without using CLE…

    ... /> LD HL, 18 ; 33 18 0
    ADD HL, SP ; 57
    LD SP, HL ...
    Battle Bunny Battle Bunny November 2011 Sinclair Basic
  • BREAK from GOSUBHere's another one. Just in case you wanted to break out of multiple GOSUB levels with a single command, here's a routine to do it, tested on all mod…

    ... br /> [code]
    RETSUB: LD HL, 20 ; 33 20 0 ;Discard ... & (ERR_SP)
    LD SP, HL ; 249 ;from m/c ... )
    EX DE, HL ; 235
    LD (23613), SP ; 237 ...
    Battle Bunny Battle Bunny December 2011 Sinclair Basic
  • Procrustean PrintingHere's a short routine to manage printing of text with command tokens, to avoid messing up the screen when they are expanded. It just prints as many …

    ... ;
    STACK: ld hl,14
    add hl,sp
    ld sp,hl ;undo USR ... ,hl ;HL=string pointer
    ld b,a ;B =max_length
    SSNEXT1:ld a,(hl ...
    Battle Bunny Battle Bunny December 2011 Sinclair Basic
  • Invalid combination of operands and opcodesIt says the error in the title, why is this?? [CODE] ORG 0000 LD HL, 63000 ;LOAD HL WITH STACK LOCATION LD SP, HL ;SET STACK POINTER TO HL LD A, …

    ... br /> LD HL, 63000 ;LOAD HL WITH STACK LOCATION
    LD SP, HL ;SET ... STACK POINTER TO HL
    LD ... DISPLAY
    LD HL, 0000 ;LOAD HL WITH THE STARTING ... DISPLAY
    LD HL, 0000 ;LOAD HL WITH Z80 POWERED ...
    Robin Robin December 2011 Sinclair Miscellaneous
  • Indirect Variable AssignmentHere's another wacky routine. This allows assignment of values to variables where the source & destination variables can themselves be defined in var…

    Here's another wacky routine. This allows assignment of values to variables where the source & destination variables can themselves be defined in variables (or expressions which evaluate to variables). Some of this can already be done with VAL or VAL$, ...
    Battle Bunny Battle Bunny January 2012 Sinclair Basic
  • Amazonia (BUGFIX)This is a bugfix for game [URL="http://www.worldofspectrum.org/infoseekid.cgi?id=0027280"]Amazonia[/URL], please add the following "known errors" des…

    ... /> 9ec1 210000 ld hl,0000h
    9ec4 22c89b ld (9bc8h),hl ; reset time ... ret
    9ee0 3600 ld (hl),00h ; reset minutes/hours/ ... already zero)
    9ec5 21e99b ld hl,9be9h ; clock address
    ...
    Einar Saukas Einar Saukas January 2012 Infoseek database
  • Loading the display with data from memoryTrying to load part of the screen(4k's worth) with data from memory location 53000, I've written this routine, but it doesnt work... [I]ld b,4000 ld…

    ... ]ld b,4000
    ld de, 16384
    ld hl, 55000
    loop ld a,(hl ... )
    ld (de ... ),a
    inc de
    inc hl
    daveysludge daveysludge January 2012 Development
  • S-S-Sample black borderI'm wanting the 'S-S-Sample' routine from YS to play the sounds without the flashing border effects. A plain black border is required. Heres the rou…

    ... /> ld hl, (32768 )
    ld de, (32770)
    ld bc, 2048
    ld c, (hl)
    ld ... a, c
    rlca
    ld ...
    daveysludge daveysludge January 2012 Development
  • editing strings with INPUT LINEHere's the latest in my unpredictable series of utility routines. This one I needed for the SAGE game editor; it emulates INPUT LINE l$ but with the …

    ... />
    inc hl
    ld c,(hl)
    inc hl
    ld b,(hl) ;BC=l ... de,hl
    ld (hl),$0d ;followed by ENTER
    ld (K_CUR),hl
    ld de ...
    Battle Bunny Battle Bunny February 2012 Sinclair Basic
  • Routine for clearing screenI was looking for a 'nice' way of clearing a screen of graphics in Z80. After a ridiculous amount of time mucking around, this is the best and most …

    ...
    ld hl,16384
    ld bc,6144
    ld de,(PRT_CHR ... ld a,(hl)
    and e
    ld (hl),a
    inc hl ...
    dec bc
    ld a ... ,SCREEN_CLEAR_LOOP

    ld a,(PRT_CHR)
    sla a ... ret nc

    ld (PRT_CHR),a
    jr ...
    Morkin Morkin March 2012 Development
  • 28-character wide multicolour(ish) on 48k SpectrumLong-time lurker here... I've always been interested in rainbow effects on the 48k Spectrum, mainly from a perspective of "Just what [I]would [/I]ha…

    ... /> LD H,A
    LD A,24
    LD (DEPTH),A
    LD (HIATT),HL ... ; Some more attribute data
    ld hl,5566H ; Some more attribute data ... /> LD L,C
    LD D,A
    LD E,B
    LD (HL),0FDH ...
    AMW AMW April 2012 Development
  • Byte-order backbufferThis is a tool for Z80 coders who wish the Spectrum screen had a serial layout. It runs as an interrupt mode 2 service routine and uses POP and PUSH …

    ... byte of the screen
    ld hl, $ + 9 ; set return location (no ... stack available)
    ld (endcall), hl
    jp blit ; call ... ) - (chunk * 2048)
    ld hl, $ + 9
    ld (endcall), hl
    jp blit
    chev chev April 2012 Development
<1234567…34>

Latest Posts

  • Your Favorite Magazine Cover Tapes.
    Your Spec-chum on 2:19PM
  • Where to Buy the New or Fairly Recent , Excellent ZX Spectrum Games Software?
    Your Spec-chum on 1:34PM
  • i am currently listening to........
    mel the bell on 11:34AM
  • Mis-labeled cassette titles or a name change?
    harriusherbartio on 11:06AM
  • Ways to preserve Speccy Tapes in the loft
    harriusherbartio on 10:58AM
  • Fixed Speccy Software. And which games remained unfixed?
    harriusherbartio on 10:47AM
  • Minor British Sports that did become games on the ZX Spectrum
    harriusherbartio on 10:30AM
  • How to return to basic properly from ASM
    Paradigm Shifter on 1:54AM
  • Frankie's ZX Spectrum Digouts
    Zup on April 8
  • Elusive Strategy Games done by the Smaller or less Prolific Software Houses.
    harriusherbartio on April 8

HitBox

Word Docs Hits
ld 6.3K 67.3K
23641 33 47
hl 6.2K 48K

Related Threads

  • DEC BC/LD A,B/OR C/JP NZ,loopyesterday i saw nice trick:[code]<br /> <br /> dec bc<br /> ld a, b<br /> or c<br /> jp nz, loop<br /> <br /> can be replaced (bc starts &gt;255, sho…
  • When would you use LD A,R ?Can anyone tell me a practical use of LD A,R and LD R,A I am confused when you would need to use it?<br /> <br /> Cheers
  • Correct flag response to BIT n,(HL) etc.When running the test program suggested by Arjun (thanks again), all intructions are passing the flag tests except the BIT n,(HL), BIT n,(IX+dis) and…
  • Contention: LDI vs LD (ss), rAccording c.s.s. FAQ:<br /> <br /> instruction LD (ss),r breakdowns as pc:4,[b]ss:3[/b]<br /> and LDI as pc:4,pc+1:4,hl:3,[b]de:3,de:1 x 2[/b]<br /> …
  • rotating HL left through CarryI've tried this several ways, and it works for a while, then a particular value has a bit set in an inconvenient place and it all goes to pot.<br /> …
  • Restore HL' to?It is probably a simple question, but it's been escaping me for quite some time now.<br /> <br /> Is there an 'universal' value you should restore HL…
  • Getting PC into HLHello, here's a conundrum for you...<br /> <br /> Is there a way to obtain the value of the PC register (say into HL) without using absolute addressi…
  • Z80: ABS(HL) functionI must be very tired but I cannot get my head around whether this function provides a correct implementation of a ABS function for a signed 16-bit va…
  • JP (HL) confusionokay.... JP nn will jump to memory address nn.<br /> JP (HL) ,I assumed would read the contents of memory address HL and jump to the location<br /> …

Related Searches

  • ld ix
  • ld bytes
  • ld hl de
  • return to basic hl
  • ld bc eostr string
  • ld am
  • ld a r
  • ld r a
  • call hl
  • ld a b xor c loop
  • ld a b or c loop
  • ld i a
  • ld a 3fh
  • ld a 0 call 5633
  • ld fe 00
  • slt format hl
  • ld bc hl
  • ld hl 5678
  • 33 ld hl xxxx
  • screen buffer pop bc ld sp hl

Copyright © 2024 World of Spectrum