{"action":"created","issue":{"url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/25","labels_url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/25/labels{/name}","comments_url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/25/comments","events_url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/25/events","html_url":"https://github.com/raspberry-sharp/raspberry-sharp-io/pull/25","id":56763750,"number":25,"title":"Support for DS18B20 1-wire temperature sensor","user":{"login":"johnmwright","id":3373249,"avatar_url":"https://avatars.githubusercontent.com/u/3373249?v=3","gravatar_id":"","url":"https://api.github.com/users/johnmwright","html_url":"https://github.com/johnmwright","followers_url":"https://api.github.com/users/johnmwright/followers","following_url":"https://api.github.com/users/johnmwright/following{/other_user}","gists_url":"https://api.github.com/users/johnmwright/gists{/gist_id}","starred_url":"https://api.github.com/users/johnmwright/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnmwright/subscriptions","organizations_url":"https://api.github.com/users/johnmwright/orgs","repos_url":"https://api.github.com/users/johnmwright/repos","events_url":"https://api.github.com/users/johnmwright/events{/privacy}","received_events_url":"https://api.github.com/users/johnmwright/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-02-06T02:58:40Z","updated_at":"2015-02-06T08:08:56Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/pulls/25","html_url":"https://github.com/raspberry-sharp/raspberry-sharp-io/pull/25","diff_url":"https://github.com/raspberry-sharp/raspberry-sharp-io/pull/25.diff","patch_url":"https://github.com/raspberry-sharp/raspberry-sharp-io/pull/25.patch"},"body":"# DS18B20 support\r\n\r\nI've added support for the DS18B20 1-wire temperature sensor, based on the write-up found here; https://learn.adafruit.com/adafruits-raspberry-pi-lesson-11-ds18b20-temperature-sensing\r\n\r\n## Usage\r\nYou can see this in use [in my GaragePi project](https://github.com/johnmwright/GaragePi/blob/master/dotNet/GaragePi/TempSensorController.cs)\r\n\r\nUsage is similar to other components in this library, except that no pin information is needed since the 1-wire kernel driver does all the work for you.  You just need to provide the sensors unique serial number, or a zero-based index for the sensor to use.\r\n\r\nExample:\r\n\r\n        var sensorIndex = 0;\r\n        using( Ds18b20Connection _driver = new Ds18b20Connection(sensorIndex)\r\n        {\r\n             var tempF = _driver.GetTemperatureFahrenheit();\r\n        }\r\n\r\n## Prereq\r\n\r\nSince it does utilize the 1-wire kernel drivers, the user will need to use modprobe to load them ahead of running the app.  Note that the class constructor will include this in the exception message if it can't find the sensor requested.\r\n\r\n          modprobe w1-gpio\r\n          modprobe w1-therm\r\n      \r\n# GPIO Pin numbers\r\nThis also includes an update to the Pin enum to include GPIO numbering convention."},"comment":{"url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/comments/73200510","html_url":"https://github.com/raspberry-sharp/raspberry-sharp-io/pull/25#issuecomment-73200510","issue_url":"https://api.github.com/repos/raspberry-sharp/raspberry-sharp-io/issues/25","id":73200510,"user":{"login":"ebezine","id":2471245,"avatar_url":"https://avatars.githubusercontent.com/u/2471245?v=3","gravatar_id":"","url":"https://api.github.com/users/ebezine","html_url":"https://github.com/ebezine","followers_url":"https://api.github.com/users/ebezine/followers","following_url":"https://api.github.com/users/ebezine/following{/other_user}","gists_url":"https://api.github.com/users/ebezine/gists{/gist_id}","starred_url":"https://api.github.com/users/ebezine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebezine/subscriptions","organizations_url":"https://api.github.com/users/ebezine/orgs","repos_url":"https://api.github.com/users/ebezine/repos","events_url":"https://api.github.com/users/ebezine/events{/privacy}","received_events_url":"https://api.github.com/users/ebezine/received_events","type":"User","site_admin":false},"created_at":"2015-02-06T08:08:56Z","updated_at":"2015-02-06T08:08:56Z","body":"Hello,\r\n\r\nThank you for your contribution, that's a great job !\r\n\r\nUnfortunately I saw you added processor pin definitions to ConnectorPin.cs file, which is not intended for this purpose. Processor <> connector mappings vary depending on the Raspberry Pi model used and cannot be set in the same enum.\r\nThis is the purpose of ProcessorPin enum and the .ToProcessor extension method provided by the library.\r\n\r\nHence you do not require modifying the ConnectorPin.cs file in your pull request\r\n"}}