Project

General

Profile

Revision 167

some changes

View differences:

keyboard.c
6 6
#include "kbc_macros.h"
7 7
#include "utils.h"
8 8
#include "errors.h"
9
#include "proj_func.h"
9 10

  
10 11
int (subscribe_kbc_interrupt)(uint8_t interrupt_bit, int *interrupt_id) {
11 12
    if (interrupt_id == NULL) return NULL_PTR;
......
19 20
int got_error_keyboard = SUCCESS;
20 21

  
21 22
void (kbc_ih)(void) {
22
    if(done) sz = 1;
23
    if(done) { update_movement(); sz = 1; }
23 24
    else     sz++;
24 25
    uint8_t status = 0;
25 26
    got_error_keyboard = SUCCESS;
......
37 38

  
38 39
    scancode[sz-1] = byte;
39 40
    done = !(TWO_BYTE_CODE == byte);
41

  
42

  
40 43
}
41 44

  
42 45
int (keyboard_poll)(uint8_t bytes[], uint8_t *size){

Also available in: Unified diff