Giter Club home page Giter Club logo

spaberry's Introduction

SpaBerry

An IoT adapter for Balboa 9800CP control board, circa 1999.

Reads and simulates the protocol of the 8-button Balboa 51285 Deluxe Digital Control topside, aka VL801D, via an 8-pin RJ45 jack.

Monitor and control set temperature and spa mode through a web-based interface.
Combine with homebridge-spaberry module for Homekit / Siri control on Apple devices.

Application Mechanics

The app deploys a simple express webserver on the Pi returning JSON status and accepting commands via HTTP.

Requests for Spa status use the Pi to read a data and clock signal from the spa and decode the display. To get the current set temperature, a button press is simulated and the display is read again.

Button presses are achieved using the Arduino which intercepts and modifies the realtime control signal between the topside and the controller board. Currently implemented controls are temp up, temp down, and spa mode.

/json

{
  "bits": "0100011110111111111111000000000001000100000110001000001000001000000000000000",
  "display": "86F",
  "setHeat": 0,
  "mode": 0,
  "heating": 0,
  "tempUp": 0,
  "tempDown": 0,
  "blower": 0,
  "pump": 1,
  "jets": 0,
  "light": 0,
  "temperature": 86,
  "setTemp": 85
}

Requirements

This app was built and deployed using Raspberry Pi 3 model B and Arduino Uno R3 but should be compatible with other models. Lesser models of Pi may have insufficient performance for the signal processing.

Requires the pigpio node library, please review the installation instructions including the installation of the base C library.

You will need to assemble a hardware setup which intercepts the RJ45 topside-to-board communications and routes them to the Raspberry Pi and Arduino GPIO pins. A detailed log of this process and the reverse engineering of the protocol can be found here:

SpaBerry project log

Spaberry Wiring Diagram

Installation

The spaberry library is not a ready-to-deploy application but should be easily forked and adapted to your situation. Key variables in the header of comms.js and spaberry.ino should be modified to reflect the specific GPIO pinouts in use on the Arduino and Raspberry Pi.

Potential refinements

Future adaptations of the SpaBerry app may consider using the Arduino to both read and write the signal, as it is much more capable of reading the high-speed signal than the Pi, given the simpler architecture. This will require adapting the code to pass the data back via the USB serial interface.

Gratitude

Special thanks to the RaspberryPi.org community for documenting their previous efforts and paving he way for this project. Hope that this project can be of similar help to future explorers.

spaberry's People

Contributors

heisler3030 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.