Skip to content

marcbenito/domoPiJs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

domoPiJs

Domotics system based on RaspBerryPI and NodeJS

This project is based on johnny-five Framework

Installation on Rasperry PI

wget http://node-arm.herokuapp.com/node_latest_armhf.deb
sudo dpkg -i node_latest_armhf.deb
node -v

Setup and Assemble Arduino

  • Download Arduino IDE
  • Plug in your Arduino or Arduino compatible microcontroller via USB
  • Open the Arduino IDE, select: File > Examples > Firmata > StandardFirmata
  • Click the "Upload" button.

If the upload was successful, the board is now prepared and you can close the Arduino IDE.

Running the project:

First of all, we have to configure the Arduino for work with Raspberry using firmata. Follow this instructions

git clone git://github.com/sbennel/domoPiJs.git && cd domoPiJs

npm install

bower install

npm start

For windows Users/Testing:

Download and install Visual Studio 2012

Use this set of commands:

git clone git://github.com/sbennel/domoPiJs.git && cd domoPiJs

npm install --msvs_version=2012

bower install

npm start

configure the devices!!

go to the file: /server/app_main.js

and replace the following lines for your sensors:

var house = new HouseController(function() {
    require('./router')(app, house);
    app.listen(CONFIG.serverPort);
    console.log('Server listening on port: %d', CONFIG.serverPort);
    house.append( new HouseController.Light(3,'Light')); //For swhitch lights. Number 3 is the PIN

    //Other avaliable devices
    //house.append( new HouseController.Percentage(6,'Percentage Dev')); //For PWM usage
    //house.append( new HouseController.TempSensor('A0','Temperature sensor lm35')); //for LM35 Sensor
});

http://localhost:3000

About

Domotic system with RaspBerry and NodeJS

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published