Topic: Dubstep generator

Just came across this on YT smile

https://youtu.be/S2huhsg6BcI

Re: Dubstep generator

Sounds surprisingly nice for being so simple.

start
  ld b,1
  ld hl,#4000
loop
  ld a,(hl)
  add a,b
  ld b,a
  ld (hl),a
  out (#fe),a
  inc hl
  ld a,h
  cp #58
  jp nz,loop
  jp start

Could've easily shaved at least 3 bytes off, though yikes

I still would like to see a bytebeat interpreter for beeper one day. Or rather, bitbeat... I don't see how it could be done though, considering the thing needs to run in constant time.

Re: Dubstep generator

like this one?
http://www.pouet.net/prod.php?which=87664

Re: Dubstep generator

Ah, yes, Serzhsoft delivers, as usual. Thanks for reminding me about that one, I forgot to check that out when it was released!

5 (edited by cborn 2021-01-08 16:41:31)

Re: Dubstep generator

SherzhSoft s version is close to it
and can be shorter as well ??

;http://www.pouet.net/prod.php?which=87664
;digital opera in 22-2 bytes
;Serzhsoft, 2 bytes removed by cborn

start:
ad00      di
ad01      ld e,c       ; c from basic call = start adres
ad02      ld hl,0x5800

ad05      ld b,h
ad06      ld a,(bc)
ad07      ld e,a
ad08      add a,e
ad09      inc bc
ad0a      dec hl
ad0b      cpl
ad0c      out (0xfe),a
ad0e      sub (hl)
ad0f      ld (hl),a
ad10      cp (hl)
ad11      jr z,ad05

ad13      inc e           ; 'e' will be overwritten and this 'inc' can be removed, OR the loop has to be re-rwritten so it will be increased..... a puzzle!!
ad14      jr ad02


oops sudden rewrite?
in lower memory its funky!!

;http://www.pouet.net/prod.php?which=87664
;digital opera in 22 bytes
;Serzhsoft

start:
ad00      di
ad01      ld e,c       ; c from basic call = start adres
ad02      ld hl,0x5800

ad05      ld b,h
ad06      ld a,(bc)

ad08      add a,a
ad09      inc bc
ad0a      dec hl
ad0b      cpl
ad0c      out (0xfe),a
ad0e      sub (hl)
ad0f      ld (hl),a
ad10      cp (hl)
ad11      jr z,ad05
ad14      jr ad02

6 (edited by Shiru 2021-01-09 17:43:08)

Re: Dubstep generator

Great stuff!

As I understand, the amount of bits involved into an LFSR directly affects to the length of evolutions of the sound in time, while bits change density per second (like, how fast LFSR is counting) affects to the richness of the harmonic content. So here we have 6144*8 bits large LFSR, even though these bits may be used not the most efficient way. Overall it is just like a regular LFSR-based noise generator like in all old sound chips, but with tricky looped sub-periods (noise harmonics?) in it.

website - 1bit music - other music - youtube - bandcamp - patreon - twitter (latest news there)

Re: Dubstep generator

I've been wondering for some time if there is a way of replacing the usual 16-bit frequency counters with an LFSR or something of that sort. Feels like such a waste to spend 4 registers on a simple counter every time.