{"action":"created","comment":{"url":"https://api.github.com/repos/intermezzOS/kernel/pulls/comments/83150393","pull_request_review_id":4009784,"id":83150393,"diff_hunk":"@@ -1,11 +1,433 @@\n #![no_std]\n \n-static CODES: [u8; 59] = *b\"??1234567890-=??qwertyuiop[]\\n?asdfghjkl;'`?\\\\zxcvbnm,./?*? ?\";\n+pub enum Action {\n+    Pressed,\n+    Released,\n+}\n+\n+#[derive(Clone, Copy, Debug, PartialEq)]\n+pub enum Key {\n+    KA,","path":"keyboard/src/lib.rs","position":10,"original_position":11,"commit_id":"15c9715ce10d3db5cac7c222cd08a1dfe67649f7","original_commit_id":"05fe01bc598304cbf57480a264c24e43beca46f2","user":{"login":"dirk","id":7081,"avatar_url":"https://avatars.githubusercontent.com/u/7081?v=3","gravatar_id":"","url":"https://api.github.com/users/dirk","html_url":"https://github.com/dirk","followers_url":"https://api.github.com/users/dirk/followers","following_url":"https://api.github.com/users/dirk/following{/other_user}","gists_url":"https://api.github.com/users/dirk/gists{/gist_id}","starred_url":"https://api.github.com/users/dirk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dirk/subscriptions","organizations_url":"https://api.github.com/users/dirk/orgs","repos_url":"https://api.github.com/users/dirk/repos","events_url":"https://api.github.com/users/dirk/events{/privacy}","received_events_url":"https://api.github.com/users/dirk/received_events","type":"User","site_admin":false},"body":"The Rust compiler wasn't happy with `0`, `1`, etc. as plain numbers. I updated it to use plain letters/words for most of the codes, and then these keyboard (not keypad) number codes are prefixed with `Keyboard`. Also included a comment before them to note the difference between the keyboard number keys and the keypad number keys.","created_at":"2016-10-13T06:23:27Z","updated_at":"2016-10-13T06:23:27Z","html_url":"https://github.com/intermezzOS/kernel/pull/90#discussion_r83150393","pull_request_url":"https://api.github.com/repos/intermezzOS/kernel/pulls/90","_links":{"self":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/comments/83150393"},"html":{"href":"https://github.com/intermezzOS/kernel/pull/90#discussion_r83150393"},"pull_request":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/90"}}},"pull_request":{"url":"https://api.github.com/repos/intermezzOS/kernel/pulls/90","id":87625212,"html_url":"https://github.com/intermezzOS/kernel/pull/90","diff_url":"https://github.com/intermezzOS/kernel/pull/90.diff","patch_url":"https://github.com/intermezzOS/kernel/pull/90.patch","issue_url":"https://api.github.com/repos/intermezzOS/kernel/issues/90","number":90,"state":"open","locked":false,"title":"Stateful keyboard driver","user":{"login":"dirk","id":7081,"avatar_url":"https://avatars.githubusercontent.com/u/7081?v=3","gravatar_id":"","url":"https://api.github.com/users/dirk","html_url":"https://github.com/dirk","followers_url":"https://api.github.com/users/dirk/followers","following_url":"https://api.github.com/users/dirk/following{/other_user}","gists_url":"https://api.github.com/users/dirk/gists{/gist_id}","starred_url":"https://api.github.com/users/dirk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dirk/subscriptions","organizations_url":"https://api.github.com/users/dirk/orgs","repos_url":"https://api.github.com/users/dirk/repos","events_url":"https://api.github.com/users/dirk/events{/privacy}","received_events_url":"https://api.github.com/users/dirk/received_events","type":"User","site_admin":false},"body":"Builds off of #89 to start constructing a stateful keyboard driver capable of modeling the user's interaction with the keyboard and translating that into key codes for the OS and programs.\r\n\r\n- [x] Decode basic set of 1-byte PS/2 scan codes\r\n- [x] Managed internal state of pressed keys, clear state when keys released\r\n- [x] Return current printable character to OS (when possible) when inputting latest scan code\r\n- [x] Report backspace and other non-printables to the OS (send ASCII code?)\r\n- [x] Tests!\r\n- [ ] Decode 2-byte and 3-byte PS/2 scan codes (stretch goal); this will need more complex state management in the driver","created_at":"2016-10-02T05:36:27Z","updated_at":"2016-10-13T06:23:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d6e3fe6682ac18825523012ab0ebb7f403efce99","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/intermezzOS/kernel/pulls/90/commits","review_comments_url":"https://api.github.com/repos/intermezzOS/kernel/pulls/90/comments","review_comment_url":"https://api.github.com/repos/intermezzOS/kernel/pulls/comments{/number}","comments_url":"https://api.github.com/repos/intermezzOS/kernel/issues/90/comments","statuses_url":"https://api.github.com/repos/intermezzOS/kernel/statuses/15c9715ce10d3db5cac7c222cd08a1dfe67649f7","head":{"label":"dirk:dirk-keyboard-driver-state-machine","ref":"dirk-keyboard-driver-state-machine","sha":"15c9715ce10d3db5cac7c222cd08a1dfe67649f7","user":{"login":"dirk","id":7081,"avatar_url":"https://avatars.githubusercontent.com/u/7081?v=3","gravatar_id":"","url":"https://api.github.com/users/dirk","html_url":"https://github.com/dirk","followers_url":"https://api.github.com/users/dirk/followers","following_url":"https://api.github.com/users/dirk/following{/other_user}","gists_url":"https://api.github.com/users/dirk/gists{/gist_id}","starred_url":"https://api.github.com/users/dirk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dirk/subscriptions","organizations_url":"https://api.github.com/users/dirk/orgs","repos_url":"https://api.github.com/users/dirk/repos","events_url":"https://api.github.com/users/dirk/events{/privacy}","received_events_url":"https://api.github.com/users/dirk/received_events","type":"User","site_admin":false},"repo":{"id":69778873,"name":"kernel","full_name":"dirk/kernel","owner":{"login":"dirk","id":7081,"avatar_url":"https://avatars.githubusercontent.com/u/7081?v=3","gravatar_id":"","url":"https://api.github.com/users/dirk","html_url":"https://github.com/dirk","followers_url":"https://api.github.com/users/dirk/followers","following_url":"https://api.github.com/users/dirk/following{/other_user}","gists_url":"https://api.github.com/users/dirk/gists{/gist_id}","starred_url":"https://api.github.com/users/dirk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dirk/subscriptions","organizations_url":"https://api.github.com/users/dirk/orgs","repos_url":"https://api.github.com/users/dirk/repos","events_url":"https://api.github.com/users/dirk/events{/privacy}","received_events_url":"https://api.github.com/users/dirk/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dirk/kernel","description":"A hobby operating system, in Rust","fork":true,"url":"https://api.github.com/repos/dirk/kernel","forks_url":"https://api.github.com/repos/dirk/kernel/forks","keys_url":"https://api.github.com/repos/dirk/kernel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dirk/kernel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dirk/kernel/teams","hooks_url":"https://api.github.com/repos/dirk/kernel/hooks","issue_events_url":"https://api.github.com/repos/dirk/kernel/issues/events{/number}","events_url":"https://api.github.com/repos/dirk/kernel/events","assignees_url":"https://api.github.com/repos/dirk/kernel/assignees{/user}","branches_url":"https://api.github.com/repos/dirk/kernel/branches{/branch}","tags_url":"https://api.github.com/repos/dirk/kernel/tags","blobs_url":"https://api.github.com/repos/dirk/kernel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dirk/kernel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dirk/kernel/git/refs{/sha}","trees_url":"https://api.github.com/repos/dirk/kernel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dirk/kernel/statuses/{sha}","languages_url":"https://api.github.com/repos/dirk/kernel/languages","stargazers_url":"https://api.github.com/repos/dirk/kernel/stargazers","contributors_url":"https://api.github.com/repos/dirk/kernel/contributors","subscribers_url":"https://api.github.com/repos/dirk/kernel/subscribers","subscription_url":"https://api.github.com/repos/dirk/kernel/subscription","commits_url":"https://api.github.com/repos/dirk/kernel/commits{/sha}","git_commits_url":"https://api.github.com/repos/dirk/kernel/git/commits{/sha}","comments_url":"https://api.github.com/repos/dirk/kernel/comments{/number}","issue_comment_url":"https://api.github.com/repos/dirk/kernel/issues/comments{/number}","contents_url":"https://api.github.com/repos/dirk/kernel/contents/{+path}","compare_url":"https://api.github.com/repos/dirk/kernel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dirk/kernel/merges","archive_url":"https://api.github.com/repos/dirk/kernel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dirk/kernel/downloads","issues_url":"https://api.github.com/repos/dirk/kernel/issues{/number}","pulls_url":"https://api.github.com/repos/dirk/kernel/pulls{/number}","milestones_url":"https://api.github.com/repos/dirk/kernel/milestones{/number}","notifications_url":"https://api.github.com/repos/dirk/kernel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dirk/kernel/labels{/name}","releases_url":"https://api.github.com/repos/dirk/kernel/releases{/id}","deployments_url":"https://api.github.com/repos/dirk/kernel/deployments","created_at":"2016-10-02T04:29:42Z","updated_at":"2016-10-02T04:29:43Z","pushed_at":"2016-10-13T05:57:52Z","git_url":"git://github.com/dirk/kernel.git","ssh_url":"git@github.com:dirk/kernel.git","clone_url":"https://github.com/dirk/kernel.git","svn_url":"https://github.com/dirk/kernel","homepage":"http://intermezzos.github.io/","size":237,"stargazers_count":0,"watchers_count":0,"language":"Rust","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"intermezzOS:master","ref":"master","sha":"b5bbb3f23f4b65b01a6d8f2734ea6c447c9906e1","user":{"login":"intermezzOS","id":16422108,"avatar_url":"https://avatars.githubusercontent.com/u/16422108?v=3","gravatar_id":"","url":"https://api.github.com/users/intermezzOS","html_url":"https://github.com/intermezzOS","followers_url":"https://api.github.com/users/intermezzOS/followers","following_url":"https://api.github.com/users/intermezzOS/following{/other_user}","gists_url":"https://api.github.com/users/intermezzOS/gists{/gist_id}","starred_url":"https://api.github.com/users/intermezzOS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intermezzOS/subscriptions","organizations_url":"https://api.github.com/users/intermezzOS/orgs","repos_url":"https://api.github.com/users/intermezzOS/repos","events_url":"https://api.github.com/users/intermezzOS/events{/privacy}","received_events_url":"https://api.github.com/users/intermezzOS/received_events","type":"Organization","site_admin":false},"repo":{"id":44892115,"name":"kernel","full_name":"intermezzOS/kernel","owner":{"login":"intermezzOS","id":16422108,"avatar_url":"https://avatars.githubusercontent.com/u/16422108?v=3","gravatar_id":"","url":"https://api.github.com/users/intermezzOS","html_url":"https://github.com/intermezzOS","followers_url":"https://api.github.com/users/intermezzOS/followers","following_url":"https://api.github.com/users/intermezzOS/following{/other_user}","gists_url":"https://api.github.com/users/intermezzOS/gists{/gist_id}","starred_url":"https://api.github.com/users/intermezzOS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intermezzOS/subscriptions","organizations_url":"https://api.github.com/users/intermezzOS/orgs","repos_url":"https://api.github.com/users/intermezzOS/repos","events_url":"https://api.github.com/users/intermezzOS/events{/privacy}","received_events_url":"https://api.github.com/users/intermezzOS/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/intermezzOS/kernel","description":"A hobby operating system, in Rust","fork":false,"url":"https://api.github.com/repos/intermezzOS/kernel","forks_url":"https://api.github.com/repos/intermezzOS/kernel/forks","keys_url":"https://api.github.com/repos/intermezzOS/kernel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/intermezzOS/kernel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/intermezzOS/kernel/teams","hooks_url":"https://api.github.com/repos/intermezzOS/kernel/hooks","issue_events_url":"https://api.github.com/repos/intermezzOS/kernel/issues/events{/number}","events_url":"https://api.github.com/repos/intermezzOS/kernel/events","assignees_url":"https://api.github.com/repos/intermezzOS/kernel/assignees{/user}","branches_url":"https://api.github.com/repos/intermezzOS/kernel/branches{/branch}","tags_url":"https://api.github.com/repos/intermezzOS/kernel/tags","blobs_url":"https://api.github.com/repos/intermezzOS/kernel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/intermezzOS/kernel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/intermezzOS/kernel/git/refs{/sha}","trees_url":"https://api.github.com/repos/intermezzOS/kernel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/intermezzOS/kernel/statuses/{sha}","languages_url":"https://api.github.com/repos/intermezzOS/kernel/languages","stargazers_url":"https://api.github.com/repos/intermezzOS/kernel/stargazers","contributors_url":"https://api.github.com/repos/intermezzOS/kernel/contributors","subscribers_url":"https://api.github.com/repos/intermezzOS/kernel/subscribers","subscription_url":"https://api.github.com/repos/intermezzOS/kernel/subscription","commits_url":"https://api.github.com/repos/intermezzOS/kernel/commits{/sha}","git_commits_url":"https://api.github.com/repos/intermezzOS/kernel/git/commits{/sha}","comments_url":"https://api.github.com/repos/intermezzOS/kernel/comments{/number}","issue_comment_url":"https://api.github.com/repos/intermezzOS/kernel/issues/comments{/number}","contents_url":"https://api.github.com/repos/intermezzOS/kernel/contents/{+path}","compare_url":"https://api.github.com/repos/intermezzOS/kernel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/intermezzOS/kernel/merges","archive_url":"https://api.github.com/repos/intermezzOS/kernel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/intermezzOS/kernel/downloads","issues_url":"https://api.github.com/repos/intermezzOS/kernel/issues{/number}","pulls_url":"https://api.github.com/repos/intermezzOS/kernel/pulls{/number}","milestones_url":"https://api.github.com/repos/intermezzOS/kernel/milestones{/number}","notifications_url":"https://api.github.com/repos/intermezzOS/kernel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/intermezzOS/kernel/labels{/name}","releases_url":"https://api.github.com/repos/intermezzOS/kernel/releases{/id}","deployments_url":"https://api.github.com/repos/intermezzOS/kernel/deployments","created_at":"2015-10-25T01:36:53Z","updated_at":"2016-10-11T06:15:33Z","pushed_at":"2016-10-13T05:57:53Z","git_url":"git://github.com/intermezzOS/kernel.git","ssh_url":"git@github.com:intermezzOS/kernel.git","clone_url":"https://github.com/intermezzOS/kernel.git","svn_url":"https://github.com/intermezzOS/kernel","homepage":"http://intermezzos.github.io/","size":266,"stargazers_count":514,"watchers_count":514,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":40,"mirror_url":null,"open_issues_count":26,"forks":40,"open_issues":26,"watchers":514,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/90"},"html":{"href":"https://github.com/intermezzOS/kernel/pull/90"},"issue":{"href":"https://api.github.com/repos/intermezzOS/kernel/issues/90"},"comments":{"href":"https://api.github.com/repos/intermezzOS/kernel/issues/90/comments"},"review_comments":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/90/comments"},"review_comment":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/intermezzOS/kernel/pulls/90/commits"},"statuses":{"href":"https://api.github.com/repos/intermezzOS/kernel/statuses/15c9715ce10d3db5cac7c222cd08a1dfe67649f7"}}}}
{"actor":{"display_login":"dirk"}}