|
1 | | -# etee-Python-API |
2 | | -Official Python API for the eteeController devices. This API enables easy device data reading and communication. To learn more about the controllers, visit: eteexr.com . |
| 1 | +<!-- README file in MD for the etee Python API repository--> |
| 2 | +<a name="readme-top"></a> |
| 3 | +<!-- |
| 4 | +*** Attribution and thanks: README template adapted from Othneil Drew's example, available at: |
| 5 | +*** https://github.com/othneildrew/Best-README-Template |
| 6 | +--> |
| 7 | + |
| 8 | + |
| 9 | +<!-- PROJECT LOGO --> |
| 10 | +<br /> |
| 11 | +<div align="center"> |
| 12 | + <a href="https://github.com/eteeXR/etee-Python-API"> |
| 13 | + <img src="img/logo-dark-mode.png" alt="Logo" width="200" height="200"> |
| 14 | + </a> |
| 15 | + |
| 16 | + <p align="center"> |
| 17 | + Official Python API for the eteeController devices. |
| 18 | + <br /> |
| 19 | + <a href="https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/index.html#"><strong>Explore the docs »</strong></a> |
| 20 | + <br /> |
| 21 | + <a href="https://github.com/eteeXR/etee-Python-API/issues">Report Bug</a> |
| 22 | + · |
| 23 | + <a href="https://github.com/eteeXR/etee-Python-API/issues">Request Feature</a> |
| 24 | + </p> |
| 25 | +</div> |
| 26 | + |
| 27 | + |
| 28 | +<!-- SHIELDS FOR REPO --> |
| 29 | +<br /> |
| 30 | +<p align="center"> |
| 31 | + <a href="https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/index.html#"> |
| 32 | + <img src="https://img.shields.io/badge/docs-etee_Python_API-lightgrey" |
| 33 | + alt="Check our Docs!"></a> |
| 34 | + <a> |
| 35 | + <img src="https://img.shields.io/github/v/tag/eteexr/etee-Python-API" |
| 36 | + alt="Tag for latest stable release"></a> |
| 37 | + <a> |
| 38 | + <img src="https://img.shields.io/github/license/eteexr/etee-Python-API" |
| 39 | + alt="License"></a> |
| 40 | +</p> |
| 41 | + |
| 42 | +<!-- SHIELDS FOR SOCIALS --> |
| 43 | +<p align="center"> |
| 44 | + <a href="https://eteexr.com/"> |
| 45 | + <img src="https://img.shields.io/badge/website-eteexr.com-blue" |
| 46 | + alt="Check our Website!"></a> |
| 47 | + <a href="customer@eteexr.com"> |
| 48 | + <img src="https://img.shields.io/badge/contact-customer%40eteexr.com-blue" |
| 49 | + alt="Support e-mail"></a> |
| 50 | + <a href="https://twitter.com/etee_tg0"> |
| 51 | + <img src="https://img.shields.io/twitter/follow/etee_tg0?style=social" |
| 52 | + alt="Follow us in Twitter!"></a> |
| 53 | +</p> |
| 54 | + |
| 55 | + |
| 56 | +<!-- TABLE OF CONTENTS --> |
| 57 | +<details> |
| 58 | + <summary>Table of Contents</summary> |
| 59 | + <ol> |
| 60 | + <li> |
| 61 | + <a href="#about-the-project">About The Project</a> |
| 62 | + </li> |
| 63 | + <li> |
| 64 | + <a href="#getting-started">Getting Started</a> |
| 65 | + <ul> |
| 66 | + <li><a href="#clone-repo">Step 1: Clone the Repository</a></li> |
| 67 | + <li><a href="#package-installation-and-venv">Step 2: Package Installation & Environment</a></li> |
| 68 | + </ul> |
| 69 | + </li> |
| 70 | + <li><a href="#usage">Usage</a></li> |
| 71 | + <li><a href="#contributing">Contributing</a> |
| 72 | + <ul> |
| 73 | + <li><a href="#how-to-contribute">How to Contribute</a></li> |
| 74 | + <li><a href="#semantic-type-prefixes">Semantic Type Prefixes</a></li> |
| 75 | + </ul> |
| 76 | + </li> |
| 77 | + <li><a href="#license">License</a></li> |
| 78 | + <li><a href="#authors">Authors</a></li> |
| 79 | + <li><a href="#contact">Contact</a></li> |
| 80 | + </ol> |
| 81 | +</details> |
| 82 | + |
| 83 | + |
| 84 | +<!-- ABOUT THE PROJECT --> |
| 85 | +## About the Project |
| 86 | + |
| 87 | +This API enables easy device data reading and communication. |
| 88 | + |
| 89 | +In this repository, you can access: |
| 90 | +- etee Python API package source code |
| 91 | +- etee Python API example scripts |
| 92 | +- Setup files |
| 93 | + |
| 94 | +For more information, please, visit our documentation site: |
| 95 | +[Developer Documentation - etee Python API][url-documentation] |
| 96 | + |
| 97 | + |
| 98 | +<!-- GETTING STARTED --> |
| 99 | +## Getting Started |
| 100 | + |
| 101 | +<a name="clone-repo"></a> |
| 102 | +### Step 1: Clone the repository |
| 103 | + |
| 104 | +1. Open a command prompt. |
| 105 | +2. Change the current working directory to the location where you want the cloned directory. |
| 106 | +3. Type git clone, and then paste the URL for the Github repository. |
| 107 | + ```sh |
| 108 | + git clone https://github.com/eteeXR/etee-Python-API.git |
| 109 | + ``` |
| 110 | + |
| 111 | +<a name="package-installation-and-venv"></a> |
| 112 | +### Step 2: Package Installation & Environment |
| 113 | +This repository comes ready with two different setup files: |
| 114 | +- `setup_repo.py` will create a [virtual environment (venv)][url-python-venv] using the dependencies listed in `requirements.txt`. |
| 115 | +- `setup.py` will automate the ***etee-api*** package installation. |
| 116 | + |
| 117 | +> **Note:** You will need the pip package to run the installation. |
| 118 | +> If you do not have Python or pip installed, follow the |
| 119 | +> [Python guide on package installation][url-python-package-installation]. |
| 120 | + |
| 121 | + |
| 122 | +<a name="setting-up-venv"></a> |
| 123 | +#### 2.1. Setting Up a Virtual Environment |
| 124 | + |
| 125 | +> **If you do not want to run the example scripts**, please skip this step and move to: |
| 126 | +> <a href="#installing-the-package">2.2. Installing the Package</a>. |
| 127 | + |
| 128 | +After cloning the repository, you will need to install all the project dependencies to run the example code. |
| 129 | +Unlike *step 2.2*., these steps will install extra dependencies required only when running the example scripts |
| 130 | +(e.g. `keyboard`, `matplotlib`). |
| 131 | + |
| 132 | +1. Open a command prompt. |
| 133 | +2. Navigate to the directory where the `setup_repo.py` is located. |
| 134 | +3. Run the script. |
| 135 | + ```sh |
| 136 | + python setup_repo.py |
| 137 | + ``` |
| 138 | +4. This should have created a venv inside your project directory. You can activate it at any time by navigating |
| 139 | +to the directory containing the /venv folder and entering the following command line: |
| 140 | + ```sh |
| 141 | + .venv\Scripts\activate.bat |
| 142 | + ``` |
| 143 | + |
| 144 | +<a name="installing-the-package"></a> |
| 145 | +#### 2.2. Installing the Package |
| 146 | + |
| 147 | +You can automate the installation of the ***etee-api*** package and all its dependencies in |
| 148 | +your Python environment, by using the `setup.py` script. |
| 149 | + |
| 150 | +1. Open a command prompt. |
| 151 | +2. If you followed *step 2.1.*, make sure that you activate the venv (see previous section). |
| 152 | +3. Navigate to the directory where the `setup.py` is located. |
| 153 | +4. Use the pip method to run the installation file. |
| 154 | + ```sh |
| 155 | + pip install . |
| 156 | + ``` |
| 157 | +5. To check that the package has been successfully installed, you can run the pip list command. |
| 158 | + ```sh |
| 159 | + pip list |
| 160 | + ``` |
| 161 | + If the package was installed, you will see its name and version listed: |
| 162 | + ```text |
| 163 | + Package Version |
| 164 | + --------------- ------- |
| 165 | + etee-api 1.0.0 |
| 166 | + ``` |
| 167 | + |
| 168 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 169 | + |
| 170 | + |
| 171 | +<!-- USAGE EXAMPLES --> |
| 172 | +## Usage |
| 173 | + |
| 174 | +To get started, [set up the hardware][url-documentation-setup-hw]. This involves connecting the device dongle to your |
| 175 | +PC or laptop, and turning ON the controllers. You will know they are connected if the device dongle keeps blinking in |
| 176 | +the following pattern: pink-pink-blue. |
| 177 | + |
| 178 | +If you followed the previous steps on installation, you should be able to run any example scripts. |
| 179 | + |
| 180 | +1. Open a command prompt. |
| 181 | +2. In case you followed *step 2.1.*, make sure that you activate the venv. |
| 182 | +3. Navigate to the directory where the example script is located. |
| 183 | +4. Use the python method to run the example script. |
| 184 | + ```sh |
| 185 | + python example_script_name.py |
| 186 | + ``` |
| 187 | + |
| 188 | +We also have [quickstart][url-documentation-quickstart] and [more detailed developer guides][url-documentation-api-functions] |
| 189 | +in our documentation page. This might help you understand the different API functionalities and how to integrate them |
| 190 | +in your custom applications. |
| 191 | + |
| 192 | +_To learn more about the API and the controller data, visit our [Developer Documentation Site][url-documentation]_ |
| 193 | + |
| 194 | +<a href="https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/index.html#"> |
| 195 | + <img src="https://img.shields.io/badge/docs-etee Python API-lightgrey" |
| 196 | + alt="Check our Docs!"> |
| 197 | +</a> |
| 198 | + |
| 199 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 200 | + |
| 201 | + |
| 202 | +<!-- CONTRIBUTING --> |
| 203 | +## Contributing |
| 204 | + |
| 205 | +### How to Contribute |
| 206 | + |
| 207 | +Contributions are what make the open source community such an amazing place to learn, inspire, and create. |
| 208 | +Any contributions you make are **greatly appreciated**. |
| 209 | + |
| 210 | +If you have a suggestion that would make this better, please fork the repo and create a pull request. |
| 211 | +You can also simply open an issue to describe your suggestion or report a bug. |
| 212 | + |
| 213 | +1. Fork the Project |
| 214 | +2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`) |
| 215 | +3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`) |
| 216 | +4. Push to the Branch (`git push origin feature/AmazingFeature`) |
| 217 | +5. Open a Pull Request |
| 218 | + |
| 219 | +### Semantic Type Prefixes |
| 220 | + |
| 221 | +To help us and the community easily identify the nature of your *commit* or *issue*, use **semantic type prefixes** |
| 222 | +to precede your message / title. |
| 223 | + |
| 224 | +Some common type prefixes include: |
| 225 | + |
| 226 | +- `feat`: A new feature for the user, not a new feature for a build script. |
| 227 | +- `fix`: Bug fix for the user, not a fix for a build scripts. |
| 228 | +- `enhanc`: Enhancement or improvement to existing feature. |
| 229 | +- `perf`: Code improved in terms of processing performance. |
| 230 | +- `refactor`: Refactoring production code (e.g. renaming a variable). |
| 231 | +- `chore`: Changes to the build process or auxiliary tools and libraries. |
| 232 | +- `docs`: Changes to documentation. |
| 233 | +- `style`: Formatting, missing semicolons, etc. No code change. |
| 234 | +- `vendor`: Update version for dependencies and other packages. |
| 235 | +- `test`: Adding missing tests or refactoring tests. No production code change. |
| 236 | + |
| 237 | +**Format**: `<type>(<scope>): <subject>`, where < scope > is optional. |
| 238 | + |
| 239 | +For example, your commit message header might look like this: |
| 240 | +```text |
| 241 | +feat(imu): Implemented Euler angles estimation from quaternion |
| 242 | +``` |
| 243 | + |
| 244 | +For more references and guides on semantic code messages, see: |
| 245 | + |
| 246 | +- [How are you writing a commit message?][url-semantic-type-prefixes-1] - by Darkø Tasevski |
| 247 | +- [Git Commit Msg][url-semantic-type-prefixes-2] - Karma by Friedel Ziegelmayer |
| 248 | + |
| 249 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 250 | + |
| 251 | + |
| 252 | +<!-- LICENSE --> |
| 253 | +## License |
| 254 | + |
| 255 | +Distributed under the Apache 2.0 License. See `LICENSE.txt` for more information. |
| 256 | + |
| 257 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 258 | + |
| 259 | + |
| 260 | +<!-- AUTHORS--> |
| 261 | +## Authors |
| 262 | + |
| 263 | +This repository was created by the [TG0][url-tg0-website] team, for the [etee][url-eteexr-website] brand. |
| 264 | + |
| 265 | +Code and documentation authors include: |
| 266 | +- **Dimitri Chikhladze** (API development and documentation) |
| 267 | +- **Pilar Zhang Qiu** (API development, documentation and release) |
| 268 | + |
| 269 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 270 | + |
| 271 | + |
| 272 | +<!-- CONTACT --> |
| 273 | +## Contact |
| 274 | + |
| 275 | +For any queries or reports about the API, please use the [**Issues tab**][url-issues-tab] in this repository. |
| 276 | +When possible, use an identifier to help us describe your query, report or request. |
| 277 | +See more at: <a href="###semantic-type-prefixes">Semantic Type Prefixes</a> |
| 278 | + |
| 279 | +For further support or queries, you can contact us: |
| 280 | +- Support e-mail: [customer@eteexr.com](customer@eteexr.com) |
| 281 | +- Support Form: [https://eteexr.com/pages/support-form](https://eteexr.com/pages/support-form) |
| 282 | + |
| 283 | +<p align="right">(<a href="#readme-top">back to top</a>)</p> |
| 284 | + |
| 285 | + |
| 286 | +<!-- MARKDOWN LINKS & IMAGES --> |
| 287 | +<!-- https://www.markdownguide.org/basic-syntax/#reference-style-links --> |
| 288 | +[url-documentation]: https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/index.html# |
| 289 | +[url-documentation-setup-hw]: https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/setup.html |
| 290 | +[url-documentation-quickstart]: https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/quickstart.html |
| 291 | +[url-documentation-api-functions]: https://tg0-etee-python-api.readthedocs-hosted.com/en/latest/guide.html |
| 292 | +[url-issues-tab]: https://github.com/eteeXR/etee-Python-API/issues |
| 293 | +[url-python-venv]: https://docs.python.org/3/tutorial/venv.html |
| 294 | +[url-python-package-installation]: https://packaging.python.org/en/latest/tutorials/installing-packages/ |
| 295 | +[url-tg0-website]: https://tg0.co.uk/ |
| 296 | +[url-eteexr-website]: https://eteexr.com/ |
| 297 | +[url-semantic-type-prefixes-1]: https://dev.to/puritanic/how-are-you-writing-a-commit-message-1ih7 |
| 298 | +[url-semantic-type-prefixes-2]: http://karma-runner.github.io/1.0/dev/git-commit-msg.html |
0 commit comments