mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* Scrolling issues in edit command
@ 2016-03-30 15:38 Guillermo Rodriguez Garcia
  2016-03-31 13:39 ` Holger Schurig
  2016-04-04 20:07 ` Uwe Kleine-König
  0 siblings, 2 replies; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-03-30 15:38 UTC (permalink / raw)
  To: barebox

Hi all,

I am trying to setup Barebox on a SAMA5D3-Xplained board. I started
with barebox-2016.03.0. So far things are looking good.

I have found that I have problems in the 'edit' command, when trying
to scroll using the arrow keys. Scrolling up inserts random "A"
characters in the text, scrolling down inserts random "B" characters.
I am using minicom as the terminal. I don't remember seeing this
before with older versions of barebox on different boards.

This is not fatal of course but it makes it very cumbersome to edit
files from barebox itself. Can anyone provide any hints on why this is
happening or how to fix it ?

Thank you,

Guillermo Rodriguez

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-03-30 15:38 Scrolling issues in edit command Guillermo Rodriguez Garcia
@ 2016-03-31 13:39 ` Holger Schurig
  2016-03-31 15:36   ` Guillermo Rodriguez Garcia
  2016-04-04 20:07 ` Uwe Kleine-König
  1 sibling, 1 reply; 15+ messages in thread
From: Holger Schurig @ 2016-03-31 13:39 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox

Guillermo Rodriguez Garcia <guille.rodriguez@gmail.com> writes:

> Can anyone provide any hints on why this is
> happening or how to fix it ?

I guess this is probably because your terminal emulation doesn't match
what barebox assume.



I personally connect from Linux via the serial line with kermit to my
target. Kermit has a simple ~/.kermrc file that looks like this:

    set line /dev/ttyS0
    set baud 115200
    set handshake none
    set flow-control none
    set carrier-watch off
    set escape-character ^X
    log session ~/.kermlog
    connect

Kermit is oblivious to any ANSI escape sequences, so my X11 terminal
emulates them. Here I use the rxvt-unicode binary `urxvt`. The effect is
that the "edit" commands works.

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-03-31 13:39 ` Holger Schurig
@ 2016-03-31 15:36   ` Guillermo Rodriguez Garcia
  2016-04-04  6:38     ` Sascha Hauer
  0 siblings, 1 reply; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-03-31 15:36 UTC (permalink / raw)
  To: Holger Schurig; +Cc: barebox

Hello,

Thank you for the answer. Some comments below.

2016-03-31 15:39 GMT+02:00 Holger Schurig <holgerschurig@gmail.com>:
> Guillermo Rodriguez Garcia <guille.rodriguez@gmail.com> writes:
>
>> Can anyone provide any hints on why this is
>> happening or how to fix it ?
>
> I guess this is probably because your terminal emulation doesn't match
> what barebox assume.

Uhm, could be, however I have also been using minicom with an older
version of barebox for a long time (2011.05.0, on a different target
board), and never had any problems at all. I only noticed this
behaviour when testing barebox 2016.03.0 on a new board.

[...]
> Kermit is oblivious to any ANSI escape sequences, so my X11 terminal
> emulates them. Here I use the rxvt-unicode binary `urxvt`. The effect is
> that the "edit" commands works.

