GithubHelp home page GithubHelp logo

microbot's Introduction

Linux utility for MicroBot Push

This is a Linux utility for Naran MicroBot Push.

Deps

$ pip3 install bluepy

Usage

Find your device's bdaddr by using hcitool.

$ sudo hcitool lescan | grep mibp
XX:XX:XX:XX:XX:XX mibp

You need to get a token from the device first time. (Please add '-n' option in case of 1.x.x.x firmware.)

$ python3 ./microbot.py [-n] XX:XX:XX:XX:XX:XX
update token
connected
notify: ack with bdaddr
touch the button to get a token
waiting...

Touch the button on the device to continue the process.

notify: ack with token
disconnected

The token is stored in ~/.microbot.conf by default. Now you can use the device by using the token.

$ python3 ./microbot.py [-n] XX:XX:XX:XX:XX:XX
use existing token
connected
disconnected

If you need to set mode, depth or press&hole duration in case of 1.x.x.x firmware, please use -s option to set them in advance.

$ python3 ./microbot.py -n -s -m normal -d 25 -p 5 XX:XX:XX:XX:XX:XX
and then,
$ python3 ./microbot.py -n XX:XX:XX:XX:XX:XX

Simple server mode is added. This mode uses unix domain socket and its file path is /var/tmp/microbot-xxxxxxxxxxxx.

On server side:
$ python3 ./microbot.py -r -n XX:XX:XX:XX:XX:XX

On client side:
$ python3 ./microbot.py -n XX:XX:XX:XX:XX:XX

microbot's People

Contributors

kahiroka avatar rymsha 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.