Added the encoder