Re: [ptxdist] Backspace not working in terminal (using ssh)
On 21/03/2019 13:33, Michael Olbrich wrote: On Thu, Mar 21, 2019 at 12:46:40PM +, Ian Abbott wrote: On 20/03/2019 15:41, Michael Olbrich wrote: On Wed, Mar 20, 2019 at 12:41:47PM +, Ian Abbott wrote: On 20/03/2019 09:15, Dold, Wolfram wrote: On Tue, 2019-03-19 at 17:42 +, Ian Abbott wrote: On 19/03/2019 12:33, Dold, Wolfram wrote: Hi Ian, On Tue, 2019-03-19 at 12:06 +, Ian Abbott wrote: On 19/03/2019 09:17, Dold, Wolfram wrote: Hi there, when we connect via ssh to our embedded device, the backspace key does not work. During the analysis we found out that the passage # This fixes the backspace when telnetting in. if [ "$TERM" != "linux" ]; then stty erase ^H fi from the file '/etc/profile' contained in ptxdist. Now I want to ask, how best to fix this behavior? Can the passage simply be omitted? (At least the comment lets me assume that, because there 'telnet' is mentioned and that is no longer necessarily state of the art). Or does omitting it lead to other unwanted side effects? Any help would be appreciated. [snip because it's getting a bit long] I've no idea why that bit of the /etc/profile file is there, but I guess it must have suited one of the PTXdist developers at the time. A "git blame" only revealed that the whole file was added in 2006, so I don't know how relevant that part of it is today. This code was moved around some more. It was actually introduced in the initial import from CVS in 2003 :-). Telnet works just fine without this, so I guess this is no longer needed. Perhaps it was there for the Windows Telnet client which seems to send ASCII BS when the "Backspace" key is pressed and ASCII DEL when the (less conveniently placed) "Delete" key is pressed. This mimics the codes sent by the VT-102 "Backspace" and "Delete" keys which were both conveniently placed. The Windows telnet client has a -t option to set the terminal type to one of "vt100", "vt52", "ansi", or "vtnt", but it doesn't pass the selected terminal type to the server, and this doesn't seem to have any effect on the codes sent by the "Backspace" and "Delete" keys. The TERM environment variable ends up getting set to "vt102" by default on my PTXdist systems if a terminal type hasn't been passed through by the Telnet client. I don't know if that is configurable. The Windows Telnet client isn't installed by default, but can still be installed as a "Windows Feature". I guess most people who used it would have switched to something like PuTTY by now. I'm pretty sure it was a Linux issue. I remember having problems like this a long time ago. I'll be happy to apply a patch that removes this. I'm worried that doing so might annoy some people who expect the existing behavior. I'd rather fix a real problem. If it causes issues, then we'll try to find a solution. Changing it would probably annoy gtkterm users, and annoy minicom users less so. For both of those, the Backspace key sends BS by default. There is an option to change it to DEL in minicom, but no such option in gtkterm (or if it exists, it is well hidden!). (Personally, I prefer minimalist, dumb serial terminal emulators such as picocom, nanocom, and microcom which just run inside a local terminal session.) -- -=( Ian Abbott || Web: www.mev.co.uk )=- -=( MEV Ltd. is a company registered in England & Wales. )=- -=( Registered number: 02862268. Registered address:)=- -=( 15 West Park Road, Bramhall, STOCKPORT, SK7 3JZ, UK. )=- ___ ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Backspace not working in terminal (using ssh)
On 21/03/2019 13:33, Michael Olbrich wrote: On Thu, Mar 21, 2019 at 12:46:40PM +, Ian Abbott wrote: On 20/03/2019 15:41, Michael Olbrich wrote: On Wed, Mar 20, 2019 at 12:41:47PM +, Ian Abbott wrote: On 20/03/2019 09:15, Dold, Wolfram wrote: On Tue, 2019-03-19 at 17:42 +, Ian Abbott wrote: On 19/03/2019 12:33, Dold, Wolfram wrote: Hi Ian, On Tue, 2019-03-19 at 12:06 +, Ian Abbott wrote: On 19/03/2019 09:17, Dold, Wolfram wrote: Hi there, when we connect via ssh to our embedded device, the backspace key does not work. During the analysis we found out that the passage # This fixes the backspace when telnetting in. if [ "$TERM" != "linux" ]; then stty erase ^H fi from the file '/etc/profile' contained in ptxdist. Now I want to ask, how best to fix this behavior? Can the passage simply be omitted? (At least the comment lets me assume that, because there 'telnet' is mentioned and that is no longer necessarily state of the art). Or does omitting it lead to other unwanted side effects? Any help would be appreciated. [snip because it's getting a bit long] I've no idea why that bit of the /etc/profile file is there, but I guess it must have suited one of the PTXdist developers at the time. A "git blame" only revealed that the whole file was added in 2006, so I don't know how relevant that part of it is today. This code was moved around some more. It was actually introduced in the initial import from CVS in 2003 :-). Telnet works just fine without this, so I guess this is no longer needed. Perhaps it was there for the Windows Telnet client which seems to send ASCII BS when the "Backspace" key is pressed and ASCII DEL when the (less conveniently placed) "Delete" key is pressed. This mimics the codes sent by the VT-102 "Backspace" and "Delete" keys which were both conveniently placed. The Windows telnet client has a -t option to set the terminal type to one of "vt100", "vt52", "ansi", or "vtnt", but it doesn't pass the selected terminal type to the server, and this doesn't seem to have any effect on the codes sent by the "Backspace" and "Delete" keys. The TERM environment variable ends up getting set to "vt102" by default on my PTXdist systems if a terminal type hasn't been passed through by the Telnet client. I don't know if that is configurable. The Windows Telnet client isn't installed by default, but can still be installed as a "Windows Feature". I guess most people who used it would have switched to something like PuTTY by now. I'm pretty sure it was a Linux issue. I remember having problems like this a long time ago. I guess it used to do `stty erase ^H` always and an exception was added later for terminal type "linux". The Linux vt console sends ASCII DEL for the Backspace key, and ASCII ESC [ 3 ~ for the Delete key, so that seems like it was a reasonably cautious change at the time. I'll be happy to apply a patch that removes this. I'm worried that doing so might annoy some people who expect the existing behavior. I'd rather fix a real problem. If it causes issues, then we'll try to find a solution. I suppose using the GNU coreutils default value for the stty erase character ( ^? (ASCII DEL) by default) is likely to cause the least problems overall. This also seems to be the default for FreeBSD (although FreeBSD stty also has an "erase2" option set to ^H (ASCII BS) by default). -- -=( Ian Abbott || Web: www.mev.co.uk )=- -=( MEV Ltd. is a company registered in England & Wales. )=- -=( Registered number: 02862268. Registered address:)=- -=( 15 West Park Road, Bramhall, STOCKPORT, SK7 3JZ, UK. )=- ___ ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Backspace not working in terminal (using ssh)
On Thu, Mar 21, 2019 at 12:46:40PM +, Ian Abbott wrote: > On 20/03/2019 15:41, Michael Olbrich wrote: > > On Wed, Mar 20, 2019 at 12:41:47PM +, Ian Abbott wrote: > > > On 20/03/2019 09:15, Dold, Wolfram wrote: > > > > On Tue, 2019-03-19 at 17:42 +, Ian Abbott wrote: > > > > > On 19/03/2019 12:33, Dold, Wolfram wrote: > > > > > > Hi Ian, > > > > > > On Tue, 2019-03-19 at 12:06 +, Ian Abbott wrote: > > > > > > > On 19/03/2019 09:17, Dold, Wolfram wrote: > > > > > > > > Hi there, > > > > > > > > when we connect via ssh to our embedded device, the backspace > > > > > > > > key does not work. > > > > > > > > During the analysis we found out that the passage > > > > > > > > > > > > > > > > # This fixes the backspace when telnetting in. > > > > > > > > if [ "$TERM" != "linux" ]; then > > > > > > > > stty erase ^H > > > > > > > > fi > > > > > > > > > > > > > > > > from the file '/etc/profile' contained in ptxdist. > > > > > > > > > > > > > > > > Now I want to ask, how best to fix this behavior? > > > > > > > > Can the passage simply be omitted? (At least the comment lets > > > > > > > > me assume that, because there 'telnet' is > > > > > > > > mentioned > > > > > > > > and > > > > > > > > that is no longer necessarily state of the art). > > > > > > > > Or does omitting it lead to other unwanted side effects? > > > > > > > > > > > > > > > > Any help would be appreciated. > [snip because it's getting a bit long] > > > > I've no idea why that bit of the /etc/profile file is there, but I guess > > > it > > > must have suited one of the PTXdist developers at the time. A "git blame" > > > only revealed that the whole file was added in 2006, so I don't know how > > > relevant that part of it is today. > > > > This code was moved around some more. It was actually introduced in the > > initial import from CVS in 2003 :-). Telnet works just fine without this, > > so I guess this is no longer needed. > > Perhaps it was there for the Windows Telnet client which seems to send ASCII > BS when the "Backspace" key is pressed and ASCII DEL when the (less > conveniently placed) "Delete" key is pressed. This mimics the codes sent by > the VT-102 "Backspace" and "Delete" keys which were both conveniently > placed. > > The Windows telnet client has a -t option to set the terminal type to one of > "vt100", "vt52", "ansi", or "vtnt", but it doesn't pass the selected > terminal type to the server, and this doesn't seem to have any effect on the > codes sent by the "Backspace" and "Delete" keys. The TERM environment > variable ends up getting set to "vt102" by default on my PTXdist systems if > a terminal type hasn't been passed through by the Telnet client. I don't > know if that is configurable. > > The Windows Telnet client isn't installed by default, but can still be > installed as a "Windows Feature". I guess most people who used it would > have switched to something like PuTTY by now. I'm pretty sure it was a Linux issue. I remember having problems like this a long time ago. > > I'll be happy to apply a patch that removes this. > > I'm worried that doing so might annoy some people who expect the existing > behavior. I'd rather fix a real problem. If it causes issues, then we'll try to find a solution. Michael -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | ___ ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Backspace not working in terminal (using ssh)
On 20/03/2019 15:41, Michael Olbrich wrote: On Wed, Mar 20, 2019 at 12:41:47PM +, Ian Abbott wrote: On 20/03/2019 09:15, Dold, Wolfram wrote: On Tue, 2019-03-19 at 17:42 +, Ian Abbott wrote: On 19/03/2019 12:33, Dold, Wolfram wrote: Hi Ian, On Tue, 2019-03-19 at 12:06 +, Ian Abbott wrote: On 19/03/2019 09:17, Dold, Wolfram wrote: Hi there, when we connect via ssh to our embedded device, the backspace key does not work. During the analysis we found out that the passage # This fixes the backspace when telnetting in. if [ "$TERM" != "linux" ]; then stty erase ^H fi from the file '/etc/profile' contained in ptxdist. Now I want to ask, how best to fix this behavior? Can the passage simply be omitted? (At least the comment lets me assume that, because there 'telnet' is mentioned and that is no longer necessarily state of the art). Or does omitting it lead to other unwanted side effects? Any help would be appreciated. [snip because it's getting a bit long] I've no idea why that bit of the /etc/profile file is there, but I guess it must have suited one of the PTXdist developers at the time. A "git blame" only revealed that the whole file was added in 2006, so I don't know how relevant that part of it is today. This code was moved around some more. It was actually introduced in the initial import from CVS in 2003 :-). Telnet works just fine without this, so I guess this is no longer needed. Perhaps it was there for the Windows Telnet client which seems to send ASCII BS when the "Backspace" key is pressed and ASCII DEL when the (less conveniently placed) "Delete" key is pressed. This mimics the codes sent by the VT-102 "Backspace" and "Delete" keys which were both conveniently placed. The Windows telnet client has a -t option to set the terminal type to one of "vt100", "vt52", "ansi", or "vtnt", but it doesn't pass the selected terminal type to the server, and this doesn't seem to have any effect on the codes sent by the "Backspace" and "Delete" keys. The TERM environment variable ends up getting set to "vt102" by default on my PTXdist systems if a terminal type hasn't been passed through by the Telnet client. I don't know if that is configurable. The Windows Telnet client isn't installed by default, but can still be installed as a "Windows Feature". I guess most people who used it would have switched to something like PuTTY by now. I'll be happy to apply a patch that removes this. I'm worried that doing so might annoy some people who expect the existing behavior. -- -=( Ian Abbott || Web: www.mev.co.uk )=- -=( MEV Ltd. is a company registered in England & Wales. )=- -=( Registered number: 02862268. Registered address:)=- -=( 15 West Park Road, Bramhall, STOCKPORT, SK7 3JZ, UK. )=- ___ ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Backspace not working in terminal (using ssh)
Hi, On Thu, Mar 21, 2019 at 10:45:57AM +, Dold, Wolfram wrote: > Yes, I know and I actually wanted to avoid that. > But maybe, when the ptxdist developers read this thread, > they take a closer look at that and maybe it was really See my other reply to this thread. Send Patches :-). Michael -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | ___ ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] Backspace not working in terminal (using ssh)
On Wed, 2019-03-20 at 12:41 +, Ian Abbott wrote: > On 20/03/2019 09:15, Dold, Wolfram wrote: > > On Tue, 2019-03-19 at 17:42 +, Ian Abbott wrote: > > > On 19/03/2019 12:33, Dold, Wolfram wrote: > > > > Hi Ian, > > > > On Tue, 2019-03-19 at 12:06 +, Ian Abbott wrote: > > > > > On 19/03/2019 09:17, Dold, Wolfram wrote: > > > > > > Hi there, > > > > > > when we connect via ssh to our embedded device, the backspace key > > > > > > does not work. > > > > > > During the analysis we found out that the passage > > > > > > > > > > > > # This fixes the backspace when telnetting in. > > > > > > if [ "$TERM" != "linux" ]; then > > > > > >stty erase ^H > > > > > > fi > > > > > > > > > > > > from the file '/etc/profile' contained in ptxdist. > > > > > > > > > > > > Now I want to ask, how best to fix this behavior? > > > > > > Can the passage simply be omitted? (At least the comment lets me > > > > > > assume that, because there 'telnet' is > > > > > > mentioned > > > > > > and > > > > > > that is no longer necessarily state of the art). > > > > > > Or does omitting it lead to other unwanted side effects? > > > > > > > > > > > > Any help would be appreciated. > > > > > > > > > > > > > > > > Code can interpret input characters in various ways independently of > > > > > the > > > > > stty settings. For example, if the "Command Line Editing" feature is > > > > > enabled in the Busybox configuration, the Busybox "ash" and "hush" > > > > > shells' interactive line editing will handle both ASCII DEL and ASCII > > > > > BS > > > > > as a "backspace" operation. This can be enabled in the PTXdist > > > > > menuconfig via: > > > > > > > > > > Shell & Console Tools ---> > > > > > -*- busybox ---> > > > > > Settings ---> > > > > >[*] Command Line Editing > > > > > > > > > > This sets "PTXCONF_BUSYBOX_FEATURE_EDITING=y" in the ptxconfig file. > > > > > > > > > > > > > The feature is already enabled. > > > > But it does not work for me. It only works when I delete the stty > > > > command from /etc/profile, > > > > > > > > > If you are using Bash or some other other program with READLINE > > > > > support, > > > > > I think it handles ASCII BS and ASCII DEL similarly to Busybox's > > > > > command > > > > > line editing feature. > > > > > > > > We do not use bash, we use the busybox shell. > > > > > > Just for comparison, I'm using the busybox "ash" shell. (There are two > > > shells in Busybox - "ash" and "hush".) > > > > > > My SSH client is set to send ASCII DEL when the backspace is pressed, > > > and sets TERM="xterm" or TERM="xterm-256color". The stty command on my > > > target system shows "erase ^H". > > > > > > Both the backspace key (which sends ASCII DEL) and the CTRL-H sequence > > > (which sends ASCII BS) result in a backspace operation on the ash > > > command line. > > > > > > If I run a command that doesn't do any fancy line editing, such as: > > > > > > od -c > > > > > > then the ASCII DEL characters get passed through to standard input and > > > the ASCII BS characters erase the previous characters (as per the stty > > > erase ^H setting). > > > > > > If I change the stty setting: > > > > > > stty erase '^?' > > > > > > then both ASCII DEL and ASCII BS result in a backspace operation on the > > > ash command line, but for commands that do not do any fancy line > > > editing, the ASCII BS is passed through to standard input and the ASCII > > > DEL erases the previous character as per the stty erase '^?' setting. > > > > > > So in summary, the PTXCONF_BUSYBOX_FEATURE_EDITING option seems to work > > > for me, at least in the "ash" shell. (I haven't tried the "hush" shell.) > > > > > > I am using BusyBox 1.29.3 from PTXdist 2019.03.0. > > > > > > > Sorry, I didn't describe the problem detailed enough: > > When I type in the shell, everything works as you described it. > > The problem that the backspace key doesn't work occurs when we > > use the busybox-read function from a shell script. > > > > We are using ash from busybox. > > We are using BusyBox v1.29.3 from ptxdist 2019.03.1 > > > > Sorry again for the miscommunication. > > I understand your problem now, the BusyBox ash "read" built-in does not > have line editing support, so only the kernel-level, n_tty > line-discipline editing features can be used. (Bash's "read" built-in > supports the "-e" option to allow line-editing when the input is from a > tty.) > I've already read that bash's read supports the option '-e'. But 'bash' is not an option for us at the moment. > I've no idea why that bit of the /etc/profile file is there, but I guess > it must have suited one of the PTXdist developers at the time. A "git > blame" only revealed that the whole file was added in 2006, so I don't > know how relevant that part of it is today. > > Still, it's easy enough to replace the default file with a modified one > in your project since it uses PTXdist's
[ptxdist] [PATCH] wayland: version bump 1.16.0 -> 1.17.0
Signed-off-by: Philipp Zabel --- rules/wayland.make | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rules/wayland.make b/rules/wayland.make index ccbae96bba73..22e4aa478b6e 100644 --- a/rules/wayland.make +++ b/rules/wayland.make @@ -16,8 +16,8 @@ PACKAGES-$(PTXCONF_WAYLAND) += wayland # # Paths and names # -WAYLAND_VERSION:= 1.16.0 -WAYLAND_MD5:= 0c215e53de71d6fb26f7102cdc6432d3 +WAYLAND_VERSION:= 1.17.0 +WAYLAND_MD5:= d91f970aea11fd549eae023d06f91af3 WAYLAND:= wayland-$(WAYLAND_VERSION) WAYLAND_SUFFIX := tar.xz WAYLAND_URL:= http://wayland.freedesktop.org/releases/$(WAYLAND).$(WAYLAND_SUFFIX) -- 2.20.1 ___ ptxdist mailing list ptxdist@pengutronix.de