fix bug that there is no output in encoder console
Merge pull request #534 from ruil2/encoder_ret

    fix bug that there is no output in encoder console