@lasseborly/squegg-sdk

Unofficial SDK for the SQUEGG Smart Hand Grip Trainer.


Keywords
sdk, squegg, ts, typescript
License
MIT
Install
npm install @lasseborly/squegg-sdk@0.1.2

Documentation

Squegg SDK

This is an UNOFFICIAL package and is in no way endorsed or affiliated with the official SQUEGG Smart Hand Grip Trainer product.

That said it is a great product and can be aquired from mysquegg.com and Amazon.

squegg

Demo

Usage

$ npm install @lasseborly/squegg-sdk
import { parseSquegg } from "@lasseborly/squegg-sdk";

/* 
 * Character codes should come from the device itself and it's your job to
 * convert them into an array of numbers. dataViewToArray is a utility function
 * that is useable if you use it on a web platform.
 */

const exampleCharCodes = [49, 57, 49, 49, 57, 46, 54, 50, 55];

parseSquegg(exampleCharCodes);
// { strength: 19.6, isSqueezing: true, batteryCharge: 100 }