roboticslab-uc3m / questions-and-answers

A place for general debate and question&answer
https://robots.uc3m.es/developer-manual/appendix/repository-index.html
2 stars 0 forks source link

How to resolve strange characters in yarp #27

Closed rsantos88 closed 7 years ago

rsantos88 commented 7 years ago

I don't remember how to solve this annoying problem when I connect with a yarp rpc port and I press the direction keys:

yarp rpc /tts/rpc:s
^[[C^[[C^[[C^[[B^[[A
David-Estevez commented 7 years ago

Those strange characters are how the terminal represents the arrow keys (and other key combinations such as cntrl+key). They typically appear when the application you are using doesn't support using the arrows to navigate the history (or that combination of keys).

To summarize: yarp ports don't support command history navigation through arrows (as far as I remember, I might be wrong).

rsantos88 commented 7 years ago

Yes, I remember that @jgvictores knew some linux packet that when you install it allow command history navigation in yarp ports...

PeterBowman commented 7 years ago

It actually worked for me on some system, at some point (maybe Windows? can't remember). After opening a RPC connection via terminal, I saw a >>> prompt starting on each line, then it was possible to browse the command history with arrow-up/-down and traverse left-right on the current line.

jgvictores commented 7 years ago

Sounds like some readline magic. I recall some READLINE directives in yarp cmake.

rsantos88 commented 7 years ago

OK!! I solved it!! try to install libedit-dev packet to allow for commands auto-completion and recompile YARP. It works!! :smile:

David-Estevez commented 7 years ago

Great!! :clap: :clap: :clap: :clap:

Maybe we should put this info in the installation-guides...

PeterBowman commented 7 years ago

Maybe we should put this info in the installation-guides...

Done at roboticslab-uc3m/installation-guides@c17a122, closing as resolved and kudos to @rsantos88!