Pulse

The square wave channel of an old sound chip. The wave stays high for a fixed part of each period, one of four duty cycles, and each note starts at one of sixteen volumes that an envelope moves one step at a time.

Import

import { Pulse } from '@halleyfante/chiptune';

A square wave that fades out

Constructor

new Pulse({  })

Methods

MethodDescription
play(options: ChannelPlayOptions<PulseSettings>): voidEvery duty cycle keeps the same peak to peak amplitude, as on the hardware, instead of being normalized to the same peak.