#README
This is web interface for home automation using raspberry pi and golang project.
Feature:
- Turn On and Off.
- Dimming 220v light using slider.
- Motor speed control.
- API for turn on and off.
- Feedback for detecting that the device is actually turned on or off.
- Sense the current to calculate the estimated power and cost.
The feature will be added for the future:
- Chart.
- Schedule turn on and off.
- Sense the voltage value for better calculation of power and cost.
- Send voltage and current data to HADOOP for better historical data
and analitics using API or Socket programming.
#How to run
Several items that being use in this project, make sure you have install this before
running:
- go language
- gorilla mux (http://www.gorillatoolkit.org/pkg/mux)
- mrmorphic hwio (http://github.com/mrmorphic/hwio)
- pi blaster (https://github.com/sarfata/pi-blaster)
to start the web:
go run web.go
#Testing
Still no unit testing for this project.
#Electrical Schematic
See Circuit Folder
Component:
- Triac BT139
- Triac driver MOC3021
- Zero Crossing H11A1 or H11AA1
- Resistor 1k ohm 1 watt (the value depend on the current but minimum 1 watt)
- Fuse 3 amps/ 4 amps
- Lamp 5 watt for test
- Bridge Rectifier KBJ408G (if using H11A1)
- Tap the current using ACS712 module, connect the VCC to 5v
- Convert the ACS712 value to digital value using PCF8591 AD/DA converter, connect the VCC to 5v
- Use level shifter module to convert 5v to 3.3v before connect th PCF8591 to Raspberry Pi I2C interface
#Beware
Careful with the electrical component, make sure it all safe!!! You playing with 110v/220v voltage line..
Careful..
Careful..
#Contribute
Contact me