{ "info": { "author": "James Stewart", "author_email": "jstewart101@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "TOSR0x\n======================\n\nA Python module for communicating with 'TOSR0x' relay controllers available at [tinyosshop.com](http://www.tinyosshop.com/index.php?route=product/product&product_id=365) and other online retailers.\n\n*Note: as of v0.6.0 this module only supports Python 3.4+.*\n\nSupported Hardware\n----------------------\n\n* [TOSR0x USB 2-8 relay](http://www.tinyosshop.com/index.php?route=product/category&path=141_142)\n* [TOSR0x WiFi 2-8 relay](http://www.tinyosshop.com/index.php?route=product/category&path=141_143)\n* [LazyBone WiFi single relay](http://www.tinyosshop.com/index.php?route=product/category&path=141_129)\n\nFunctionality\n----------------------\n\n* Detect TOSR0x USB and WiFi devices.\n* Set relay states.\n* Query relay states.\n* Query temperature (on supported models).\n\nRequirements\n----------------------\n\n* Python serial module (should be installed by default)\n\nInstallation\n----------------------\n\nUse setup.py:\n\n python setup.py install\n\nIf using Debian or a derivative (Ubuntu) additional USB permissions may be required:\n\n Add the user to the 'dialout' group:\n\n $ sudo usermod -G dialout -a \n\n Add a udev rules file to allow access to usb devices:\n\n $ cat /etc/udev/rules.d/50-usb.rules\n # allow access to usb devices for users in dialout group\n SUBSYSTEM==\"usb\", MODE=\"0666\", GROUP=\"dialout\"\n\nUsage\n----------------------\n\nCall the handler function to return a list of tosr0x objects:\n\n >import tosr0x\n >th = tosr0x.handler()\n\n Testing USB serial device on /dev/ttyUSB0\n Testing USB serial device on /dev/ttyUSB1\n Testing USB serial device on /dev/ttyUSB2\n Testing USB serial device on /dev/ttyUSB3\n TOSR0x device found on /dev/ttyUSB3\n\n >myTosr0x = th[0]\n >print myT0sr0x\n\n \n\nBy default the handler scans all USB ports for compatible tosr0x devices. You\ncan also specify a range of ports to scan:\n\n >th = tosr0x.handler(devicePath=['/dev/ttyUSB3'])\n\n Testing USB serial device on /dev/ttyUSB3\n TOSR0x device found on /dev/ttyUSB3\n\nUsually all relays on the module are cycled at initialisation to determine the\nrelay count. You can specify a relay count to prevent this:\n\n >th = tosr0x.handler(devicePath=['/dev/ttyUSB3'], relayCount=4)\n\n Testing USB serial device on /dev/ttyUSB3\n TOSR0x device found on /dev/ttyUSB3\n\nIt is also possible to use the class directly without using the handler:\n\n FOR SERIAL:\n >import serial\n >import tosr0x\n >sd=serial.Serial('/dev/ttyUSB0', timeout=0.1)\n >myTosr0x=tosr0x.relayModule(sd) #Num relays not specified in this example\n\n FOR WIFI:\n >import tosr0x\n >myTosr0x = tosr0x.relayModule( ('192.168.1.2',2000), 2) #Module of 2 relays\n\nSet relay states to either 0 or 1:\n\n >myTosr0x.set_relay_position(1,1)\n True\n\n >myTosr0x.set_relay_position(2,0)\n True\n\n(Note: relay numbering starts at 1. Set the state of all relays by using relay number 0.)\n\nGet relay positions, (returned as a dict {relay : state}):\n\n >myTosr0x.get_relay_positions()\n {1: 1, 2: 0}\n\nGet Ambient Temperaure n Celsius degree for modules supporting a temperature probe:\n\n >myTosr0x.get_temperature()\n 23.94\n\nProjects\n----------------------\n\n* James Stewart (@amorphic) uses to _tosr0x_ to implement an Environmental Controller in [braubuddy](http://braubuddy.org), a temperature monitoring framework.\n* Alex Roche (@alexroche) is using _tosr0x_ with WIFI option to control blinds through openremote controller running on a Raspberry Pi.", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/amorphic/tosr0x", "keywords": "", "license": "LICENSE.txt", "maintainer": "", "maintainer_email": "", "name": "tosr0x", "package_url": "https://pypi.org/project/tosr0x/", "platform": "", "project_url": "https://pypi.org/project/tosr0x/", "project_urls": { "Homepage": "https://github.com/amorphic/tosr0x" }, "release_url": "https://pypi.org/project/tosr0x/0.6.4/", "requires_dist": null, "requires_python": "", "summary": "An interface to tinyos.com TOSR0x relay modules.", "version": "0.6.4" }, "last_serial": 5963003, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "4e6cae572c9f5b717eda051109262ef5", "sha256": "958ead002fb19cd82afcf8ba0a3e96e0be6d04e02018d7e698e0ebf8962d39e4" }, "downloads": -1, "filename": "tosr0x-0.1.0.tar.gz", "has_sig": false, "md5_digest": "4e6cae572c9f5b717eda051109262ef5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3752, "upload_time": "2014-01-27T04:33:25", "url": "https://files.pythonhosted.org/packages/a6/16/6915081273a16e5a8bfa680f10eecc0f968d7e34ed5b0a86fa24df079e8f/tosr0x-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "eb659d9aa5ad757d9386831e424c483e", "sha256": "6755609cb3c2c7bb011391f036e875c2c7ef1301b86272c60b489e0b25c48138" }, "downloads": -1, "filename": "tosr0x-0.2.0.tar.gz", "has_sig": false, "md5_digest": "eb659d9aa5ad757d9386831e424c483e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3942, "upload_time": "2014-01-27T12:33:42", "url": "https://files.pythonhosted.org/packages/d6/cd/edd7559a71c36fd227a0bb54a99e2cc1ae6e15aa4ceca404613232ac4ceb/tosr0x-0.2.0.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "e5781fd58c8f7953a7a55c853db4507c", "sha256": "055d0ca3b40de8cd6598c78fefaa3049aafcf6f9491653b2ef1fecd4aee2048a" }, "downloads": -1, "filename": "tosr0x-0.3.0.tar.gz", "has_sig": false, "md5_digest": "e5781fd58c8f7953a7a55c853db4507c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5670, "upload_time": "2015-05-29T08:38:14", "url": "https://files.pythonhosted.org/packages/cc/9d/9fd76147c46b43aec165514a47f0fa11b40ee54a66d6f9266a09861f77d5/tosr0x-0.3.0.tar.gz" } ], "0.5.0": [ { "comment_text": "", "digests": { "md5": "5c470f7cd10c68d7cc4d6513744d117c", "sha256": "110c8b6f9873380bd5253841f79d864ff3fd1d51ec57ea6b03c1c8bb65ad29b3" }, "downloads": -1, "filename": "tosr0x-0.5.0.tar.gz", "has_sig": false, "md5_digest": "5c470f7cd10c68d7cc4d6513744d117c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6218, "upload_time": "2015-06-01T23:05:42", "url": "https://files.pythonhosted.org/packages/c6/7d/ac12c0e036fc68e686faac9c70d748c815d45886f137146aba77ae6cbee4/tosr0x-0.5.0.tar.gz" } ], "0.5.1": [ { "comment_text": "", "digests": { "md5": "0a8b762af217e89778e7b70549f6c2e0", "sha256": "82f37447e2540ffc047d1b5f29d6dd762d8297fc6eb1a5ea74a08ec54195d4bd" }, "downloads": -1, "filename": "tosr0x-0.5.1.tar.gz", "has_sig": false, "md5_digest": "0a8b762af217e89778e7b70549f6c2e0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6273, "upload_time": "2015-06-02T12:27:42", "url": "https://files.pythonhosted.org/packages/d5/63/041d4b705e9c760fec7f7d7ac254287e1e4fdf2b2e8aa8690f7d2f402da4/tosr0x-0.5.1.tar.gz" } ], "0.5.2": [ { "comment_text": "", "digests": { "md5": "a9e3d477676fd2402d71c03452fdc156", "sha256": "fcdf1962ae269c160071f690fa1896d97872c008b9c5bc9e9869fffc5ffa92e9" }, "downloads": -1, "filename": "tosr0x-0.5.2.tar.gz", "has_sig": false, "md5_digest": "a9e3d477676fd2402d71c03452fdc156", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7418, "upload_time": "2015-06-02T12:31:08", "url": "https://files.pythonhosted.org/packages/2a/58/a74de81e4aa4f1f7595dfb6fac30819b1475ff64a626a21e42ea9ed93d34/tosr0x-0.5.2.tar.gz" } ], "0.6.0": [ { "comment_text": "", "digests": { "md5": "fff4d67e27b87ec83938d2394ca76eb3", "sha256": "30edf0290739ee78b871a1ea2bf0ca0b587df89c2bc49bd93e85b4e484a4c3fc" }, "downloads": -1, "filename": "tosr0x-0.6.0.tar.gz", "has_sig": false, "md5_digest": "fff4d67e27b87ec83938d2394ca76eb3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7346, "upload_time": "2019-10-12T04:24:43", "url": "https://files.pythonhosted.org/packages/97/c3/2adc843d4de88cada3892e78368cfb590a1ee32ea433d3259d08751e54d2/tosr0x-0.6.0.tar.gz" } ], "0.6.1": [ { "comment_text": "", "digests": { "md5": "4c43e3654af5499ac71ef9c7569ee1e8", "sha256": "b3b7dbb6eebd9ac638eb9ac302d3627bf40685731234b9ec60cb078fe6f4df6a" }, "downloads": -1, "filename": "tosr0x-0.6.1.tar.gz", "has_sig": false, "md5_digest": "4c43e3654af5499ac71ef9c7569ee1e8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7347, "upload_time": "2019-10-12T04:32:13", "url": "https://files.pythonhosted.org/packages/30/bc/df65e7d998941f9cf9c39f92bfd7f43e40d66eae150d19ba3c331bf0b056/tosr0x-0.6.1.tar.gz" } ], "0.6.2": [ { "comment_text": "", "digests": { "md5": "26a6e89526c0191ecb03badc4e2f754d", "sha256": "a61384408c4742b2ecbbb9a9332e34f9ff1aeffba947eba277c4400799dd88f1" }, "downloads": -1, "filename": "tosr0x-0.6.2.tar.gz", "has_sig": false, "md5_digest": "26a6e89526c0191ecb03badc4e2f754d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7257, "upload_time": "2019-10-12T04:35:39", "url": "https://files.pythonhosted.org/packages/7d/d1/46f85140d01b2250f8ad4b7190d96f457016e090338cbd76dc58a6b47fce/tosr0x-0.6.2.tar.gz" } ], "0.6.4": [ { "comment_text": "", "digests": { "md5": "b4c1dfc6f716088a334dea5c465cb3db", "sha256": "d1d4df590ef1c7b5ce9a8b9fc49405c92af67ea436b33734e8d90d942af4da96" }, "downloads": -1, "filename": "tosr0x-0.6.4.tar.gz", "has_sig": false, "md5_digest": "b4c1dfc6f716088a334dea5c465cb3db", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7378, "upload_time": "2019-10-12T05:01:40", "url": "https://files.pythonhosted.org/packages/58/09/fc93d18495cfd97fcb93c00a416d80bc2dcff4108ee741c14cdcb0b2a518/tosr0x-0.6.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b4c1dfc6f716088a334dea5c465cb3db", "sha256": "d1d4df590ef1c7b5ce9a8b9fc49405c92af67ea436b33734e8d90d942af4da96" }, "downloads": -1, "filename": "tosr0x-0.6.4.tar.gz", "has_sig": false, "md5_digest": "b4c1dfc6f716088a334dea5c465cb3db", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7378, "upload_time": "2019-10-12T05:01:40", "url": "https://files.pythonhosted.org/packages/58/09/fc93d18495cfd97fcb93c00a416d80bc2dcff4108ee741c14cdcb0b2a518/tosr0x-0.6.4.tar.gz" } ] }