anchor.diff:      (sei)                               ; Init CPU
       (cld)
       (poke 0 +ppu-cr1+)
  -    ;;(ldx (imm #xFF))
  -    ;;(txs)
  -    ;;(as/until :negative (bita (mem +ppu-status+))) ; PPU warmup
  -    ;;(as/until :negative (bita (mem +ppu-status+)))
       ;; Init sound hardware..
       (poke 0 #x4015)                     ; Silence all channels.
       (poke #x40 #x4017)                  ; IRQ off, 4-step.
  
positive.code: 
      (poke #b10000000 +ppu-cr1+)         ; Enable NMI
  
      ;; Init song playback:
      (pokeword (label 'music-start) mptr)
      (rts))
  
    ;; (procedure brk-handler (rti))
  
    ;; (procedure nmi-handler
    ;;   (inc vblank-flag)
    ;;   (rti))
  
    ;; (procedure wait
    ;;   (as/until :not-zero (lda vblank-flag))
    ;;   (poke 0 vblank-flag)
    ;;   (rts))
  
    ;; (advance-to +nmi-vector+)
    ;; (dw (label 'nmi-handler))
    ;; (dw (label 'reset))
    ;; (dw (label 'brk-handler))
  
    ;; Write .NES file
    ;;(write-ines "/tmp/music.nes" (link *context*))
  
    ;; Write .NSF file
    (setf (binary-file "/tmp/dollhouse.nsf") (link *context*)))
  
negative.code: 
      (align 256)
      (with-label music-start
        (unless (= (length music-sequence) (* 128 (expt 2 log2-song-length)))
          (error "Song length is ~:D, should be ~:D"
                 (length music-sequence)
                 (* 128 (expt 2 log2-song-length))))
        (print (list :num-unique  (length (remove-duplicates music-sequence))))
        (mapcar #'dw (reverse music-sequence))))
  
  