Update: that might need to be $scp->slave_pty->stty('-echo') and $scp->slave_pty->stty('echo'). or you might need to use one of the $obj->log_* or Expect::Log_* function/variables to tweak what gets displayed where and when.