Changes

Jump to: navigation, search

PSG

195 bytes added, 14 September
/* Block Diagram */
Much like the [[CRTC]] chip, the PSG consists of a few simple functional blocks consisting of counters, equality comparators and some fairly simple logic.
Careful studies of the chip output prove that the chip '''counts up''' from 0 until the counter becomes '''greater or equal ''' to the period, at which point the output flips and the counter resets to 0. (This means that shortening the period can cause an immediate flip if the phase counter is already past the new period value. ) This is an important difference when the program is rapidly changing the period to modulate the sound. This is worthwhile noting, since the datasheets say that the chip counts down.
Also, note that period = 0 is the same as period = 1. This is mentioned in the YM2203 datasheet. However, this does NOT apply to the Envelope period. In that case, period = 0 is half as period = 1. [https://github.com/mamedev/mame/blob/master/src/devices/sound/ay8910.cpp Source]
8,990
edits