in reply to Control:CLI or Net::SSH2 - Send <ctrl>_

Hi Monks, thanks for the assistance thus far. I made both changes listed above (put instead of print, add sleep 2) and unfortunately neither worked. Here's the new HEX output (relevant part)...

< 0x00000: 0a 0d 0a 50 72 65 73 73 20 5b 45 6e 74 65 72 5d ...Pres +s [Enter] < 0x00010: 20 74 6f 20 64 69 73 70 6c 61 79 20 74 68 65 20 to dis +play the < 0x00020: 73 77 69 74 63 68 20 63 6f 6e 73 6f 6c 65 3a 20 switch +console: > 0x00000: 1f . > 0x00000: 44

Replies are listed 'Best First'.
Re^2: Control:CLI or Net::SSH2 - Send <ctrl>_
by soonix (Chancellor) on Feb 21, 2017 at 14:58 UTC
    What should happen? IOW: what happens, if you connect using a ssh client and manually type these characters in?
Re^2: Control:CLI or Net::SSH2 - Send <ctrl>_
by huck (Prior) on Feb 21, 2017 at 16:13 UTC

    Ok, one more limb, this is but a mere hailmary guess.

    what if you first have to be in the console before even escape works?

    so in the original test code replace

    my $switchexit = $obj->print("\037"); # <== PROBLEM
    with
    $output = $obj->put("\x0a"); Sleep 1; # give it time to start the console; $output = $obj->put("\x1f"); Sleep 1; # give it time to for a "time guard interval" ;
    Sorry about going back to hex, i dont think as well in octal.