NomiProject / LampByBluetoothPi

Control the I/O (like a lamp through a relay) pin of Raspberry Pi from a Client-Server Bluetooth application

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LampByBluetoothPi

Control the I/O (like a lamp through a relay) pin of Raspberry Pi from a Client-Server Bluetooth application

Requirements

  1. Python 2.7 or 3.6 Download Python interpreter here.

  2. Raspberry Pi 3 Model B Learn more about RasberryPi project.

  3. PyBluez and Bluetooth support

    sudo apt-get install python-pip python-dev ipython bluetooth libbluetooth-dev

    And then:

    sudo pip install pybluez

Setup

  1. Clone the repo (In your PC and RaspberryPi)

    $ git clone https://github.com/NomiProject/LampByBluetoothPi.git
    $ cd LampByBluetoothPi/
  2. In your RasberryPi, with bluetooth enabled, run:

    $ python server.py
    • Note: Opening server.py, you can change GPIO pin
  3. In your PC, with bluetooth enabled, run:

    $ python client.py -s OPTION
    • Note 1: OPTION can be: on, off or exit;
    • Note 2: Opening client.py, you can change Raspberry MAC address or uncomment some lines to search new devices

Developed by Allex Lima, Daniel Bispo, Paulo Moraes and Renan Barroncas with ❤️ using Python.

Copyright © 2017 LampByBluetoothPi - Licensed by MIT LICENSE.

About

Control the I/O (like a lamp through a relay) pin of Raspberry Pi from a Client-Server Bluetooth application

License:MIT License


Languages

Language:Python 100.0%