Skip to content

Server for Spark Printer -- built in Ruby using Sinatra, RSpec, Capybara and DataMapper

Notifications You must be signed in to change notification settings

henryaj/Maker-Spark-Server

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Screenshot of server splash page

Spark Printer Server Code Climate

The pitch

We spend all day looking at screens. You look at a screen on the way to work, where you look at screens all day. When you get home, you look at a screen some more. You go to bed, and look at a screen the second you wake up.

Wouldn't it be nice not to have to look at a screen for once? To have something tangible and tactile?

We wanted to venture out of the comfortable space of web apps and build something physical.

The product

It's a tiny, wireless, RFID-enabled, open source personal printer.

Start by tapping your RFID card on the reader – Spark Printer will print out a link for you to follow. There, you can register and customise your printouts. Once set up, tap your card on the reader to receive a personalised, context-aware printout.

The server handles user signup and login, and parses and formats messages for printing before sending them to the printer using the Spark Cloud API.

The family

Spark Printer has several distinct components which work together. The repos are linked below.

  • Spark Printer Server – you're looking at it. A Sinatra webserver which controls the printer, handles user registration and login, allows users to customise their printouts and pulls in data from various APIs to print for users.
  • Spark Printer Firmware – C++ code and libraries for Spark Core. When hooked up to the right hardware, this handles reading RFID cards, sending them to the server, receiving print requests and controlling the printer.
  • Spark Printer Push Server – a simple node.js app that listens for messages from the Spark Core (specifically, announcements of the ID of RFID cards it reads) and forwards them on to the Spark Printer Server for processing.

Technologies

Back-end

  • Ruby
  • Sinatra
  • C++ and Spark Cloud
  • node.js
  • Postgres
  • DataMapper

Front-end

  • AngularJS
  • jQuery
  • Bootstrap

Hardware

Hosting

  • Dokku
  • Heroku & DigitalOcean

Testing

  • RSpec
  • Capybara
  • WebMock

APIs

About

Server for Spark Printer -- built in Ruby using Sinatra, RSpec, Capybara and DataMapper

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 92.7%
  • JavaScript 4.1%
  • CSS 2.6%
  • CoffeeScript 0.6%