Giter VIP home page Giter VIP logo

ninja-envir's Introduction

Current Cost EnviR Power Meter

Usage

This Ninja Block driver is installed on your ninja block (http://www.ninjablocks.com/) It will read the serial commands from your Current Cost EnviR power meter's serial port (http://www.currentcost.com/product-envir.html) You can use the EnviR's serial cable or use the on-board beagle serial pins. It will upload your current usage every 6 seconds when the unit sends data. This will then show in your Ninja Block dashboard and you will be able to make rules based upon your household power usage You also have the option to send the data to Cosm (replicating the bridge device)

Installation

Log into the Ninjablock via SSH

  $ cd /opt/ninja/drivers/
  $ rm -rf ninja-envir
  $ git clone https://github.com/DotNetDann/ninja-envir.git ninja-envir
  $ sudo service ninjablock restart

You will then be able to edit any settings via the drivers configuration on the Ninja Dashboard. (Any changes require a restart)

Ninjablock Dashboard

ScreenShot

Serial Communications

By default the driver will expect the USB cable that came with the EnviR (ttyUSB0) You have the option to use the serial pins on the board.

On the beagle bone (http://beagleboard.org/bone) You can use serial port name 'ttyO5' which is on-board Serial 5 (http://www.jerome-bernard.com/blog/2012/06/04/beaglebone-serial-ports-and-xbees/)

NOTE: You need to put these lines in /etc/rc.local

  echo 4 > /sys/kernel/debug/omap_mux/lcd_data8
  echo 24 > /sys/kernel/debug/omap_mux/lcd_data9

Then use this pin diagram to wire directly to the EnviR

   CC128		Beagle Bone			Cat5 Wire Colour	Notes
  ---------------------------------------------------------------------------------
 	Pin 1		Pin P9-01 or 02  	Blue				Gnd
 	Pin 4		Pin P9-03 or 04 	Green Stripe		3.3v
 	Pin 7		Pin P8-37			Brown Stripe		Serial Data (Optional)
 	Pin 8		Pin P8-38			Brown				Serial Data

ninja-envir's People

Contributors

dotnetdann avatar elliots avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

ninja-envir's Issues

TypeError: Object #<envir> has no method 'save'

With the current nina client on develop:

[2014-11-10 03:25:06.226] [WARN] NB DriverLoader - Failed to load driver: ninja-envir Error: [TypeError: Object #<envir> has no method 'save']
TypeError: Object #<envir> has no method 'save'
    at new envir (/opt/ninja-devel2/drivers/ninja-envir/index.js:56:10)
    at DriverLoader.loadDriver (/opt/ninja-devel2/lib/DriverLoader.js:135:16)
    at /opt/ninja-devel2/lib/DriverLoader.js:34:16
    at Array.forEach (native)
    at onEachDriverPath (/opt/ninja-devel2/lib/DriverLoader.js:32:28)
    at Array.forEach (native)
    at new DriverLoader (/opt/ninja-devel2/lib/DriverLoader.js:28:15)
    at Object.<anonymous> (/opt/ninja-devel2/index.js:94:15)
    at Module._compile (module.js:449:26)
    at Object.Module._extensions..js (module.js:467:10)

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.