For my project I needed to create a custom terminal-like window and connect to a Cisco router through console port. So I inherited a TextBox and created a custom control in WPF. And I thought it would be enough; just to add some code to implement extra features I wanted. I'm sending one character at a time and wait for responses. But then I saw that my custom terminal does not handle special characters, those basic like \n sure are recognized but all the others not. I have written responses to a text file and I see i got quite a lot of those special ones but I don't know how should I react. Maybe someone knows or have found some links with info about how to react for a specific control character? I have only found what characters are send here , but nothing else about it. I understand that for a "BS" I will delete one character before carriage but what should I do when I get "ACK" or "DC1" ? Maybe I should just skip them ? Any ideas?
Edit: Apart from sending one character at a time I'll get response only when I send enter or characters like ? or TAB. Then when I receive a response it's mixed with special chars to format the text like in 80x25 terminal window. And I would like just to display it like it wants, but that means I need to know how to react when I get special chars I don't need to display them, just to format normal text based on the special ones I'm also receiving. When I get BS i need to clear the character before carriage, when I get DEL I need to clear the character after carriage. And I would like to know what I need to do when I'm getting other special chars. I know I can do it the hard way and just send those to a working terminal and see what it will do but it will take a while so I wonder if someone maybe knows the answer.