Skip to main content

Platform-independent wrapper for platform-dependent APIs

Project description

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Description: # Plyer

Plyer is a platform-independent api to use features commonly found on various platforms, notably mobile ones, in Python.

[![coverage](https://coveralls.io/repos/kivy/plyer/badge.svg?branch=master)](https://coveralls.io/r/kivy/plyer?branch=master) [![Backers on Open Collective](https://opencollective.com/kivy/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/kivy/sponsors/badge.svg)](#sponsors) ![Continuous Integration with Ubuntu](https://github.com/kivy/plyer/workflows/Continuous%20Integration%20with%20Ubuntu/badge.svg) ![Continuous Integration with OSX](https://github.com/kivy/plyer/workflows/Continuous%20Integration%20with%20OSX/badge.svg) ![Continuous Integration with Windows](https://github.com/kivy/plyer/workflows/Continuous%20Integration%20with%20Windows/badge.svg) ![Deploy to PyPI](https://github.com/kivy/plyer/workflows/Deploy%20to%20PyPI/badge.svg)

## How

Plyer tries not to reinvent the wheel, and will call for external libraries to implement the api in the easiest way, depending on the current platform.

  • on python-for-android, pyjnius is used

  • on kivy-ios, pyobjus is used

  • on windows/mac/linux, commonly found libraries and programs will be used

## Supported APIs

Platform | Android | iOS | Windows | OS X | Linux |
—————————— | ——- | — | ——- | —- | —– |
Accelerometer | ✔ | ✔ | | ✔ | ✔ |
Audio recording | ✔ | | ✔ | ✔ | |
Barometer | ✔ | ✔ | | | |
Battery | ✔ | ✔ | ✔ | ✔ | ✔ |
Bluetooth | ✔ | | | ✔ | |
Brightness | ✔ | ✔ | | | ✔ |
Call | ✔ | ✔ | | | |
Camera (taking picture) | ✔ | ✔ | | | |
Compass | ✔ | ✔ | | | |
CPU count | | | ✔ | ✔ | ✔ |
Email (open mail client) | ✔ | ✔ | ✔ | ✔ | ✔ |
Flash | ✔ | ✔ | | | |
GPS | ✔ | ✔ | | | |
Gravity | ✔ | ✔ | | | |
Gyroscope | ✔ | ✔ | | | |
Humidity | ✔ | | | | |
IR Blaster | ✔ | | | | |
Light | ✔ | | | | |
Native file chooser | ✔ | | ✔ | ✔ | ✔ |
Notifications | ✔ | | ✔ | ✔ | ✔ |
Orientation | ✔ | | | | |
Proximity | ✔ | | | | |
Screenshot | | | ✔ | ✔ | ✔ |
SMS (send messages) | ✔ | ✔ | | | |
Spatial Orientation | ✔ | ✔ | | | |
Speech to text | ✔ | | | | |
Storage Path | ✔ | ✔ | ✔ | ✔ | ✔ |
Temperature | ✔ | | | | |
Text to speech | ✔ | ✔ | ✔ | ✔ | ✔ |
Unique ID | ✔ | ✔ | ✔ | ✔ | ✔ |
Vibrator | ✔ | ✔ | | | |
Wifi | | | ✔ | ✔ | ✔ |

## Support

If you need assistance, you can ask for help on our mailing list:

Discord channel:

## Contributing

We love pull requests and discussing novel ideas. Check out our [contribution guide](http://kivy.org/docs/contribute.html) and feel free to improve Plyer.

The following mailing list and IRC channel are used exclusively for discussions about developing the Kivy framework and its sister projects:

IRC channel:

  • Server : irc.freenode.net

  • Port : 6667, 6697 (SSL only)

  • Channel : #kivy-dev

## License

Plyer is released under the terms of the MIT License. Please refer to the LICENSE file.

## Backers

Thank you to all our backers! 🙏 [[Become a backer](https://opencollective.com/kivy#backer)]

<a href=”https://opencollective.com/kivy#backers” target=”_blank”><img src=”https://opencollective.com/kivy/backers.svg?width=890”></a>

## Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/kivy#sponsor)]

<a href=”https://opencollective.com/kivy/sponsor/0/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/0/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/1/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/1/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/2/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/2/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/3/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/3/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/4/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/4/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/5/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/5/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/6/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/6/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/7/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/7/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/8/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/8/avatar.svg”></a> <a href=”https://opencollective.com/kivy/sponsor/9/website” target=”_blank”><img src=”https://opencollective.com/kivy/sponsor/9/avatar.svg”></a>

# Change Log

## [1.3.0](https://github.com/kivy/plyer/tree/1.3.0) (2017-03-23) [Full Changelog](https://github.com/kivy/plyer/compare/v1.2.4…1.3.0)

Implemented enhancements:

Closed issues:

Merged pull requests:

## [v1.2.4](https://github.com/kivy/plyer/tree/v1.2.4) (2015-06-01) [Full Changelog](https://github.com/kivy/plyer/compare/1.2.3…v1.2.4)

Implemented enhancements:

Closed issues:

Merged pull requests:

## [1.2.3](https://github.com/kivy/plyer/tree/1.2.3) (2015-01-27) [Full Changelog](https://github.com/kivy/plyer/compare/1.2.2…1.2.3)

## [1.2.2](https://github.com/kivy/plyer/tree/1.2.2) (2015-01-27) [Full Changelog](https://github.com/kivy/plyer/compare/1.2.1…1.2.2)

Closed issues:

Merged pull requests:

## [1.2.1](https://github.com/kivy/plyer/tree/1.2.1) (2014-08-19) [Full Changelog](https://github.com/kivy/plyer/compare/1.2.0…1.2.1)

Implemented enhancements:

Closed issues:

Merged pull requests:

## [1.2.0](https://github.com/kivy/plyer/tree/1.2.0) (2014-06-24) Implemented enhancements:

Closed issues:

Merged pull requests:

* This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)

Platform: UNKNOWN Classifier: Development Status :: 4 - Beta Classifier: Intended Audience :: Developers Classifier: Natural Language :: English Classifier: License :: OSI Approved :: MIT License Classifier: Programming Language :: Python Classifier: Programming Language :: Python :: 2.6 Classifier: Programming Language :: Python :: 2.7 Classifier: Programming Language :: Python :: 3 Classifier: Programming Language :: Python :: 3.3 Classifier: Programming Language :: Python :: 3.4 Classifier: Programming Language :: Python :: 3.5 Description-Content-Type: text/markdown Provides-Extra: ios Provides-Extra: macosx Provides-Extra: android Provides-Extra: dev

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

plyer-2.0.0.tar.gz (95.6 kB view details)

Uploaded Source

Built Distribution

plyer-2.0.0-py2.py3-none-any.whl (131.4 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file plyer-2.0.0.tar.gz.

File metadata

  • Download URL: plyer-2.0.0.tar.gz
  • Upload date:
  • Size: 95.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for plyer-2.0.0.tar.gz
Algorithm Hash digest
SHA256 8de38b17bc438df36eedeacd546cf05303ab871855af0669fc4e8df51f2adf94
MD5 a1ea761bfdce75444fec12cc311550af
BLAKE2b-256 eff67061dc660e04f5aa4c2bf13bdd7320812f89c02699f67d9e77445a50ec8e

See more details on using hashes here.

File details

Details for the file plyer-2.0.0-py2.py3-none-any.whl.

File metadata

  • Download URL: plyer-2.0.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 131.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0

File hashes

Hashes for plyer-2.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 d62a1e68622042e6b9367ba429844e989ea7b13035fd1befe66f385aaaba6de1
MD5 42d8c958a512ea004f5d5642568b4d7f
BLAKE2b-256 26b123800271e74bf5ce54e124df0c495506bb9857d05f63cf6bc3ce4d89f5c9

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page