{"action":"created","comment":{"url":"https://api.github.com/repos/uw-midsun/firmware/pulls/comments/190771815","pull_request_review_id":123221981,"id":190771815,"diff_hunk":"@@ -0,0 +1,76 @@\n+#pragma once\n+\n+// This module is used to parse and represent NMEA data. Used in the GPS module\n+\n+#include <stdint.h>\n+#include <stdio.h>\n+#include \"status.h\"\n+\n+// This enum contains the list of NMEA sentences (not all of then are supported yet)\n+// because they do not contain useful information\n+typedef enum {\n+  NMEA_UNKNOWN = 0,\n+  NMEA_GGA,\n+  NMEA_GLL,\n+  NMEA_GSA,\n+  NMEA_GSV,\n+  NMEA_RMC,\n+  NMEA_VTG,\n+  NMEA_NUM_MESSAGE_IDS\n+} NMEA_MESSAGE_ID;\n+\n+// This is to get the number of fields in a sentence for array allocation\n+static const size_t s_nmea_message_num_fields[] = { 0, 16, 9, 11, 13, 14, 14, 10 };\n+\n+typedef struct {\n+  uint32_t hh;   // Hours\n+  uint32_t mm;   // Minutes\n+  uint32_t ss;   // Seconds\n+  uint32_t sss;  // Milliseconds\n+} nmea_utc_time;\n+\n+// Representation of longitude or latitude\n+// https://en.wikipedia.org/wiki/Longitude\n+typedef struct {\n+  uint32_t degrees;\n+  uint32_t minutes;\n+  uint32_t fraction;\n+} nmea_coord;\n+// Info passed from the GPS chip should be dropped into this struct (more fields\n+// coming soon)\n+\n+typedef struct {\n+  uint32_t position_fix;  // 0 = invalid, (1,2,6) = valid, all else is undefined","path":"projects/telemetry/inc/nmea.h","position":43,"original_position":43,"commit_id":"1de6dd9ef2e17eb5d1b054b54efe7800da02c6b8","original_commit_id":"1de6dd9ef2e17eb5d1b054b54efe7800da02c6b8","user":{"login":"mikzharov","id":8266317,"avatar_url":"https://avatars2.githubusercontent.com/u/8266317?v=4","gravatar_id":"","url":"https://api.github.com/users/mikzharov","html_url":"https://github.com/mikzharov","followers_url":"https://api.github.com/users/mikzharov/followers","following_url":"https://api.github.com/users/mikzharov/following{/other_user}","gists_url":"https://api.github.com/users/mikzharov/gists{/gist_id}","starred_url":"https://api.github.com/users/mikzharov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikzharov/subscriptions","organizations_url":"https://api.github.com/users/mikzharov/orgs","repos_url":"https://api.github.com/users/mikzharov/repos","events_url":"https://api.github.com/users/mikzharov/events{/privacy}","received_events_url":"https://api.github.com/users/mikzharov/received_events","type":"User","site_admin":false},"body":"Actually some of it may be useful, will use and enum","created_at":"2018-05-25T01:31:03Z","updated_at":"2018-05-25T01:31:03Z","html_url":"https://github.com/uw-midsun/firmware/pull/191#discussion_r190771815","pull_request_url":"https://api.github.com/repos/uw-midsun/firmware/pulls/191","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/comments/190771815"},"html":{"href":"https://github.com/uw-midsun/firmware/pull/191#discussion_r190771815"},"pull_request":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/191"}},"in_reply_to_id":189480246},"pull_request":{"url":"https://api.github.com/repos/uw-midsun/firmware/pulls/191","id":189209729,"html_url":"https://github.com/uw-midsun/firmware/pull/191","diff_url":"https://github.com/uw-midsun/firmware/pull/191.diff","patch_url":"https://github.com/uw-midsun/firmware/pull/191.patch","issue_url":"https://api.github.com/repos/uw-midsun/firmware/issues/191","number":191,"state":"open","locked":false,"title":"ELEC-71: Adding NMEA parser","user":{"login":"mikzharov","id":8266317,"avatar_url":"https://avatars2.githubusercontent.com/u/8266317?v=4","gravatar_id":"","url":"https://api.github.com/users/mikzharov","html_url":"https://github.com/mikzharov","followers_url":"https://api.github.com/users/mikzharov/followers","following_url":"https://api.github.com/users/mikzharov/following{/other_user}","gists_url":"https://api.github.com/users/mikzharov/gists{/gist_id}","starred_url":"https://api.github.com/users/mikzharov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikzharov/subscriptions","organizations_url":"https://api.github.com/users/mikzharov/orgs","repos_url":"https://api.github.com/users/mikzharov/repos","events_url":"https://api.github.com/users/mikzharov/events{/privacy}","received_events_url":"https://api.github.com/users/mikzharov/received_events","type":"User","site_admin":false},"body":"Adding a NMEA parser for the GPS driver","created_at":"2018-05-19T22:34:18Z","updated_at":"2018-05-25T01:31:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"17e12f0eb2c85b580eb1287126b342cc96d26f41","assignee":null,"assignees":[],"requested_reviewers":[{"login":"ckitagawa","id":9539007,"avatar_url":"https://avatars0.githubusercontent.com/u/9539007?v=4","gravatar_id":"","url":"https://api.github.com/users/ckitagawa","html_url":"https://github.com/ckitagawa","followers_url":"https://api.github.com/users/ckitagawa/followers","following_url":"https://api.github.com/users/ckitagawa/following{/other_user}","gists_url":"https://api.github.com/users/ckitagawa/gists{/gist_id}","starred_url":"https://api.github.com/users/ckitagawa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ckitagawa/subscriptions","organizations_url":"https://api.github.com/users/ckitagawa/orgs","repos_url":"https://api.github.com/users/ckitagawa/repos","events_url":"https://api.github.com/users/ckitagawa/events{/privacy}","received_events_url":"https://api.github.com/users/ckitagawa/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/uw-midsun/firmware/pulls/191/commits","review_comments_url":"https://api.github.com/repos/uw-midsun/firmware/pulls/191/comments","review_comment_url":"https://api.github.com/repos/uw-midsun/firmware/pulls/comments{/number}","comments_url":"https://api.github.com/repos/uw-midsun/firmware/issues/191/comments","statuses_url":"https://api.github.com/repos/uw-midsun/firmware/statuses/1de6dd9ef2e17eb5d1b054b54efe7800da02c6b8","head":{"label":"uw-midsun:elec_71_nmea","ref":"elec_71_nmea","sha":"1de6dd9ef2e17eb5d1b054b54efe7800da02c6b8","user":{"login":"uw-midsun","id":14828575,"avatar_url":"https://avatars1.githubusercontent.com/u/14828575?v=4","gravatar_id":"","url":"https://api.github.com/users/uw-midsun","html_url":"https://github.com/uw-midsun","followers_url":"https://api.github.com/users/uw-midsun/followers","following_url":"https://api.github.com/users/uw-midsun/following{/other_user}","gists_url":"https://api.github.com/users/uw-midsun/gists{/gist_id}","starred_url":"https://api.github.com/users/uw-midsun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uw-midsun/subscriptions","organizations_url":"https://api.github.com/users/uw-midsun/orgs","repos_url":"https://api.github.com/users/uw-midsun/repos","events_url":"https://api.github.com/users/uw-midsun/events{/privacy}","received_events_url":"https://api.github.com/users/uw-midsun/received_events","type":"Organization","site_admin":false},"repo":{"id":69197028,"name":"firmware","full_name":"uw-midsun/firmware","owner":{"login":"uw-midsun","id":14828575,"avatar_url":"https://avatars1.githubusercontent.com/u/14828575?v=4","gravatar_id":"","url":"https://api.github.com/users/uw-midsun","html_url":"https://github.com/uw-midsun","followers_url":"https://api.github.com/users/uw-midsun/followers","following_url":"https://api.github.com/users/uw-midsun/following{/other_user}","gists_url":"https://api.github.com/users/uw-midsun/gists{/gist_id}","starred_url":"https://api.github.com/users/uw-midsun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uw-midsun/subscriptions","organizations_url":"https://api.github.com/users/uw-midsun/orgs","repos_url":"https://api.github.com/users/uw-midsun/repos","events_url":"https://api.github.com/users/uw-midsun/events{/privacy}","received_events_url":"https://api.github.com/users/uw-midsun/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/uw-midsun/firmware","description":"Firmware for MSXII","fork":false,"url":"https://api.github.com/repos/uw-midsun/firmware","forks_url":"https://api.github.com/repos/uw-midsun/firmware/forks","keys_url":"https://api.github.com/repos/uw-midsun/firmware/keys{/key_id}","collaborators_url":"https://api.github.com/repos/uw-midsun/firmware/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/uw-midsun/firmware/teams","hooks_url":"https://api.github.com/repos/uw-midsun/firmware/hooks","issue_events_url":"https://api.github.com/repos/uw-midsun/firmware/issues/events{/number}","events_url":"https://api.github.com/repos/uw-midsun/firmware/events","assignees_url":"https://api.github.com/repos/uw-midsun/firmware/assignees{/user}","branches_url":"https://api.github.com/repos/uw-midsun/firmware/branches{/branch}","tags_url":"https://api.github.com/repos/uw-midsun/firmware/tags","blobs_url":"https://api.github.com/repos/uw-midsun/firmware/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/uw-midsun/firmware/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/uw-midsun/firmware/git/refs{/sha}","trees_url":"https://api.github.com/repos/uw-midsun/firmware/git/trees{/sha}","statuses_url":"https://api.github.com/repos/uw-midsun/firmware/statuses/{sha}","languages_url":"https://api.github.com/repos/uw-midsun/firmware/languages","stargazers_url":"https://api.github.com/repos/uw-midsun/firmware/stargazers","contributors_url":"https://api.github.com/repos/uw-midsun/firmware/contributors","subscribers_url":"https://api.github.com/repos/uw-midsun/firmware/subscribers","subscription_url":"https://api.github.com/repos/uw-midsun/firmware/subscription","commits_url":"https://api.github.com/repos/uw-midsun/firmware/commits{/sha}","git_commits_url":"https://api.github.com/repos/uw-midsun/firmware/git/commits{/sha}","comments_url":"https://api.github.com/repos/uw-midsun/firmware/comments{/number}","issue_comment_url":"https://api.github.com/repos/uw-midsun/firmware/issues/comments{/number}","contents_url":"https://api.github.com/repos/uw-midsun/firmware/contents/{+path}","compare_url":"https://api.github.com/repos/uw-midsun/firmware/compare/{base}...{head}","merges_url":"https://api.github.com/repos/uw-midsun/firmware/merges","archive_url":"https://api.github.com/repos/uw-midsun/firmware/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/uw-midsun/firmware/downloads","issues_url":"https://api.github.com/repos/uw-midsun/firmware/issues{/number}","pulls_url":"https://api.github.com/repos/uw-midsun/firmware/pulls{/number}","milestones_url":"https://api.github.com/repos/uw-midsun/firmware/milestones{/number}","notifications_url":"https://api.github.com/repos/uw-midsun/firmware/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/uw-midsun/firmware/labels{/name}","releases_url":"https://api.github.com/repos/uw-midsun/firmware/releases{/id}","deployments_url":"https://api.github.com/repos/uw-midsun/firmware/deployments","created_at":"2016-09-25T23:38:58Z","updated_at":"2018-05-23T01:14:06Z","pushed_at":"2018-05-25T00:32:28Z","git_url":"git://github.com/uw-midsun/firmware.git","ssh_url":"git@github.com:uw-midsun/firmware.git","clone_url":"https://github.com/uw-midsun/firmware.git","svn_url":"https://github.com/uw-midsun/firmware","homepage":"","size":2961,"stargazers_count":3,"watchers_count":3,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":12,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":2,"open_issues":12,"watchers":3,"default_branch":"master"}},"base":{"label":"uw-midsun:master","ref":"master","sha":"57339db57cf9023db2946f595e39a755e9aec0be","user":{"login":"uw-midsun","id":14828575,"avatar_url":"https://avatars1.githubusercontent.com/u/14828575?v=4","gravatar_id":"","url":"https://api.github.com/users/uw-midsun","html_url":"https://github.com/uw-midsun","followers_url":"https://api.github.com/users/uw-midsun/followers","following_url":"https://api.github.com/users/uw-midsun/following{/other_user}","gists_url":"https://api.github.com/users/uw-midsun/gists{/gist_id}","starred_url":"https://api.github.com/users/uw-midsun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uw-midsun/subscriptions","organizations_url":"https://api.github.com/users/uw-midsun/orgs","repos_url":"https://api.github.com/users/uw-midsun/repos","events_url":"https://api.github.com/users/uw-midsun/events{/privacy}","received_events_url":"https://api.github.com/users/uw-midsun/received_events","type":"Organization","site_admin":false},"repo":{"id":69197028,"name":"firmware","full_name":"uw-midsun/firmware","owner":{"login":"uw-midsun","id":14828575,"avatar_url":"https://avatars1.githubusercontent.com/u/14828575?v=4","gravatar_id":"","url":"https://api.github.com/users/uw-midsun","html_url":"https://github.com/uw-midsun","followers_url":"https://api.github.com/users/uw-midsun/followers","following_url":"https://api.github.com/users/uw-midsun/following{/other_user}","gists_url":"https://api.github.com/users/uw-midsun/gists{/gist_id}","starred_url":"https://api.github.com/users/uw-midsun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/uw-midsun/subscriptions","organizations_url":"https://api.github.com/users/uw-midsun/orgs","repos_url":"https://api.github.com/users/uw-midsun/repos","events_url":"https://api.github.com/users/uw-midsun/events{/privacy}","received_events_url":"https://api.github.com/users/uw-midsun/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/uw-midsun/firmware","description":"Firmware for MSXII","fork":false,"url":"https://api.github.com/repos/uw-midsun/firmware","forks_url":"https://api.github.com/repos/uw-midsun/firmware/forks","keys_url":"https://api.github.com/repos/uw-midsun/firmware/keys{/key_id}","collaborators_url":"https://api.github.com/repos/uw-midsun/firmware/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/uw-midsun/firmware/teams","hooks_url":"https://api.github.com/repos/uw-midsun/firmware/hooks","issue_events_url":"https://api.github.com/repos/uw-midsun/firmware/issues/events{/number}","events_url":"https://api.github.com/repos/uw-midsun/firmware/events","assignees_url":"https://api.github.com/repos/uw-midsun/firmware/assignees{/user}","branches_url":"https://api.github.com/repos/uw-midsun/firmware/branches{/branch}","tags_url":"https://api.github.com/repos/uw-midsun/firmware/tags","blobs_url":"https://api.github.com/repos/uw-midsun/firmware/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/uw-midsun/firmware/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/uw-midsun/firmware/git/refs{/sha}","trees_url":"https://api.github.com/repos/uw-midsun/firmware/git/trees{/sha}","statuses_url":"https://api.github.com/repos/uw-midsun/firmware/statuses/{sha}","languages_url":"https://api.github.com/repos/uw-midsun/firmware/languages","stargazers_url":"https://api.github.com/repos/uw-midsun/firmware/stargazers","contributors_url":"https://api.github.com/repos/uw-midsun/firmware/contributors","subscribers_url":"https://api.github.com/repos/uw-midsun/firmware/subscribers","subscription_url":"https://api.github.com/repos/uw-midsun/firmware/subscription","commits_url":"https://api.github.com/repos/uw-midsun/firmware/commits{/sha}","git_commits_url":"https://api.github.com/repos/uw-midsun/firmware/git/commits{/sha}","comments_url":"https://api.github.com/repos/uw-midsun/firmware/comments{/number}","issue_comment_url":"https://api.github.com/repos/uw-midsun/firmware/issues/comments{/number}","contents_url":"https://api.github.com/repos/uw-midsun/firmware/contents/{+path}","compare_url":"https://api.github.com/repos/uw-midsun/firmware/compare/{base}...{head}","merges_url":"https://api.github.com/repos/uw-midsun/firmware/merges","archive_url":"https://api.github.com/repos/uw-midsun/firmware/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/uw-midsun/firmware/downloads","issues_url":"https://api.github.com/repos/uw-midsun/firmware/issues{/number}","pulls_url":"https://api.github.com/repos/uw-midsun/firmware/pulls{/number}","milestones_url":"https://api.github.com/repos/uw-midsun/firmware/milestones{/number}","notifications_url":"https://api.github.com/repos/uw-midsun/firmware/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/uw-midsun/firmware/labels{/name}","releases_url":"https://api.github.com/repos/uw-midsun/firmware/releases{/id}","deployments_url":"https://api.github.com/repos/uw-midsun/firmware/deployments","created_at":"2016-09-25T23:38:58Z","updated_at":"2018-05-23T01:14:06Z","pushed_at":"2018-05-25T00:32:28Z","git_url":"git://github.com/uw-midsun/firmware.git","ssh_url":"git@github.com:uw-midsun/firmware.git","clone_url":"https://github.com/uw-midsun/firmware.git","svn_url":"https://github.com/uw-midsun/firmware","homepage":"","size":2961,"stargazers_count":3,"watchers_count":3,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":12,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":2,"open_issues":12,"watchers":3,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/191"},"html":{"href":"https://github.com/uw-midsun/firmware/pull/191"},"issue":{"href":"https://api.github.com/repos/uw-midsun/firmware/issues/191"},"comments":{"href":"https://api.github.com/repos/uw-midsun/firmware/issues/191/comments"},"review_comments":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/191/comments"},"review_comment":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/uw-midsun/firmware/pulls/191/commits"},"statuses":{"href":"https://api.github.com/repos/uw-midsun/firmware/statuses/1de6dd9ef2e17eb5d1b054b54efe7800da02c6b8"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"mikzharov"}}