{"action":"created","issue":{"url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/26","labels_url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/26/labels{/name}","comments_url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/26/comments","events_url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/26/events","html_url":"https://github.com/roger-/pyrtlsdr/pull/26","id":101295841,"number":26,"title":"Add support for TCP communication","user":{"login":"nocarryr","id":1625941,"avatar_url":"https://avatars.githubusercontent.com/u/1625941?v=3","gravatar_id":"","url":"https://api.github.com/users/nocarryr","html_url":"https://github.com/nocarryr","followers_url":"https://api.github.com/users/nocarryr/followers","following_url":"https://api.github.com/users/nocarryr/following{/other_user}","gists_url":"https://api.github.com/users/nocarryr/gists{/gist_id}","starred_url":"https://api.github.com/users/nocarryr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nocarryr/subscriptions","organizations_url":"https://api.github.com/users/nocarryr/orgs","repos_url":"https://api.github.com/users/nocarryr/repos","events_url":"https://api.github.com/users/nocarryr/events{/privacy}","received_events_url":"https://api.github.com/users/nocarryr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":33,"created_at":"2015-08-16T20:20:45Z","updated_at":"2015-08-31T16:24:36Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/roger-/pyrtlsdr/pulls/26","html_url":"https://github.com/roger-/pyrtlsdr/pull/26","diff_url":"https://github.com/roger-/pyrtlsdr/pull/26.diff","patch_url":"https://github.com/roger-/pyrtlsdr/pull/26.patch"},"body":"This is currently a WIP, but I thought I might open it as a PR to get some collaboration as far as structure, etc is concerned.\r\n\r\nI've built subclasses for both servers and clients and so far have been able to successfully communicate between the two (setting sample_rate, center_freq, reading samples, etc)\r\n\r\nThe general idea I had was to allow a client computer or device (mobile perhaps) to utilize the library without the need for the underlying librtlsdr installed.  This would be a future step since all of it is required at import time, but could be easily refactored.\r\n\r\nI'd appreciate any feedback!"},"comment":{"url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/comments/136420466","html_url":"https://github.com/roger-/pyrtlsdr/pull/26#issuecomment-136420466","issue_url":"https://api.github.com/repos/roger-/pyrtlsdr/issues/26","id":136420466,"user":{"login":"nocarryr","id":1625941,"avatar_url":"https://avatars.githubusercontent.com/u/1625941?v=3","gravatar_id":"","url":"https://api.github.com/users/nocarryr","html_url":"https://github.com/nocarryr","followers_url":"https://api.github.com/users/nocarryr/followers","following_url":"https://api.github.com/users/nocarryr/following{/other_user}","gists_url":"https://api.github.com/users/nocarryr/gists{/gist_id}","starred_url":"https://api.github.com/users/nocarryr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nocarryr/subscriptions","organizations_url":"https://api.github.com/users/nocarryr/orgs","repos_url":"https://api.github.com/users/nocarryr/repos","events_url":"https://api.github.com/users/nocarryr/events{/privacy}","received_events_url":"https://api.github.com/users/nocarryr/received_events","type":"User","site_admin":false},"created_at":"2015-08-31T16:24:35Z","updated_at":"2015-08-31T16:24:35Z","body":"> BTW any idea what was causing the instability with the async support? I haven't tested that code much, so it may be fundamentally broken.\r\n\r\nI haven't tested it much in standalone either to be honest, that may be something to explore.\r\n\r\nI'm pretty sure the issues I was seeing during client/server testing was because I was trying to keep the SocketServer's [handler](https://docs.python.org/2.7/library/socketserver.html#requesthandler-objects) object open to keep feeding data to the client (which also held its socket open) until either:\r\n* A call was made to `cancel_read_async` or\r\n* The client/server connection was closed\r\n\r\nIt required another thread on the client side as well which can lead to all sorts of problems without proper exception handling and graceful shutdown.\r\n\r\nIt just seemed to be adding too much weight and error-prone code that needs a lot more scrutiny and extensive testing to want to put it into production."}}