![]() |
Routines |
Prev: 62720 | Up: Map | Next: 63048 |
Used by the routines at SoundHandler_BombFuse and SoundHandler_BombSparks.
|
||||
SoundGenerator_WhiteNoise | 63000 | PUSH BC | Stash BC and BC on the stack. | |
63001 | PUSH BC | |||
63002 | CALL WhiteNoiseGenerator | Call WhiteNoiseGenerator. | ||
63005 | LD BC,65534 | Send *Active_BorderColour to the speaker port. | ||
63008 | LD A,(23504) | |||
63011 | OUT (C),A | |||
63013 | POP BC | Restore BC from the stack. | ||
63014 | CALL WhiteNoiseGenerator | Call WhiteNoiseGenerator. | ||
63017 | LD BC,65534 | BC=65534 (C points to the speaker port). | ||
63020 | LD A,(23504) | A=*Active_BorderColour. | ||
63023 | OR %00010000 | Turn on the speaker (set bit 4). | ||
63025 | OUT (C),A | Send A to port *C. | ||
63027 | POP BC | Restore BC from the stack. | ||
63028 | DEC DE | Decrease DE by one. | ||
63029 | LD A,D | Jump to SoundGenerator_WhiteNoise until DE is zero. | ||
63030 | OR E | |||
63031 | JR NZ,SoundGenerator_WhiteNoise | |||
63033 | RET | Return. | ||
WhiteNoiseGenerator | 63034 | PUSH BC | Stash BC on the stack. | |
63035 | CALL BombTimer | Call BombTimer. | ||
63038 | AND B | Merge the bits from B. | ||
63039 | LD B,A | B=A. | ||
63040 | CP 0 | Jump to WhiteNoiseHouseKeeping if A is zero. | ||
63042 | JR Z,WhiteNoiseHouseKeeping | |||
WhiteNoiseDelay | 63044 | DJNZ WhiteNoiseDelay | Decrease counter by one and loop back to WhiteNoiseDelay until counter is zero. | |
WhiteNoiseHouseKeeping | 63046 | POP BC | Restore BC from the stack. | |
63047 | RET | Return. |
Prev: 62720 | Up: Map | Next: 63048 |