Hi,
> Does the original code flush the multi-byte sequence on a timeout? I
> suspect it is important that one can hit ESC without having to type
> another key. Also, I'd prefer to avoid backwards gotos if possible.
Yes, sort of. If it didn't match an escape sequence and hasn't seen
additiona
On Mon, Jul 04, 2016 at 11:16:45AM +0200, Gerd Hoffmann wrote:
> Hi,
>
> > > +#define FLAG_CTRL (1<<0)
> > > +#define FLAG_SHIFT (1<<1)
> > > +
> > > +VARLOW struct {
> > > +u8 flags;
> > > +u8 scancode;
> > > +} termchr[256] = {
> > > +[ '1'] = { .scancode = 0x02,
Hi,
> > +#define FLAG_CTRL (1<<0)
> > +#define FLAG_SHIFT (1<<1)
> > +
> > +VARLOW struct {
> > +u8 flags;
> > +u8 scancode;
> > +} termchr[256] = {
> > +[ '1'] = { .scancode = 0x02, },
>
> I think this table should be generated at runtime from
> kbd.c:
On Fri, Jul 01, 2016 at 01:07:39PM -0400, Kevin O'Connor wrote:
> If I understand correctly, most keys are sent on the serial port as
> single bytes, but there are a few keys that are sent as multi-byte
> sequences. There's a lot of complexity to implement buffering for
> that unusual case. I won
On Fri, Jul 01, 2016 at 12:54:31PM +0200, Gerd Hoffmann wrote:
> Signed-off-by: Gerd Hoffmann
> ---
> src/clock.c | 1 +
> src/serial.c | 255
> +++
> src/util.h | 1 +
> 3 files changed, 257 insertions(+)
>
> diff --git a/src/clock
Signed-off-by: Gerd Hoffmann
---
src/clock.c | 1 +
src/serial.c | 255 +++
src/util.h | 1 +
3 files changed, 257 insertions(+)
diff --git a/src/clock.c b/src/clock.c
index e83e0f3..e44e112 100644
--- a/src/clock.c
+++ b/src/clock.c