• I guess one way is to assign the console to Loopback:

    USB.onData(function (d) { LoopbackB.write(d); });
    LoopbackB.onData(function (d) { USB.write(d); });
    LoopbackA.setConsole();
    

    But things like Ctrl-C to break won't work then.

    Can anyone think of a reason why setConsole shouldn't just override the automatic changeover? (the changeover happens if USB connects and you're on Serial1, or if USB disconnects while you're on USB)

    Perhaps Device.setConsole(true) could force the console to stay in place, and Device.setConsole() would have the existing behaviour.

About

Avatar for Gordon @Gordon started