PSG Registers R11 - R13
0000:0000:00ee:vvvv where: ee selects the envelope magnitude 00 No envelope selected. PSG uses the flat volume in 'vvvv' instead. 01 Use envelope volume shifted right by 2 10 Use envelope volume shifted right by 1 11 Use envelope volume as-is vvvv indicates the flat volume to use if no envelope selected (ee is 00).
Some variants of the AY-3-891x family do not implement both envelope select bits. Those devices only allow selecting the unmodified envelope or a flat volume. On those devices, bit 5 always reads as zero (0). To ensure compatibility across both variants of the PSG, programs should always write ones (1) to both 'e' bits, and also should not rely on a one (1) written to bit 5 reading back as one (1) or zero (0). (Writing zero (0) to bit 5 and subsequently reading it always gives zero (0).)