Skip to content

This is part of a project to manage a coffee maker at home from a Android mobile phone. It's made up of an Android app written in Kotlin as the front-end, Firebase service as the back-end and Raspberry PI 3 as a single board computer with a script written in Javascript running on Node.JS and integrated to a coffee maker with water level sensors.

License

Notifications You must be signed in to change notification settings

ivanph1017/CoffeeMakerJS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CoffeeMakerJS

This is part of project to manage a coffee maker remotely. More details can be found here:

The script was developed in Javascript following ECMAScript 2016 and run on Node.JS. More details can be found here:

Wiring

The full list of devices required are below:

  • Android smartphone
  • Raspberry PI 3
  • Relay module
  • Coffee maker
  • Breadboard
  • 2 float ball liquid sensor
  • 2 resistors of 10k ohms
  • Many jump wires with female and male header connectors
  • Many jump wires with female and female header connectors
  • Many jump wires with male and male header connectors

Then, the circuits should look like the image below:

Circuit

The relay module is like our switch, it can open or close the electric circuit of the coffee maker. In other words, it's the device that turns on/off our machine. For more details of how a relay works, follow the next link:

Setting up

First of all, we might end up accesing our Raspberry PI 3 on Wifi, so enabling SSH and setting up our SSID and password come handy.

Then, it's necessary to install Node.JS in order to be run the script on our Raspdian. Therefore, it's necessary to follow Node.JS. Nonetheless, it's thoroughly recommended to follow the NVM guide to manage both Node.JS and npm in an easier way.

Later, it's time to set up the libraries that will be part of our project.

  • Onoff doc: The GPIO library that allow us to access GPIO Raspberry PI 3 pins.
  • Firebase doc: Here's a complete guide detailed step by step to add Firebase library

Finally, install PM2 library globally in order to auto run our script on startup and monitor it.

Here's an article about Node.JS modules and an explanation about exporting primitive values by module.exports:

About

This is part of a project to manage a coffee maker at home from a Android mobile phone. It's made up of an Android app written in Kotlin as the front-end, Firebase service as the back-end and Raspberry PI 3 as a single board computer with a script written in Javascript running on Node.JS and integrated to a coffee maker with water level sensors.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published