Socket
Socket
Sign inDemoInstall

chip-io

Package Overview
Dependencies
24
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    chip-io

Johnny-Five IO Plugin for the Next Thing Co. C.H.I.P.


Version published
Weekly downloads
1
Maintainers
1
Created
Weekly downloads
 

Changelog

Source

Version 2.0.0

  • Officially added support to access LCD pins via mmap to /dev/mem (requires root or sudo).
  • Added PWM and LRADC support.
  • Added new components for battery voltage, internal temperature, and status LED.
  • Fixed segfault if sudo was not used for R8 pins. (@urish)
  • Bus 2 is now the default bus for I2C. (@bbx10)
  • Added support for J2 components to specificy I2C bus via i2cConfig (@rwaldron)

Older

  • Changes not recorded

Readme

Source

chip-io

logo

Johnny-Five IO Plugin for the Next Thing Co. C.H.I.P.

Prerequisites

  • Next Thing Co. C.H.I.P. board
  • Node.js installed
    1. Install curl: sudo apt-get install curl
    2. Follow Debian section of NodeSource installations instructions
  • Build essential installed: sudo apt-get install build-essential
  • Add chip user to i2c group: sudo adduser chip i2c

NOTE: Some GPIO pins require root or sudo.

Getting Started

npm install chip-io johnny-five

Boilerplate Program

var five = require('johnny-five');
var chipio = require('chip-io');

var board = new five.Board({
  io: new chipio()
});

board.on('ready', function() {
  // do Johnny-Five stuff
});

Examples

See examples folder as well as Johnny-Five examples.

API

See Johnny-Five API docs.

Pin Guide

Johnny-Five Compatible NameNumberSupported ModesRequires root or sudoInfo
LCD-D217Input
PWM018Input, Output, PWM
LCD-D419Input, Output
LCD-D320Input, Output
LCD-D621Input, Output
LCD-D522Input, Output
LCD-D1023Input, Output
LCD-D724Input, Output
LCD-D1225Input, Output
LCD-D1126Input, Output
LCD-D1427Input, Output
LCD-D1328Input, Output
LCD-D1829Input, Output
LCD-D1530Input, Output
LCD-D2031Input, Output
LCD-D1932Input, Output
LCD-D2233Input, Output
LCD-D2134Input, Output
LCD-CLK35Input, Output
LCD-D2336Input, Output
LCD-VSYNC37Input, Output
LCD-HSYNC38Input, Output
LCD-DE40Input, Output
LRADC51Analog
XIO-P053Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P154Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P255Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P356Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P457Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P558Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P659Input, OutputConnected to the built-in PCF8574A IO extender
XIO-P760Input, OutputConnected to the built-in PCF8574A IO extender
CSIPCK67Input
CSICK68Input
CSIHSYNC69Input
CSIVSYNC70Input, Output
CSID071Input, Output
CSID172Input, Output
CSID273Input, Output
CSID374Input, Output
CSID475Input, Output
CSID576Input, Output
CSID677Input, Output
CSID778Input, Output
I2CI2CUses I2C port 2 (TWI2-SCK and TWI2-SDA)

C.H.I.P. pinouts

Additional Features

TypeUsageJohnny-Five typeNotes
Battery Voltagenew chipio.BatteryVoltage();five.SensorReads battery voltage from the AXP290
Internal Temperaturenew chipio.InternalTemperature();five.ThermometerReads internal temperature from the AXP290
Status LEDnew chipio.StatusLed;five.LedControls status LED connected to GPIO2 on the AXP290

Keywords

FAQs

Last updated on 23 Jul 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc