A communication receiver amplifies a pulse-amplitude-modulated (PAM)
signal representing an integer-valued sequence of first data elements
(D1) with an adjustable first gain (G1) and digitizes the amplified
signal to produce a sequence of second data elements (D2) representing
successive magnitudes of the PAM signal. A first automatic gain control
(AGC) circuit determines the rate at which magnitudes of the second data
sequence elements fall within a first range and adjusts G1 to maintain
that rate within a second range. Digital signal processing circuits
within the receiver process the second data to produce a sequence of
third data elements (D3), each having a real number value substantially
equal to a product of a second gain G2 and a corresponding one of the
first data elements D1. A slicer rounds the real number represented by
each third data sequence element to produce a corresponding
integer-valued element of a fourth data sequence (D4). A second AGC
circuit adjusts the second gain based on a combination of a sign of each
fourth sequence element and a sign of a difference between corresponding
third and fourth data sequence elements to keep each third data element
as close as possible in value to its corresponding first data element.