skip to navigation
skip to content

Not Logged In

python-eeml 4.1.0

Python support for the Extended Environments Markup Language

https://travis-ci.org/petervizi/python-eeml.png?branch=master

Intorduction

This is a python package for generating eeml documents.

Installation

With administrative privileges run:

sudo python setup.py install

Without root access:

python setup.py install --prefix=~/
PTYHONPATH="~/lib/python2.7/site-packages" python example/simple_example.py

Example

An example python script for publishing measurement data:

import eeml
import eeml.datastream
import eeml.unit
import serial

# parameters
API_KEY = 'YOUR PERSONAL API KEY'
API_URL = 'YOUR PERSONAL API URL, LIKE /api/1275.xml'

serial = serial.Serial('/dev/ttyUSB0', 9600)
readings = serial.readline().strip().split(' ') # the readings are separated by spaces
pac = eeml.datastream.Cosm(API_URL, API_KEY)
pac.update([eeml.Data(0, readings[0], unit=eeml.unit.Celsius()), eeml.Data(1, readings[1], unit=eeml.unit.RH())])
pac.put()

Other examples can be found in the example folder.

Requirements

  • python-xml
 
File Type Py Version Uploaded on Size
python-eeml-4.1.0.tar.gz (md5) Source 2013-02-18 20KB
  • Downloads (All Versions):
  • 17 downloads in the last day
  • 105 downloads in the last week
  • 685 downloads in the last month