Perhaps I should clarify what I am seeing. The "edit" command actually
works, more or less. If I scroll up or down one line at a time then
there are no problems. I only see bogus A or B characters inserted
when I do "continuous" scrolling. Also I noticed that ESC [ A is the
ANSI escape sequence for "cursor up", and ESC [ B is the ANSI escape
sequence for "cursor down". Perhaps when I keep the arrow up/down key
pressed, minicom is sending these escape sequences faster than barebox
can handle them, and that's why I see the 'A' and 'B' characters
inserted?

Regards,

Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-03-31 15:36   ` Guillermo Rodriguez Garcia
@ 2016-04-04  6:38     ` Sascha Hauer
  2016-04-04 13:34       ` Guillermo Rodriguez Garcia
  0 siblings, 1 reply; 15+ messages in thread
From: Sascha Hauer @ 2016-04-04  6:38 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox

On Thu, Mar 31, 2016 at 05:36:58PM +0200, Guillermo Rodriguez Garcia wrote:
> Hello,
> 
> Thank you for the answer. Some comments below.
> 
> 2016-03-31 15:39 GMT+02:00 Holger Schurig <holgerschurig@gmail.com>:
> > Guillermo Rodriguez Garcia <guille.rodriguez@gmail.com> writes:
> >
> >> Can anyone provide any hints on why this is
> >> happening or how to fix it ?
> >
> > I guess this is probably because your terminal emulation doesn't match
> > what barebox assume.
> 
> Uhm, could be, however I have also been using minicom with an older
> version of barebox for a long time (2011.05.0, on a different target
> board), and never had any problems at all. I only noticed this
> behaviour when testing barebox 2016.03.0 on a new board.
> 
> [...]
> > Kermit is oblivious to any ANSI escape sequences, so my X11 terminal
> > emulates them. Here I use the rxvt-unicode binary `urxvt`. The effect is
> > that the "edit" commands works.
> 
> Perhaps I should clarify what I am seeing. The "edit" command actually
> works, more or less. If I scroll up or down one line at a time then
> there are no problems. I only see bogus A or B characters inserted
> when I do "continuous" scrolling. Also I noticed that ESC [ A is the
> ANSI escape sequence for "cursor up", and ESC [ B is the ANSI escape
> sequence for "cursor down". Perhaps when I keep the arrow up/down key
> pressed, minicom is sending these escape sequences faster than barebox
> can handle them, and that's why I see the 'A' and 'B' characters
> inserted?

Yes, could be. I have never seen such a behaviour. Normally the rate
your host sends "ESC [ B" is limited by the keyboard repeat rate, not by
the serial port speed, so I think barebox should be able to follow this.

What we see here more and more frequently is that the signal level
generated on one side is not high enough for the other side to detect it
properly. Maybe you have similar issues? How about pasting copy/pasting
text on the barebox command line using middle mouse button? Does that
work properly?

I recommend microcom as a terminal program. Like kermit it does not
emulate a terminal but is just a 1:1 pass through to the host terminal.
Unlike kermit microcom can be passed the port to use on the command
line. It's part of Debian/Ubuntu.

Sascha


-- 
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-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-04  6:38     ` Sascha Hauer
@ 2016-04-04 13:34       ` Guillermo Rodriguez Garcia
  2016-04-05  7:32         ` Rolf Evers-Fischer
  0 siblings, 1 reply; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-04-04 13:34 UTC (permalink / raw)
  To: Sascha Hauer; +Cc: barebox

2016-04-04 8:38 GMT+02:00 Sascha Hauer <s.hauer@pengutronix.de>:
> On Thu, Mar 31, 2016 at 05:36:58PM +0200, Guillermo Rodriguez Garcia wrote:
>> Hello,
>>
>> Thank you for the answer. Some comments below.
>>
>> 2016-03-31 15:39 GMT+02:00 Holger Schurig <holgerschurig@gmail.com>:
>> > Guillermo Rodriguez Garcia <guille.rodriguez@gmail.com> writes:
>> >
>> >> Can anyone provide any hints on why this is
>> >> happening or how to fix it ?
>> >
>> > I guess this is probably because your terminal emulation doesn't match
>> > what barebox assume.
>>
>> Uhm, could be, however I have also been using minicom with an older
>> version of barebox for a long time (2011.05.0, on a different target
>> board), and never had any problems at all. I only noticed this
>> behaviour when testing barebox 2016.03.0 on a new board.
>>
>> [...]
>> > Kermit is oblivious to any ANSI escape sequences, so my X11 terminal
>> > emulates them. Here I use the rxvt-unicode binary `urxvt`. The effect is
>> > that the "edit" commands works.
>>
>> Perhaps I should clarify what I am seeing. The "edit" command actually
>> works, more or less. If I scroll up or down one line at a time then
>> there are no problems. I only see bogus A or B characters inserted
>> when I do "continuous" scrolling. Also I noticed that ESC [ A is the
>> ANSI escape sequence for "cursor up", and ESC [ B is the ANSI escape
>> sequence for "cursor down". Perhaps when I keep the arrow up/down key
>> pressed, minicom is sending these escape sequences faster than barebox
>> can handle them, and that's why I see the 'A' and 'B' characters
>> inserted?
>
> Yes, could be. I have never seen such a behaviour. Normally the rate
> your host sends "ESC [ B" is limited by the keyboard repeat rate, not by
> the serial port speed, so I think barebox should be able to follow this.
>
> What we see here more and more frequently is that the signal level
> generated on one side is not high enough for the other side to detect it
> properly. Maybe you have similar issues? How about pasting copy/pasting
> text on the barebox command line using middle mouse button? Does that
> work properly?

That's a very good question. I just tried to paste this text in
barebox's command line:

Lorem Ipsum is simply dummy text of the printing and typesetting industry.

It works perfectly. However I then tried to paste the very same text
in a "edit" window. Every time, the following is pasted:

Lois simply dummy text of the printing and typesetting industry.

That's exactly 10 characters missing after the first two.

What could be causing this and then only in the "edit" command, but
not in the command line?

>
> I recommend microcom as a terminal program. Like kermit it does not
> emulate a terminal but is just a 1:1 pass through to the host terminal.
> Unlike kermit microcom can be passed the port to use on the command
> line. It's part of Debian/Ubuntu.

Just tried microcom. I have exactly the same problems with scrolling
('A' and 'B' characters inserted when continuously scrolling up-down).

Any other hints ?

Thank you,

Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-03-30 15:38 Scrolling issues in edit command Guillermo Rodriguez Garcia
  2016-03-31 13:39 ` Holger Schurig
@ 2016-04-04 20:07 ` Uwe Kleine-König
  2016-04-05  7:52   ` Guillermo Rodriguez Garcia
  1 sibling, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2016-04-04 20:07 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox

Hello,

On Wed, Mar 30, 2016 at 05:38:53PM +0200, Guillermo Rodriguez Garcia wrote:
> I am trying to setup Barebox on a SAMA5D3-Xplained board. I started
> with barebox-2016.03.0. So far things are looking good.
> 
> I have found that I have problems in the 'edit' command, when trying
> to scroll using the arrow keys. Scrolling up inserts random "A"
> characters in the text, scrolling down inserts random "B" characters.
> I am using minicom as the terminal. I don't remember seeing this
> before with older versions of barebox on different boards.

Can you instrument your serial driver to count/notice overflow events?
It's strange that you're missing chars 3-12 in a longer paste.

Does it help to use

	busybox microcom -d 10 ...

? (That is a feature that is missing from the "fullblown" microcom that
comes in the microcom package.)

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-04 13:34       ` Guillermo Rodriguez Garcia
@ 2016-04-05  7:32         ` Rolf Evers-Fischer
  0 siblings, 0 replies; 15+ messages in thread
From: Rolf Evers-Fischer @ 2016-04-05  7:32 UTC (permalink / raw)
  To: barebox

Guillermo Rodriguez Garcia <guille.rodriguez@...> writes:
> 
> That's a very good question. I just tried to paste this text in
> barebox's command line:
> 
> Lorem Ipsum is simply dummy text of the printing and typesetting industry.
> 
> It works perfectly. However I then tried to paste the very same text
> in a "edit" window. Every time, the following is pasted:
> 
> Lois simply dummy text of the printing and typesetting industry.
> 
> That's exactly 10 characters missing after the first two.
> 
> What could be causing this and then only in the "edit" command, but
> not in the command line?
> 
> Any other hints ?
> 
Hello,
I have had a similar problem (missing characters) with a SAMV71Xplained
board and NuttX OS. In my case this problem was caused by a disabled
instruction cache. Could you please check if your caches are enabled?

Best regards,
 Rolf




_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-04 20:07 ` Uwe Kleine-König
@ 2016-04-05  7:52   ` Guillermo Rodriguez Garcia
  2016-04-05  8:14     ` Uwe Kleine-König
  0 siblings, 1 reply; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-04-05  7:52 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: barebox

2016-04-04 22:07 GMT+02:00 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:
> Hello,
>
> On Wed, Mar 30, 2016 at 05:38:53PM +0200, Guillermo Rodriguez Garcia wrote:
>> I am trying to setup Barebox on a SAMA5D3-Xplained board. I started
>> with barebox-2016.03.0. So far things are looking good.
>>
>> I have found that I have problems in the 'edit' command, when trying
>> to scroll using the arrow keys. Scrolling up inserts random "A"
>> characters in the text, scrolling down inserts random "B" characters.
>> I am using minicom as the terminal. I don't remember seeing this
>> before with older versions of barebox on different boards.
>
> Can you instrument your serial driver to count/notice overflow events?

You mean in barebox, or in the host where I'm running minicom/microcom?

> It's strange that you're missing chars 3-12 in a longer paste.
>
> Does it help to use
>
>         busybox microcom -d 10 ...
>
> ? (That is a feature that is missing from the "fullblown" microcom that
> comes in the microcom package.)

Interesting. I tried that, the result is:

- Still the same problem when scrolling up and down in "edit" (A and B
characters inserted)
- Many more missing chars when pasting "Lorem ipsum.." (_in "edit"_).
Here are three examples:

Loe Ismismyuye   iinatestis.
Loe Ismismyuye  eiinatest uy.
Loe Ismismyuye   iinatest uy.

- The very same text can be pasted perfectly in barebox's command
line, no missing chars. The problem is only with the "edit" command.
What makes "edit" different ?

Guillermo

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05  7:52   ` Guillermo Rodriguez Garcia
@ 2016-04-05  8:14     ` Uwe Kleine-König
  2016-04-05  8:40       ` Guillermo Rodriguez Garcia
  0 siblings, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2016-04-05  8:14 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox

On Tue, Apr 05, 2016 at 09:52:39AM +0200, Guillermo Rodriguez Garcia wrote:
> 2016-04-04 22:07 GMT+02:00 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:
> > Hello,
> >
> > On Wed, Mar 30, 2016 at 05:38:53PM +0200, Guillermo Rodriguez Garcia wrote:
> >> I am trying to setup Barebox on a SAMA5D3-Xplained board. I started
> >> with barebox-2016.03.0. So far things are looking good.
> >>
> >> I have found that I have problems in the 'edit' command, when trying
> >> to scroll using the arrow keys. Scrolling up inserts random "A"
> >> characters in the text, scrolling down inserts random "B" characters.
> >> I am using minicom as the terminal. I don't remember seeing this
> >> before with older versions of barebox on different boards.
> >
> > Can you instrument your serial driver to count/notice overflow events?
> 
> You mean in barebox, or in the host where I'm running minicom/microcom?

in barebox. Also, what is your rs232 hardware? Some usb-to-rs232
adapters are not reliable. The native 8250 ports on PCs are good ones I
think.

> > It's strange that you're missing chars 3-12 in a longer paste.
> >
> > Does it help to use
> >
> >         busybox microcom -d 10 ...
> >
> > ? (That is a feature that is missing from the "fullblown" microcom that
> > comes in the microcom package.)
> 
> Interesting. I tried that, the result is:
> 
> - Still the same problem when scrolling up and down in "edit" (A and B
> characters inserted)
> - Many more missing chars when pasting "Lorem ipsum.." (_in "edit"_).
> Here are three examples:
> 
> Loe Ismismyuye   iinatestis.
> Loe Ismismyuye  eiinatest uy.
> Loe Ismismyuye   iinatest uy.
> 
> - The very same text can be pasted perfectly in barebox's command
> line, no missing chars. The problem is only with the "edit" command.
> What makes "edit" different ?

That's strange. No idea here.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05  8:14     ` Uwe Kleine-König
@ 2016-04-05  8:40       ` Guillermo Rodriguez Garcia
  2016-04-05  9:05         ` Uwe Kleine-König
  0 siblings, 1 reply; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-04-05  8:40 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: barebox

Hello,

2016-04-05 10:14 GMT+02:00 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:
> On Tue, Apr 05, 2016 at 09:52:39AM +0200, Guillermo Rodriguez Garcia wrote:
>> 2016-04-04 22:07 GMT+02:00 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:
>> > Hello,
>> >
>> > On Wed, Mar 30, 2016 at 05:38:53PM +0200, Guillermo Rodriguez Garcia wrote:
>> >> I am trying to setup Barebox on a SAMA5D3-Xplained board. I started
>> >> with barebox-2016.03.0. So far things are looking good.
>> >>
>> >> I have found that I have problems in the 'edit' command, when trying
>> >> to scroll using the arrow keys. Scrolling up inserts random "A"
>> >> characters in the text, scrolling down inserts random "B" characters.
>> >> I am using minicom as the terminal. I don't remember seeing this
>> >> before with older versions of barebox on different boards.
>> >
>> > Can you instrument your serial driver to count/notice overflow events?
>>
>> You mean in barebox, or in the host where I'm running minicom/microcom?
>
> in barebox.

I can inspect the UART's status register using md and clear the
overrun bit using mw.

Yes, both the scrolling problem and the "missing chars problem" when
pasting text in barebox are associated with overruns.

Still I don't understand why pasting the same text in the command line
does not result in an overrun.

Perhaps "edit" is so busy repainting the screen that the incoming
characters are not handled in time?

> Also, what is your rs232 hardware? Some usb-to-rs232
> adapters are not reliable. The native 8250 ports on PCs are good ones I
> think.

It is a USB to rs232 converter but I am also using this on other
boards running barebox (older version of barebox though, and different
target hardware) and no problems there.

Just to be safe I repeated the tests on a PC that has native serial
ports. That one is a Windows box so I used PuTTY. On that setup I do
not see the "missing chars problem" , however the scrolling problem
still exists (random "A" and "B" characters inserted while scrolling).

I am wondering: If I am correct, serial in/out in barebox is not
interrupt-driven. Plus, the default UART in the sama5d3_xplained board
that I am using (DBGU) has no FIFOs. Plus, "edit" does a lot of
repaint work while editing. Could it be the case that received chars
are being missed by barebox due to the repainting work in "edit" ?

Best,

Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05  8:40       ` Guillermo Rodriguez Garcia
@ 2016-04-05  9:05         ` Uwe Kleine-König
  2016-04-05  9:40           ` Rolf Evers-Fischer
  0 siblings, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2016-04-05  9:05 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox

Hello,

On Tue, Apr 05, 2016 at 10:40:48AM +0200, Guillermo Rodriguez Garcia wrote:
> I am wondering: If I am correct, serial in/out in barebox is not
> interrupt-driven. Plus, the default UART in the sama5d3_xplained board

right

> that I am using (DBGU) has no FIFOs. Plus, "edit" does a lot of
> repaint work while editing. Could it be the case that received chars
> are being missed by barebox due to the repainting work in "edit" ?

Sounds likely.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05  9:05         ` Uwe Kleine-König
@ 2016-04-05  9:40           ` Rolf Evers-Fischer
  2016-04-05 11:01             ` Guillermo Rodriguez Garcia
  0 siblings, 1 reply; 15+ messages in thread
From: Rolf Evers-Fischer @ 2016-04-05  9:40 UTC (permalink / raw)
  To: guille.rodriguez, u.kleine-koenig; +Cc: barebox

[-- Attachment #1: Type: TEXT/PLAIN, Size: 709 bytes --]

Uwe Kleine-König <u.kleine-koenig@...> writes:

> 
> Hello,
> 
> On Tue, Apr 05, 2016 at 10:40:48AM +0200, Guillermo Rodriguez Garcia 
wrote:
> > I am wondering: If I am correct, serial in/out in barebox is not
> > interrupt-driven. Plus, the default UART in the sama5d3_xplained board
> 
> right
> 
> > that I am using (DBGU) has no FIFOs. Plus, "edit" does a lot of
> > repaint work while editing. Could it be the case that received chars
> > are being missed by barebox due to the repainting work in "edit" ?
> 
> Sounds likely.
> 

But if the instruction cache is enabled, the SAMA5 should be fast enough, 
even without any interrupt handling for the UART data.

Best regards,
 Rolf

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05  9:40           ` Rolf Evers-Fischer
@ 2016-04-05 11:01             ` Guillermo Rodriguez Garcia
  2016-04-05 12:23               ` Uwe Kleine-König
  0 siblings, 1 reply; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-04-05 11:01 UTC (permalink / raw)
  To: Rolf Evers-Fischer; +Cc: barebox, Uwe Kleine-König

2016-04-05 11:40 GMT+02:00 Rolf Evers-Fischer <embedded24@evers-fischer.de>:
> Uwe Kleine-König <u.kleine-koenig@...> writes:
>
>>
>> Hello,
>>
>> On Tue, Apr 05, 2016 at 10:40:48AM +0200, Guillermo Rodriguez Garcia
> wrote:
>> > I am wondering: If I am correct, serial in/out in barebox is not
>> > interrupt-driven. Plus, the default UART in the sama5d3_xplained board
>>
>> right
>>
>> > that I am using (DBGU) has no FIFOs. Plus, "edit" does a lot of
>> > repaint work while editing. Could it be the case that received chars
>> > are being missed by barebox due to the repainting work in "edit" ?
>>
>> Sounds likely.
>>
>
> But if the instruction cache is enabled, the SAMA5 should be fast enough,
> even without any interrupt handling for the UART data.

It actually seems to be fast enough for handling input data the
command line. I only see problems in "edit". And the original issue
(problems while scrolling continuously) mostly happens when the window
needs to be scrolled, and thus fully repainted for every scroll
up/down command received.

I don't think the limitation is actually related to CPU power in the
SAMA5. When "edit" is repainting, it needs to send all the new data
out through the serial port. If serial port tx is also not
interrupt-driven (not sure about that), then this means that barebox
will not have a chance to process new input until "edit" is done
sending data. Combine this with the lack of FIFOs in the DBGU port and
I guess that this could explain the results.

However if there are other issues I would also like to find out. If
you would like to suggest any new tests please let me know and I'll be
happy to try them here.

Best,

Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05 11:01             ` Guillermo Rodriguez Garcia
@ 2016-04-05 12:23               ` Uwe Kleine-König
  2016-04-05 15:31                 ` Guillermo Rodriguez Garcia
  0 siblings, 1 reply; 15+ messages in thread
From: Uwe Kleine-König @ 2016-04-05 12:23 UTC (permalink / raw)
  To: Guillermo Rodriguez Garcia; +Cc: barebox, Rolf Evers-Fischer

Hello,

On Tue, Apr 05, 2016 at 01:01:02PM +0200, Guillermo Rodriguez Garcia wrote:
> However if there are other issues I would also like to find out. If
> you would like to suggest any new tests please let me know and I'll be
> happy to try them here.
There are ANSI control sequences for scrolling, too. I don't know if
they are used, but if they were it would greatly reduce the needed
bandwidth.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: Scrolling issues in edit command
  2016-04-05 12:23               ` Uwe Kleine-König
@ 2016-04-05 15:31                 ` Guillermo Rodriguez Garcia
  0 siblings, 0 replies; 15+ messages in thread
From: Guillermo Rodriguez Garcia @ 2016-04-05 15:31 UTC (permalink / raw)
  To: Uwe Kleine-König; +Cc: barebox, Rolf Evers-Fischer

Hello,

2016-04-05 14:23 GMT+02:00 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:
> Hello,
>
> On Tue, Apr 05, 2016 at 01:01:02PM +0200, Guillermo Rodriguez Garcia wrote:
>> However if there are other issues I would also like to find out. If
>> you would like to suggest any new tests please let me know and I'll be
>> happy to try them here.
> There are ANSI control sequences for scrolling, too. I don't know if
> they are used, but if they were it would greatly reduce the needed
> bandwidth.

The ANSI control sequences are disabled by default, but they are used
if the command is invoked as "sedit" instead of "edit".

When the command is invoked as "sedit" the scrolling problem is gone.

I guess this more or less supports the hypothesis that the problem
could be caused by losing incoming characters due to the lack of FIFOs
in this port + the repainting performed by "edit". If this sounds
reasonable then I guess there's not much more that can be done here. I
just wanted to make suere there were no other underlying problems.

Thank you all for the feedback and help,

Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2016-04-05 15:31 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-30 15:38 Scrolling issues in edit command Guillermo Rodriguez Garcia
2016-03-31 13:39 ` Holger Schurig
2016-03-31 15:36   ` Guillermo Rodriguez Garcia
2016-04-04  6:38     ` Sascha Hauer
2016-04-04 13:34       ` Guillermo Rodriguez Garcia
2016-04-05  7:32         ` Rolf Evers-Fischer
2016-04-04 20:07 ` Uwe Kleine-König
2016-04-05  7:52   ` Guillermo Rodriguez Garcia
2016-04-05  8:14     ` Uwe Kleine-König
2016-04-05  8:40       ` Guillermo Rodriguez Garcia
2016-04-05  9:05         ` Uwe Kleine-König
2016-04-05  9:40           ` Rolf Evers-Fischer
2016-04-05 11:01             ` Guillermo Rodriguez Garcia
2016-04-05 12:23               ` Uwe Kleine-König
2016-04-05 15:31                 ` Guillermo Rodriguez Garcia

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox