source: avrstuff/ps2toserial/code/main.c@ b82c7b3

main
Last change on this file since b82c7b3 was b82c7b3, checked in by Adrien Destugues <pulkomandy@…>, 14 years ago
  • Initial import of amiga and ps/2 keyboard testers

git-svn-id: svn://pulkomandy.tk/avrstuff@1 c6672c3c-f6b6-47f9-9001-1fd6b12fecbe

  • Property mode set to 100644
File size: 425 bytes
Line 
1#include <avr/io.h>
2
3#include "keyboard.h"
4#include "usart.h"
5
6int main() {
7
8 USARTInit(51);
9 init_keyboard();
10
11 //debug LED - output
12 DDRD |= (1<<PD6);
13
14 uint8_t key_code = 0;
15
16 char str_buf[21];
17 uint8_t buf_pos = 0;
18
19 str_buf[0] = str_buf[1] = 0x00;
20 USARTWriteChar('R');
21
22 while(1) {
23 key_code = read_char();
24 USARTWriteChar(render_scan_code(key_code));
25 }
26
27 return 0;
28}
29
Note: See TracBrowser for help on using the repository browser.