{"action":"created","comment":{"url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/comments/94188013","pull_request_review_id":14717670,"id":94188013,"diff_hunk":"@@ -0,0 +1,293 @@\n+/* JEZDZCY JARZYNOWEJ - CAN SAT 2016/17\n+ * GROUND STATION RECEIVER \n+ * CONNECTIONS:\n+ * A4 - barometer SCA\n+ * A5 - barometrer SCL\n+ * 2 - radio TX\n+ * 3 - radio RX\n+ * 10 - micrSD CS\n+ * 11 - microSD MOSI\n+ * 12 - microSD MISO\n+ * 13 - microSd SCLK\n+ */\n+#include <LPS331.h>\n+#include <SPI.h>\n+#include <SD.h>\n+#include <Wire.h>\n+#include <SoftwareSerial.h>\n+\n+SoftwareSerial radioSerial(2, 3);\n+\n+int startTime;\n+const int serialDelay = 1000;\n+const String autoSaveTime = \"60\";\n+\n+class TheTime{\n+  public:\n+    int inHour;\n+    int inMinute;\n+    int inSecond;\n+    int inMilisecond;\n+    \n+    int hour;\n+    int minute;\n+    int second;\n+    unsigned long milisecond;\n+    \n+    void calculate(){\n+      while(milisecond >= 1000){\n+        second++;\n+        milisecond -= 1000;\n+      }\n+      while(second >= 60){\n+        minute++;\n+        second -= 60;\n+      }\n+      while(minute >= 60){\n+        hour++;\n+        second -= 60;\n+      }\n+    }\n+\n+    void clearTimes(){\n+      hour = inHour;\n+      minute = inMinute;\n+      second = inSecond;\n+      milisecond = inMilisecond;\n+    }\n+  \n+    void calculateTime(){\n+      clearTimes();\n+      milisecond = inMilisecond + millis() - startTime;\n+      calculate();\n+    }\n+};\n+\n+const int chipSelect = 10;\n+File usedFile;\n+\n+LPS331 sensor;\n+\n+TheTime theTime;\n+\n+String sdError = \"SDERROR\";","path":"code/GroundStation.ino","position":73,"original_position":73,"commit_id":"2dc84a5ecb524800a2b67d4ac6831f213015daef","original_commit_id":"2dc84a5ecb524800a2b67d4ac6831f213015daef","user":{"login":"evemorgen","id":7932772,"avatar_url":"https://avatars.githubusercontent.com/u/7932772?v=3","gravatar_id":"","url":"https://api.github.com/users/evemorgen","html_url":"https://github.com/evemorgen","followers_url":"https://api.github.com/users/evemorgen/followers","following_url":"https://api.github.com/users/evemorgen/following{/other_user}","gists_url":"https://api.github.com/users/evemorgen/gists{/gist_id}","starred_url":"https://api.github.com/users/evemorgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evemorgen/subscriptions","organizations_url":"https://api.github.com/users/evemorgen/orgs","repos_url":"https://api.github.com/users/evemorgen/repos","events_url":"https://api.github.com/users/evemorgen/events{/privacy}","received_events_url":"https://api.github.com/users/evemorgen/received_events","type":"User","site_admin":false},"body":"To można zrobić jako dyrektywy preprocesora, wyjdzie taniej pamięciowo. W sensie #define SDERROR \"SDERROR\" czy coś podobnego","created_at":"2016-12-29T22:38:03Z","updated_at":"2016-12-29T22:49:16Z","html_url":"https://github.com/evemorgen/PuszkoSatelita/pull/12#discussion_r94188013","pull_request_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/comments/94188013"},"html":{"href":"https://github.com/evemorgen/PuszkoSatelita/pull/12#discussion_r94188013"},"pull_request":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12","id":99696965,"html_url":"https://github.com/evemorgen/PuszkoSatelita/pull/12","diff_url":"https://github.com/evemorgen/PuszkoSatelita/pull/12.diff","patch_url":"https://github.com/evemorgen/PuszkoSatelita/pull/12.patch","issue_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/12","number":12,"state":"open","locked":false,"title":"Kod Stacji Bazowej","user":{"login":"jezdzcyjarzynowej","id":22419462,"avatar_url":"https://avatars.githubusercontent.com/u/22419462?v=3","gravatar_id":"","url":"https://api.github.com/users/jezdzcyjarzynowej","html_url":"https://github.com/jezdzcyjarzynowej","followers_url":"https://api.github.com/users/jezdzcyjarzynowej/followers","following_url":"https://api.github.com/users/jezdzcyjarzynowej/following{/other_user}","gists_url":"https://api.github.com/users/jezdzcyjarzynowej/gists{/gist_id}","starred_url":"https://api.github.com/users/jezdzcyjarzynowej/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jezdzcyjarzynowej/subscriptions","organizations_url":"https://api.github.com/users/jezdzcyjarzynowej/orgs","repos_url":"https://api.github.com/users/jezdzcyjarzynowej/repos","events_url":"https://api.github.com/users/jezdzcyjarzynowej/events{/privacy}","received_events_url":"https://api.github.com/users/jezdzcyjarzynowej/received_events","type":"User","site_admin":false},"body":"Kod Stacji Bazowej, testy dla radia","created_at":"2016-12-29T20:47:29Z","updated_at":"2016-12-29T22:49:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"786b4588ff972b9635cf882ef6c09cd17984f8d3","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12/commits","review_comments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12/comments","review_comment_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/comments{/number}","comments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/12/comments","statuses_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/statuses/2dc84a5ecb524800a2b67d4ac6831f213015daef","head":{"label":"evemorgen:GS&R","ref":"GS&R","sha":"2dc84a5ecb524800a2b67d4ac6831f213015daef","user":{"login":"evemorgen","id":7932772,"avatar_url":"https://avatars.githubusercontent.com/u/7932772?v=3","gravatar_id":"","url":"https://api.github.com/users/evemorgen","html_url":"https://github.com/evemorgen","followers_url":"https://api.github.com/users/evemorgen/followers","following_url":"https://api.github.com/users/evemorgen/following{/other_user}","gists_url":"https://api.github.com/users/evemorgen/gists{/gist_id}","starred_url":"https://api.github.com/users/evemorgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evemorgen/subscriptions","organizations_url":"https://api.github.com/users/evemorgen/orgs","repos_url":"https://api.github.com/users/evemorgen/repos","events_url":"https://api.github.com/users/evemorgen/events{/privacy}","received_events_url":"https://api.github.com/users/evemorgen/received_events","type":"User","site_admin":false},"repo":{"id":69119724,"name":"PuszkoSatelita","full_name":"evemorgen/PuszkoSatelita","owner":{"login":"evemorgen","id":7932772,"avatar_url":"https://avatars.githubusercontent.com/u/7932772?v=3","gravatar_id":"","url":"https://api.github.com/users/evemorgen","html_url":"https://github.com/evemorgen","followers_url":"https://api.github.com/users/evemorgen/followers","following_url":"https://api.github.com/users/evemorgen/following{/other_user}","gists_url":"https://api.github.com/users/evemorgen/gists{/gist_id}","starred_url":"https://api.github.com/users/evemorgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evemorgen/subscriptions","organizations_url":"https://api.github.com/users/evemorgen/orgs","repos_url":"https://api.github.com/users/evemorgen/repos","events_url":"https://api.github.com/users/evemorgen/events{/privacy}","received_events_url":"https://api.github.com/users/evemorgen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/evemorgen/PuszkoSatelita","description":null,"fork":false,"url":"https://api.github.com/repos/evemorgen/PuszkoSatelita","forks_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/forks","keys_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/keys{/key_id}","collaborators_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/teams","hooks_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/hooks","issue_events_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/events{/number}","events_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/events","assignees_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/assignees{/user}","branches_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/branches{/branch}","tags_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/tags","blobs_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/refs{/sha}","trees_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/trees{/sha}","statuses_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/statuses/{sha}","languages_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/languages","stargazers_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/stargazers","contributors_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/contributors","subscribers_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/subscribers","subscription_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/subscription","commits_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/commits{/sha}","git_commits_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/commits{/sha}","comments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/comments{/number}","issue_comment_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/comments{/number}","contents_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/contents/{+path}","compare_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/compare/{base}...{head}","merges_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/merges","archive_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/downloads","issues_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues{/number}","pulls_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls{/number}","milestones_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/milestones{/number}","notifications_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/labels{/name}","releases_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/releases{/id}","deployments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/deployments","created_at":"2016-09-24T18:16:13Z","updated_at":"2016-12-07T19:47:32Z","pushed_at":"2016-12-29T20:47:29Z","git_url":"git://github.com/evemorgen/PuszkoSatelita.git","ssh_url":"git@github.com:evemorgen/PuszkoSatelita.git","clone_url":"https://github.com/evemorgen/PuszkoSatelita.git","svn_url":"https://github.com/evemorgen/PuszkoSatelita","homepage":null,"size":25327,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"evemorgen:master","ref":"master","sha":"a4d281a658e3e9d2a077c4c4e4eca22866f14f75","user":{"login":"evemorgen","id":7932772,"avatar_url":"https://avatars.githubusercontent.com/u/7932772?v=3","gravatar_id":"","url":"https://api.github.com/users/evemorgen","html_url":"https://github.com/evemorgen","followers_url":"https://api.github.com/users/evemorgen/followers","following_url":"https://api.github.com/users/evemorgen/following{/other_user}","gists_url":"https://api.github.com/users/evemorgen/gists{/gist_id}","starred_url":"https://api.github.com/users/evemorgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evemorgen/subscriptions","organizations_url":"https://api.github.com/users/evemorgen/orgs","repos_url":"https://api.github.com/users/evemorgen/repos","events_url":"https://api.github.com/users/evemorgen/events{/privacy}","received_events_url":"https://api.github.com/users/evemorgen/received_events","type":"User","site_admin":false},"repo":{"id":69119724,"name":"PuszkoSatelita","full_name":"evemorgen/PuszkoSatelita","owner":{"login":"evemorgen","id":7932772,"avatar_url":"https://avatars.githubusercontent.com/u/7932772?v=3","gravatar_id":"","url":"https://api.github.com/users/evemorgen","html_url":"https://github.com/evemorgen","followers_url":"https://api.github.com/users/evemorgen/followers","following_url":"https://api.github.com/users/evemorgen/following{/other_user}","gists_url":"https://api.github.com/users/evemorgen/gists{/gist_id}","starred_url":"https://api.github.com/users/evemorgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evemorgen/subscriptions","organizations_url":"https://api.github.com/users/evemorgen/orgs","repos_url":"https://api.github.com/users/evemorgen/repos","events_url":"https://api.github.com/users/evemorgen/events{/privacy}","received_events_url":"https://api.github.com/users/evemorgen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/evemorgen/PuszkoSatelita","description":null,"fork":false,"url":"https://api.github.com/repos/evemorgen/PuszkoSatelita","forks_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/forks","keys_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/keys{/key_id}","collaborators_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/teams","hooks_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/hooks","issue_events_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/events{/number}","events_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/events","assignees_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/assignees{/user}","branches_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/branches{/branch}","tags_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/tags","blobs_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/refs{/sha}","trees_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/trees{/sha}","statuses_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/statuses/{sha}","languages_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/languages","stargazers_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/stargazers","contributors_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/contributors","subscribers_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/subscribers","subscription_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/subscription","commits_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/commits{/sha}","git_commits_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/git/commits{/sha}","comments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/comments{/number}","issue_comment_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/comments{/number}","contents_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/contents/{+path}","compare_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/compare/{base}...{head}","merges_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/merges","archive_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/downloads","issues_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues{/number}","pulls_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls{/number}","milestones_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/milestones{/number}","notifications_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/labels{/name}","releases_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/releases{/id}","deployments_url":"https://api.github.com/repos/evemorgen/PuszkoSatelita/deployments","created_at":"2016-09-24T18:16:13Z","updated_at":"2016-12-07T19:47:32Z","pushed_at":"2016-12-29T20:47:29Z","git_url":"git://github.com/evemorgen/PuszkoSatelita.git","ssh_url":"git@github.com:evemorgen/PuszkoSatelita.git","clone_url":"https://github.com/evemorgen/PuszkoSatelita.git","svn_url":"https://github.com/evemorgen/PuszkoSatelita","homepage":null,"size":25327,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12"},"html":{"href":"https://github.com/evemorgen/PuszkoSatelita/pull/12"},"issue":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/12"},"comments":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/evemorgen/PuszkoSatelita/statuses/2dc84a5ecb524800a2b67d4ac6831f213015daef"}}}}
{"actor":{"display_login":"evemorgen"}}