Changeset 838c48e in mainline
- Timestamp:
- 2006-06-02T09:25:00Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 49d072e
- Parents:
- 1180a88e
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
console/console.c
r1180a88e r838c48e 140 140 scr->position_x = scr->position_x % scr->size_x; 141 141 scr->position_y = scr->position_y % scr->size_y; 142 ipc_call_async_2(fb_info.phone, FB_CURSOR_GOTO, scr->position_y, scr->position_x, NULL, NULL); 142 143 143 144 } … … 173 174 if ((c >= '1') && (c < '1' + CONSOLE_COUNT)) { 174 175 /*FIXME: draw another console content from buffer */ 175 if (c - KBD_KEY_F1== active_console)176 if (c - '1' == active_console) 176 177 break; 177 178 active_console = c - '1'; … … 187 188 ipc_call_async_3(fb_info.phone, FB_PUTCHAR, d, j, i, NULL, NULL); 188 189 } 190 189 191 ipc_call_async_2(fb_info.phone, FB_CURSOR_GOTO, conn->screenbuffer.position_y, conn->screenbuffer.position_x, NULL, NULL); 190 192 ipc_call_async(fb_info.phone, FB_CURSOR_VISIBILITY, 1, NULL, NULL); -
kbd/generic/kbd.c
r1180a88e r838c48e 52 52 ipcarg_t retval, arg1, arg2; 53 53 54 // printf("Uspace kbd service started.\n");55 56 54 /* Initialize arch dependent parts */ 57 55 if (!(res = kbd_arch_init())) { 58 // printf("Kbd registration failed with retval %d.\n", res);59 56 return -1; 60 57 }; … … 64 61 65 62 /* Register service at nameserver */ 66 // printf("%s: Registering at naming service.\n", NAME); 67 63 68 64 if ((res = ipc_connect_to_me(PHONE_NS, SERVICE_KEYBOARD, 0, &phonead)) != 0) { 69 // printf("%s: Error: Registering at naming service failed.\n", NAME);70 65 return -1; 71 66 }; … … 73 68 while (1) { 74 69 callid = ipc_wait_for_call(&call); 75 // printf("%s:Call phone=%lX..", NAME, call.in_phone_hash);76 70 switch (IPC_GET_METHOD(call)) { 77 71 case IPC_M_PHONE_HUNGUP: 78 // printf("%s: Phone hung up.\n", NAME);79 72 connected = 0; 80 73 retval = 0; 81 74 break; 82 75 case IPC_M_CONNECT_ME_TO: 83 // printf("%s: Connect me (%P) to: %zd\n",NAME, IPC_GET_ARG3(call), IPC_GET_ARG1(call));84 76 /* Only one connected client allowed */ 85 77 if (connected) { … … 100 92 kbd_arch_process(&keybuffer, IPC_GET_ARG2(call)); 101 93 102 //printf("%s: GOT INTERRUPT: %c\n", NAME, key);103 104 /* Some callers could awaiting keypress - if its true, we have to send keys to them.105 * One interrupt can store more than one key into buffer. */106 107 94 retval = 0; 108 95 109 96 while (!keybuffer_empty(&keybuffer)) { 110 97 if (!keybuffer_pop(&keybuffer, (char *)&arg1)) { 111 // printf("%s: KeyBuffer is empty but it should not be.\n");112 98 break; 113 99 } 114 /*FIXME: detection of closed connection */115 100 ipc_call_async(phoneid, KBD_PUSHCHAR, arg1, NULL, NULL); 116 101 } 117 102 118 103 } 119 // printf("%s: Interrupt processed.\n", NAME);120 104 break; 121 105 default: 122 // printf("%s: Unknown method: %zd\n", NAME, IPC_GET_METHOD(call));123 106 retval = ENOENT; 124 107 break;
Note:
See TracChangeset
for help on using the changeset viewer.