Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

attiny-common

Package Overview
Dependencies
Maintainers
3
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

attiny-common

A common library for Tessel's ATTiny based modules

  • 0.1.1
  • latest
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

Attiny-common

This library is designed to encapsulate all of the shared behavior of Tessel's attiny-attx4 and ir-attx4 libraries. They share much of the same hardware design so most of the non-domain specific logic can be abstracted out. These features include:

  • Initilization
  • Firmware Updating
  • CRC Checking
  • SPI Transmissions
  • IRQ Handling

Install

npm install attiny-common

Usage

var Attiny = require('attiny-common');

// Create a new tiny agent
var attiny = new Attiny(hardware);

// Store our firmware checking and updating options
var firmwareOptions = {
  firmwareFile : FIRMWARE_FILE,
  firmwareVersion : FIRMWARE_VERSION,
  moduleID : MODULE_ID,
  signature : TINY84_SIGNATURE,
  crc : (CRC_HIGH << 8) | CRC_LOW,
}

// Initialize (check firmware version, update as necessary)
attiny.initialize(firmwareOptions, function(err) {
  console.log('done initializing module!');

  attiny.setIRQCallback(irqHit);
});

function irqHit() {
  console.log("IRQ is active");
}

Keywords

FAQs

Package last updated on 13 Nov 2017

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc