{"id":25436657,"url":"https://github.com/moduland/orangetool","last_synced_at":"2025-07-27T09:35:20.826Z","repository":{"id":48593869,"uuid":"80631089","full_name":"Moduland/Orangetool","owner":"Moduland","description":"📚 Control Functions For Single-Board Computers","archived":false,"fork":false,"pushed_at":"2024-02-09T08:05:05.000Z","size":1433,"stargazers_count":108,"open_issues_count":5,"forks_count":23,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-07-18T10:53:12.370Z","etag":null,"topics":["control","globalip","hdmi","hdmi-off","hdmi-on","internet-connection","ip","localip","moduland","orangepi","python","raspberry","raspberry-pi","sbc","script","single-board-computers","temp","tool"],"latest_commit_sha":null,"homepage":"http://www.orangetool.ir","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Moduland.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":"Supported_Device_List.md","governance":null,"roadmap":null,"authors":"AUTHORS.md","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-02-01T15:04:36.000Z","updated_at":"2025-04-28T23:02:20.000Z","dependencies_parsed_at":"2024-11-15T03:48:44.242Z","dependency_job_id":"53ae3444-c1b4-46e8-9a2d-4cb309f11cd5","html_url":"https://github.com/Moduland/Orangetool","commit_stats":{"total_commits":282,"total_committers":3,"mean_commits":94.0,"dds":0.099290780141844,"last_synced_commit":"4f85547c4393e6bf8635a185c8017cdef8b141c1"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/Moduland/Orangetool","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Moduland%2FOrangetool","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Moduland%2FOrangetool/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Moduland%2FOrangetool/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Moduland%2FOrangetool/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Moduland","download_url":"https://codeload.github.com/Moduland/Orangetool/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Moduland%2FOrangetool/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267339495,"owners_count":24071540,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-27T02:00:11.917Z","response_time":82,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["control","globalip","hdmi","hdmi-off","hdmi-on","internet-connection","ip","localip","moduland","orangepi","python","raspberry","raspberry-pi","sbc","script","single-board-computers","temp","tool"],"created_at":"2025-02-17T08:21:24.003Z","updated_at":"2025-07-27T09:35:20.780Z","avatar_url":"https://github.com/Moduland.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\u003ca href=\"http://www.orangetool.ir\"\u003e\u003cimg src=\"http://moduland.github.io/Orangetool/images/orangetool.jpg\" height=240px width=320px\u003e\u003c/a\u003e\n\n\u003c/br\u003e\n\u003ca href=\"https://zenodo.org/badge/latestdoi/80631089\"\u003e\u003cimg src=\"https://zenodo.org/badge/80631089.svg\" alt=\"DOI\"\u003e\u003c/a\u003e\n\u003ca href=\"https://badge.fury.io/py/orangetool\"\u003e\u003cimg src=\"https://badge.fury.io/py/orangetool.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://anaconda.org/sepandhaghighi/orangetool\"\u003e\u003cimg src=\"https://anaconda.org/sepandhaghighi/orangetool/badges/version.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"http://www.orangetool.ir\"\u003e\u003cimg src=\"https://img.shields.io/website-up-down-green-red/http/shields.io.svg?label=website\"\u003e\u003c/a\u003e\n\n\u003c/div\u003e\n\n----------\n\n## Table of contents\t\t\t\t\t\n   * [Overview](https://github.com/Moduland/Orangetool#overview)\n   * [Installation](https://github.com/Moduland/Orangetool#installation)\n   * [Usage](https://github.com/Moduland/Orangetool#usage)\n   \t\t* [IP Functions](https://github.com/Moduland/Orangetool#ip-functions)\n   \t\t* [RAM Functions](https://github.com/Moduland/Orangetool#ram-functions)\n   \t\t* [Storage Functions](https://github.com/Moduland/Orangetool#storage-functions)\t\n   \t\t* [Display Functions](https://github.com/Moduland/Orangetool#display-functions)\n   \t\t* [System Functions](https://github.com/Moduland/Orangetool#system-functions)\n   * [Issues \u0026 Bug Reports](https://github.com/Moduland/Orangetool#issues--bug-reports)\n   * [Supported Device List](https://github.com/Moduland/Orangetool/blob/master/Supported_Device_List.md)\n   * [Dependencies](https://github.com/Moduland/Orangetool#dependencies)\n   * [Contribution](https://github.com/Moduland/Orangetool/blob/master/.github/CONTRIBUTING.md)\n   * [Cite](https://github.com/Moduland/Orangetool#cite)\n   * [Authors](https://github.com/Moduland/Orangetool/blob/master/AUTHORS.md)\n   * [License](https://github.com/Moduland/Orangetool/blob/master/LICENSE)\n   * [Donate](https://github.com/Moduland/Orangetool#donate-to-our-project)\n   * [Changelog](https://github.com/Moduland/Orangetool/blob/master/CHANGELOG.md)\n   * [Code of Conduct](https://github.com/Moduland/Orangetool/blob/master/.github/CODE_OF_CONDUCT.md)\n\n## Overview\n\t\nControl functions for Single-Board computers\t\t\t\t\n\nTested on [Lubuntu](http://lubuntu.me/)\n\n\u003ctable\u003e\n\t\u003ctr\u003e \n\t\t\u003ctd align=\"center\"\u003eOpen Hub\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://www.openhub.net/p/orangetool\"\u003e\u003cimg src=\"https://www.openhub.net/p/orangetool/widgets/project_thin_badge.gif\"\u003e\u003c/a\u003e\u003c/td\u003e\t\n\t\u003c/tr\u003e\n\t\u003ctr\u003e\n\t\t\u003ctd align=\"center\"\u003ePyPI Counter\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"http://pepy.tech/count/orangetool\"\u003e\u003cimg src=\"http://pepy.tech/badge/orangetool\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\u003c/tr\u003e\n\t\u003ctr\u003e\n\t\t\u003ctd align=\"center\"\u003eGithub Stars\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://github.com/Moduland/Orangetool\"\u003e\u003cimg src=\"https://img.shields.io/github/stars/Moduland/Orangetool.svg?style=social\u0026label=Stars\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\u003c/tr\u003e\n\u003c/table\u003e\n\n\n\n\u003ctable\u003e\n\t\u003ctr\u003e \n\t\t\u003ctd align=\"center\"\u003eBranch\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003emaster\u003c/td\u003e\t\n\t\t\u003ctd align=\"center\"\u003edev\u003c/td\u003e\t\n\t\u003c/tr\u003e\n\t\u003ctr\u003e\n\t\t\u003ctd align=\"center\"\u003eTravis\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://travis-ci.org/Moduland/Orangetool\"\u003e\u003cimg src=\"https://travis-ci.org/Moduland/Orangetool.svg?branch=master\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://travis-ci.org/Moduland/Orangetool\"\u003e\u003cimg src=\"https://travis-ci.org/Moduland/Orangetool.svg?branch=dev\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\u003c/tr\u003e\n\u003c/table\u003e\n\n\n\u003ctable\u003e\n\t\u003ctr\u003e \n\t\t\u003ctd align=\"center\"\u003eCode Quality\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://www.codacy.com/app/sepand-haghighi/Orangetool?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=Moduland/Orangetool\u0026amp;utm_campaign=Badge_Grade\"\u003e\u003cimg src=\"https://api.codacy.com/project/badge/Grade/ad9374e6e7b24a63b34d6a4f419497ac\"/\u003e\u003c/a\u003e\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://codebeat.co/projects/github-com-moduland-orangetool-dev\"\u003e\u003cimg alt=\"codebeat badge\" src=\"https://codebeat.co/badges/78f987a9-d504-4d29-b98d-21dd1f2d319e\" /\u003e\u003c/a\u003e\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://www.codefactor.io/repository/github/moduland/orangetool\"\u003e\u003cimg src=\"https://www.codefactor.io/repository/github/moduland/orangetool/badge\" alt=\"CodeFactor\" /\u003e\u003c/a\u003e\u003c/td\u003e\t\t\n\t\u003c/tr\u003e\n\u003c/table\u003e\n\n----------\n\t\nBy [Moduland Co](http://www.moduland.ir)\t\t\n\n\n## Installation\n### Source Code\n- Download [Version 0.50](https://github.com/moduland/Orangetool/archive/v0.50.zip) or [Latest Source ](https://github.com/Moduland/Orangetool/archive/dev.zip)\n- `pip3 install -r requirements.txt` or `pip install -r requirements.txt` (Need root access)\t\n- `python3 setup.py install` or `python setup.py install`\n### PyPI\n\n- Check [Python Packaging User Guide](https://packaging.python.org/installing/)     \n- `pip3 install orangetool==0.50` or `pip install orangetool==0.50` (Need root access)\t\n\u003cdiv align=\"center\"\u003e\n\u003ca href=\"https://asciinema.org/a/141548\" target=\"_blank\"\u003e\u003cimg src=\"https://asciinema.org/a/141548.png\" /\u003e\u003c/a\u003e\n\u003c/div\u003e\n\n### Conda\n\n- Check [Conda Managing Package](https://conda.io/docs/user-guide/tasks/manage-pkgs.html#installing-packages-from-anaconda-org)\n- `conda install -c sepandhaghighi orangetool` (Need root access)\n\n### Easy install\n\n- Run `easy_install --upgrade orangetool` (Need root access)\n\n## Usage\n\t\t\t\t\t\t\t\t\t\t\t\t\n### IP Functions\n\n```python\nimport orangetool\n\n#1- local_ip\n\nlocal_ip=orangetool.local_ip() # this function return local ip of board as string\n\n#2- global_ip\n\nglobal_ip=orangetool.global_ip() # this function return global ip of board as string\n\n#3- internet \n\nstatus=orangetool.internet() #this function check internet connection and return True if internet connection is stable\n\n#4- ping\n\nip_status=orangetool.ping(ip_address) #this function check ip and return True if this ip is available in network and False otherwise\n\n#5- set_ip\n\norangetool.set_ip(\"192.168.1.46\",\"eth0\")  #this function set static ip for system\n\n#6- mac\n\nmac_dic=orangetool.mac() # return dict of all system net devices mac addresses\n\n#7- network_enable\n\nstatus=network_enable(\"eth0\") # enable network device\n\n#8- network_disable\n\nstatus=network_disable(\"eth0\") # disable network device\n\n```\n\n### RAM Functions\t\t\n\n```python\n \n#1- total ram\n\nram=orangetool.ram_total() #this function return total ram of the board\n\n#2- free ram\n\nram=orangetool.ram_free() # this function return how much ram is available in the board\n\n#3- ram percentage\n\nram=orangetool.ram_percent() # this function return used ram percentage\n\n#4- used percentage\n\nram=orangetool.ram_used() # this function return used ram \n\n#5- freeup\n\norangetool.freeup() # To free pagecache, dentries and inodes and return freeuped amount\n\n```\n\n### Storage Functions\t\t\t\t\n\n```python\n#1- mount_status\n\nmount_details=orangetool.mount_status(\"sda1\") # This function return mount addresses of input device\n\n#2- storage_status\n\nmount_details=orangetool.storage_status() # This function return all of the inserted storage and their status\n\n#3- unmount\n\norangetool.unmount(\"/mnt/usb1\") # This function unmount input device\n\n#4- unmount_all\n\n\norangetool.unmount_all() #This function unmount all of the mounted devices\n\n#5- mount\n\norangetool.mount(\"sda1\",\"/mnt/usb1\") # This function mount input device in input addresses\n\n#6- usb_on\n\norangetool.usb_on() # This function enable USB\n\n#7- usb_off\n\norangetool.usb_off() # This function disable USB\n\n```\n\n### Display Functions\t\t\t\t\n\n```python\n#1- hdmi_on\n\norangetool.hdmi_on() # turn on hdmi port\n\n#2- hdmi_off\n\norangetool.hdmi_off() # turn off hdmi port\n\n#3- hdmi_size\n\norangetool.hdmi_size(1280,720) # this function change hdmi display resolution\n\n```\n\n### System Functions\t\t\t\t\n\n```python\n#1- sleep\n\norangetool.sleep() # put system in sleep mode\n\n#2- hibernate\n\norangetool.hibernate() # put system in hibernate mode\n\n#3- halt\n\norangetool.halt() # poweroff system\n\n#4- restart\n\norangetool.restart() # restart system\n\n#5- wakeup\n\norangetool.wakeup(day=1,hour=0,minute=1,sync=True) # set rtc wakeuptime\n\n#6- get_temp\n\ntemp=orangetool.get_temp() # this function return cpu temperature as string\n\n#7- uptime\n\ntime=orangetool.uptime() # this function return uptime of system\n\n#8- idletime\n\ntime=orangetool.idletime() # this function return idle of system ( all cores)\n\n\n#9- version\n\norangetool.version() # return orangetool version for test\n\n#10- check_update\n\norangetool.check_update() # Return True if new version is available\n\n```\n\n\n\n- All of the functions in error state return `Error` String\n- `local_ip` and `global_ip` originally are available in ipz package [Link](http://github.com/sepandhaghighi/ipz)\n- RAM functions in this version need psutil package\n- Running `set_ip` function remotely will freeze your terminal so it's better to set `restart` parameter to True\n- Running `halt`,`restart`,`hibernate` \u0026 `sleep` functions remotely will freeze your terminal\n- Some of funtions need root access so it's better to run ```sudo -s``` before use this tool\n\n\n\n## Issues \u0026 Bug Reports\t\t\t\n\nJust fill an issue and describe it. We'll check it ASAP!\t\t\t\t\t\t\t\nor send an email to [info@orangetool.ir](mailto:info@orangetool.ir \"info@orangetool.ir\"). \n\n## Dependencies\n\n\u003ctable\u003e\n\t\u003ctr\u003e \n\t\t\u003ctd align=\"center\"\u003emaster\u003c/td\u003e\t\n\t\t\u003ctd align=\"center\"\u003edev\u003c/td\u003e\t\n\t\u003c/tr\u003e\n\t\u003ctr\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://requires.io/github/Moduland/Orangetool/requirements/?branch=master\"\u003e\u003cimg src=\"https://requires.io/github/Moduland/Orangetool/requirements.svg?branch=master\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\t\u003ctd align=\"center\"\u003e\u003ca href=\"https://requires.io/github/Moduland/Orangetool/requirements/?branch=dev\"\u003e\u003cimg src=\"https://requires.io/github/Moduland/Orangetool/requirements.svg?branch=dev\"\u003e\u003c/a\u003e\u003c/td\u003e\n\t\u003c/tr\u003e\n\u003c/table\u003e\n\n\t\t\n## Cite\nIf you use orangetool in your research , please cite this ;-)\n\n\u003cblockquote\u003e\n\u003cp\u003eSepand Haghighi. 2017. Moduland/Orangetool: Version 0.23. (July 2017). DOI:http://dx.doi.org/10.5281/zenodo.829797\u003c/p\u003e\n\u003c/blockquote\u003e\t\t\t\n\n\t\t\t\t\t\t\n\t\t\t\t\t\n## Donate to our project\t\t\t\t\t\t\t\t\t\n\nIf you feel like our project is important can you please support us?\t\t\t\nOur project is not and is never going to be working for profit. We need the money just so we can continue doing what we do.\n\n\u003ch3\u003eBitcoin :\u003c/h3\u003e\t\t\t\t\t\n\n```1XGr9qbZjBpUQJJSB6WtgBQbDTgrhPLPA```\n\t\t\t\t\n\n\u003ch3\u003ePayping (For Iranian citizens) :\u003c/h3\u003e\n\n\u003ca href=\"http://www.payping.net/sepandhaghighi\" target=\"__blank\"\u003e\u003cimg src=\"http://www.qpage.ir/images/payping.png\" height=100px width=100px\u003e\u003c/a\u003e\n\n## License\n\u003cdiv align=\"center\"\u003e\n\u003ca href=\"https://github.com/Moduland/orangetool/blob/master/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/mashape/apistatus.svg\"/\u003e\u003c/a\u003e\n\u003cbr/\u003e\n\u003ca href=\"http://www.moduland.ir\" target=\"_blank\" title=\"Moduland Website\"\u003e\u003cimg src=\"http://www.orangetool.ir/images/moduland.jpg\" height=\"128px\" width=\"128px\" alt=\"Moduland Website\"\u003e\u003c/a\u003e\n\n\u003c/div\u003e\n\n\n\n\t\t\t\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoduland%2Forangetool","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmoduland%2Forangetool","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoduland%2Forangetool/lists"}