Coder Social home page Coder Social logo

myenergi-python-example's Introduction

MyEnergi-Python-Example

How to access and display MyEnergi data

Windows PC

  1. Install a version of Python typically 3.10
  2. The Python code here needs additional modules to be installed, so launch Windows Powershell(Admin)
  3. Type:
  4. pip install requests
    
  5. pip install json
    
  6. Repeat for any other missing modules
  7. Download the example Python code provided, to your desok top is easiest
  8. Right click and edit with Idle (You need to install Idle)
  9. Edit the file to add your Username (HUB serial number) and Password (API Key)
  10. Choose Run
  11. Enjoy

API Error Codes and meaning

CODE MEANING

0 O.K. / Success

-1 Invalid ID – The unit or group cannot be found or the user does not have access rights to the ID.

-2 Invalid DSR command sequence number. Valid write values or 1-15 inclusive. Valid read values are 0-15 inclusive.

-3 No action taken. Command Sequence Number “csn” equals “err” for single unit. i.e. Command Sequence number is same as last number used.

-4 Hub not found. No associated hub record for the unit.

-5 Internal Error.

-6 Invalid load value.

-7 Year missing.

-8 Month missing or invalid.

-9 Day missing or invalid.

-10 Hour missing or invalid.

-11 Invalid TTL Value.

-12 User not authorised to perform operation.

-13 Serial No not found.

-14 Missing or bad parameter.

-15 Invalid password.

-16 New passwords don’t match.

-17 Invalid new password. Password must not contain “&”

-18 New password is same as old password.

-19 User not registered.

-20 Minute missing or invalid

-21 Slot missing or invalid

-22 Priority bad or missing

-23 Command not appropriate for device

-24 Check period bad or missing

-25 Min Green Level bad or missing

-26 Busy – Server is already sending a command to the device.

-27 Relay not fitted.

myenergi-python-example's People

Contributors

g6ejd avatar

Stargazers

 avatar  avatar Michael Birse avatar Paul Harte avatar Dom Weaver avatar  avatar DC avatar  avatar  avatar joolsk avatar Ed Mellodew avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.