Energenie EG-PMS User Manual Page 11

  • Download
  • Add to my manuals
  • Print
  • Page
    / 30
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 10
CHAPTER 3
Contents:
3.1 Installation
Installing pickups is easy. Just use pip:
$ pip install pickups
Common practise is to have an own virtual environment for your new project. Having virtualenvwrapper
installed, you can install pickups with:
$ mkvirtualenv pickups
$ pip install pickups
3.2 Usage
To use pickups in a project you have to import the main package by invoking:
$ import pickups
3.2.1 Get Started
For your convenience you can use the helper method pickups.helpers.register() which creates a custom
signal handler for you and then starts looping (depending on your configuration file) to infinity to update the extreme
feedback device statuses. Using the already shipped pickups.bamboo.BambooPickup and a configuration file
you can easily start going with a very simple runner like this:
import os
import signal
import pickups
from pickups.bamboo.bamboopickup import BambooPickup
def registerpickup(configfile):
pickups.helpers.register(BambooPickup, configfile, sign=signal.SIGTERM)
def main():
here = os.path.abspath(os.path.dirname(__file__))
configfile = os.path.join(here, ’config.cfg’)
7
Page view 10
1 2 ... 6 7 8 9 10 11 12 13 14 15 16 ... 29 30

Comments to this Manuals

No comments