{"action":"closed","issue":{"url":"https://api.github.com/repos/jwhitehorn/pi_piper/issues/24","repository_url":"https://api.github.com/repos/jwhitehorn/pi_piper","labels_url":"https://api.github.com/repos/jwhitehorn/pi_piper/issues/24/labels{/name}","comments_url":"https://api.github.com/repos/jwhitehorn/pi_piper/issues/24/comments","events_url":"https://api.github.com/repos/jwhitehorn/pi_piper/issues/24/events","html_url":"https://github.com/jwhitehorn/pi_piper/issues/24","id":37963593,"number":24,"title":".value always returns 0 in console","user":{"login":"foffer","id":1674650,"avatar_url":"https://avatars.githubusercontent.com/u/1674650?v=3","gravatar_id":"","url":"https://api.github.com/users/foffer","html_url":"https://github.com/foffer","followers_url":"https://api.github.com/users/foffer/followers","following_url":"https://api.github.com/users/foffer/following{/other_user}","gists_url":"https://api.github.com/users/foffer/gists{/gist_id}","starred_url":"https://api.github.com/users/foffer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foffer/subscriptions","organizations_url":"https://api.github.com/users/foffer/orgs","repos_url":"https://api.github.com/users/foffer/repos","events_url":"https://api.github.com/users/foffer/events{/privacy}","received_events_url":"https://api.github.com/users/foffer/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2014-07-16T09:26:10Z","updated_at":"2016-02-08T05:21:12Z","closed_at":"2016-02-08T05:21:12Z","body":"In Ruby 2.1.2 on the Raspberry Pi B model using the Pry console (tested in IRB as well)\r\nDoing this: `pin = PiPiper::Pin.new(:pin => 18, :direction => :out)` correctly initialises the pin. `pin.on / .off` works correctly. But when calling `pin.value` it always returns 0. I've tried it using the `update_value` method instead of the on / off method, but the `.value` return is the same.\r\n\r\n`[3] pry(main)> pin = PiPiper::Pin.new(:pin => 18, :direction => :out)`\r\n`=> #<PiPiper::Pin:0x1cdd648 @direction=:out, @invert=false, @last_value=nil, @pin=18, @pull=:off, @trigger=:both, @value=0>`\r\n`[4] pry(main)> pin.value`\r\n`=> 0`\r\n`[5] pry(main)> pin.update_value(1)`\r\n`=> 1`\r\n`[6] pry(main)> pin.value`\r\n`=> 0`\r\n`[7] pry(main)>`"}}