xmega: Working encoder input