Giter Site home page Giter Site logo

home-control's Introduction

Home-Control

A home control centre from the a smartphone.

History

I recently wanted to see how I can connect to a localhost server on my laptop through my smartphone. Turns out this is very easy if you know the IP address of your laptop. So I went on and created a small controller for my laptop, i.e. a web page with buttons to turn on/off programs.

Installation

This is a python Flask project, and the installation is the usual

$ git clone https://github.com/DanielAndreasen/Home-Control
$ cd Home-Control
$ pip install -r requirements.txt # Alternatively make a virtualenv first
$ export HC_secret='<a very long string>'  # Alternatively add this to your config file
$ python app.py

Simply open up the localhost at the port indicated after the last command and you will be able to see a simple control panel.

Connect your phone

You will need to know the IP of your hosting server. On Linux just run ifconfig to find it. I only tested this when the smartphone and laptop are on the same network! If they are, simply visit <your IP adress>:<PORT> and you are done!

Add/remove new entry

At the moment of writing, simple edit line 11 in app.py and add/delete the templates/main.html file according to your changes.

Add custom command

Sometimes you don't have the command available that you would like to issue. Maybe you want to run a script that fetch data and analyse it. Simply write this in a small script and add the script to your PATH.

home-control's People

Contributors

danielandreasen avatar dependabot[bot] avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.