Beispiel #1
0
Datei: devtty.c Projekt: 8l/FUZIX
void kbd_interrupt(void)
{
	newkey = 0;
	keyproc();
	if (keysdown && keysdown < 3) {
		if (newkey) {
			keydecode();
			kbd_timer = keyrepeat.first;
		} else if (! --kbd_timer) {
			keydecode();
			kbd_timer = keyrepeat.continual;
		}
	}
}
Beispiel #2
0
void platform_interrupt(void)
{
	uint8_t a = irqmap;
	uint8_t c;
	if (!(a & 2))
		wakeup(&ttydata[2]);
	if (!(a & 1)) {
		/* work around sdcc bug */
		c = uarta;
		tty_inproc(2, c);
	}
	if (!(a & 8)) {
		keyin[0] = kmap0;
		keyin[1] = kmap1;
		keyin[2] = kmap2;
		keyin[3] = kmap3;
		keyin[4] = kmap4;
		keyin[5] = kmap5;
		keyin[6] = kmap6;
		keyin[7] = kmap7;
		keyin[8] = kmap8;
		keyin[9] = kmap9;	/* This resets the scan for 10mS on */

		newkey = 0;
		keyproc();
		if (keysdown < 3 && newkey)
			keydecode();
		timer_interrupt();
	}
	/* clear the mask */
	irqmap = a;
}
Beispiel #3
0
void kbd_interrupt(void)
{
    newkey = 0;
    keyproc();
    if (keysdown < 3 && newkey)
        keydecode();
}
Beispiel #4
0
void kbd_poll(void)
{
	/* Report any press of the NMI button */
	if (nmikey) {
		nmikey = 0;
		vt_inproc(1, KEY_STOP);
	}
	newkey = 0;
	keyproc();
	if (keysdown && keysdown < 3) {
		if (newkey) {
			keydecode();
			kbd_timer = keyrepeat.first;
		} else if (!--kbd_timer) {
			keydecode();
			kbd_timer = keyrepeat.continual;
		}
	}
}
Beispiel #5
0
void platform_interrupt(void)
{
	uint8_t i = *pia_ctrl;
	if (i & 0x80) {
		*pia_col;
		newkey = 0;
		keyproc();
		if (keysdown && keysdown < 3) {
			if (newkey) {
				keydecode();
				kbd_timer = keyrepeat.first;
			} else if (! --kbd_timer) {
				keydecode();
				kbd_timer = keyrepeat.continual;
			}
		}
		timer_interrupt();
	}
}
Beispiel #6
0
void platform_interrupt(void)
{
	uint8_t i = *pia_ctrl;
	if (i & 0x80) {
		*pia_col;
		newkey = 0;
		keyproc();
		if (keysdown < 3 && newkey)
			keydecode();
		timer_interrupt();
	}
}
Beispiel #7
0
void platform_interrupt(void)
{
	uint8_t a = irqmap;
	uint8_t c;
	if (!(a & 4)) {
		/* FIXME: need to check uart itself to see wake cause */
		wakeup(&ttydata[2]);
		/* work around sdcc bug */
		c = uarta;
		tty_inproc(2, c);
	}
	if (!(a & 8)) {
		keyin[0] = kmap0;
		keyin[1] = kmap1;
		keyin[2] = kmap2;
		keyin[3] = kmap3;
		keyin[4] = kmap4;
		keyin[5] = kmap5;
		keyin[6] = kmap6;
		keyin[7] = kmap7;
		keyin[8] = kmap8;
		keyin[9] = kmap9;	/* This resets the scan for 10mS on */

		newkey = 0;
		keyproc();
		if (keysdown < 3 && newkey)
			keydecode();
		timer_interrupt();
	}
	if (!(a & 16)) {
		/* FIXME: Power button */
		;
	}
	if (!(a & 32)) {
		/* FIXME: FDC interrupt */
		;
	}
	/* clear the mask */
	irqmap = a;
}