Welcome to libsensorPy! ¶
LibsensorPy is an extensible open source python library, which allows the user to interact with environment through sensors and actuators coupled to the Raspberry Pi as well as add new sensors/actuators and easy way to practice, thereby strengthening the use of free hardware, aiming to solve problems of a physical nature. With this library the user only need keep focus on implementing their application business logic using the data that the solution delivery already processed, since LibsensorPy provides the abstractions of the main necessary resources for the processing.
LibsensorPy provides a simple abstraction layer between user's application and the actual sensor Hardware, allowing to drop in any comparable sensor with only one or two lines of code to change in the project that uses the library. Its goal is to facilitate the creation of ubiquitous systems using the Raspberry Pi. The tool is implemented in Python and is designed to facilitate the inclusion of new sensors, families and factories of sensors, as well as ease of use by the user, abstracting technical and behaviors specific to that system's type, using design patterns and following the SOLID principles.
The library's differential is the use of Abstract Factory pattern, allowing sensors and events from the same family work together, to be easily exchanged if necessary and the same type of sensors may be replaced without being necessary changes in existing code. The library also provides basic and composite sensors according to the client's needs, as well as a set of events related to specific types of sensors and unit conversions.
News / Announcements ¶
2015-04-23Version 0.0.7 has been pre-released and is already available for download. ( Downloads | Installation )
New development and bug fixes will now be provided via the 1.0-SNAPSHOT builds and the latest development codebase will now be maintained in the 'develop' branch. In addtition to maintenance and bug fixes, the 1.0-SNAPSHOT build also includes new sensors and implement the events.
Project Status ¶
Please note that this project is continually under development. The functionality is very stable but we need help to improvements and bug fixes by tests, and we would like to have these feedbacks committed into the develop branch in the libsensorPy GitHub repository and SNAPSHOT builds are published in the Pypi repository .
You are welcome to start using and integrating this library in your project. Please provide any feedback good, bad or ugly. ( We'll maybe keep the ugly feedback to a minimum. )
Visit the Downloads page to download the latest libsensorPy library builds.
Features ¶
- Manipulate sensor data to delivery readable standard values for users
- Change any comparable sensor with only one or two lines of code to change in the project that uses the library.
- Convert measurement units
- Configure GPIO pin direction
- Control/write GPIO pin states
- Easy to extend the library and add new sensor
- Automatically set GPIO states on program termination (GPIO cleanup)
- Triggers for automation based on event state changes
- Basic and Composite sensors
Getting Started ¶
The simplest method to install libsensorPy on your RaspberryPi is to execute
the following command directly on your RaspberryPi.
sudo pip install libsensorPy
To get started using the libsensorPy library, please see the following pages:
Examples ¶
Review each of the following examples to explore the functionality provided by the libsensorPy library.