An adaptive sliding block Viterbi decoder includes forward and backward Viterbi processors, a state estimator and a control unit. A vertical tube is attached to the body near the closed end, and a pellet is located within the vertical tube. The y-direction stutter count provides the estimate of pixel stutter from pure statistical data variations. The information is also used to control downhole devices that may be a packer, choke, sliding sleeve, perforating device, flow control valve, completion device, an anchor or any other device.