Skip to content
/ bb8 Public

BB-8 wasn't built to just sit on your desk. It wants to tell you stuff. Let it.

Notifications You must be signed in to change notification settings

jschementi/bb8

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BB-8 Notifications

BB-8 wasn't built to just sit on your desk. It wants to tell you stuff. Let it.

BB-8 notifying you if your shell commands succeed or not BB-8 shaking on error

Prerequisites

  • A Sphero BB-8 (though not tested, it may work with other Sphero products).

  • Only tested on Mac OS, though may work on other systems. Instructions assume you use Homebrew and Zsh - need to be adapted for other setups.

Install

brew install node                                 # Install Node.js
git clone [email protected]:jschementi/bb8.git       # Clone this repo
cd bb8 && npm install                             # Install dependencies
node index.js                                     # Run notification server
source notify.zsh                                 # Enable notifications for
                                                  # command exit codes (add to
                                                  # .zshrc to always enable).

Usage

When running a command that exits successfully (exit code == 0), BB-8 will glow green.

Otherwise (exit code != 0), BB-8 will glow red.

Inspiration

The Das Keyboard 5Q got me thinking about using lights and color to provide custom notifications. I've always wanted a "build broken" orb for my desk, but never got around to doing it. When my kids asked to play with BB-8, I thought it would be just too perfect if I could just hack BB-8 to be my own custom status light, since it normally sits on my desk doing nothing. Once I found the Sphero SDK, I first felt stupid for owning this thing for 8 months and not hacking it yet. Shame is a powerful motivator, so here we are.

I didn't back the Das Keyboard 5Q because I prefer compact keyboards (without a numpad), so can't wait to see if Das Keyboard makes a compact version.

Next Steps

Shell integration was just the low-hanging-fruit to start with. Having BB-8 glow red/green based on process exit codes handles a bunch of situations I wanted, like build and test failures, but zero=green non-zero=red is a very narrow style of notification.

Ultimately, it'd be nice to have a local service that recieves arbitrary events from your system or the internet, and responds to them in customizable ways.

For example:

  • Pulse red when I have a meeting
  • Shake head "yes" when I finish a todo.txt task

Contribute

Pull Requests welcome!

About

BB-8 wasn't built to just sit on your desk. It wants to tell you stuff. Let it.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published