Skip to content

jcasoft/external-services

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Mycroft Webcaht Client and Bluetooth presence service for Mycroft

Mycroft Webchat Client and Mycroft bluetooth service getting the MAC address of a Bluetooth device.

Requirements

This code requires the bluetooth module to be installed. On Mark1, Picroft or Ubuntu/Debian systems, this can usually be done with the following commands:

sudo apt-get install bluetooth bluez blueman

sudo reboot now

For use with Mark1 or if you have problem with Picroft you need a USB Bluetooth dongle like this Screenshot

Installation

For all installations

cd /opt/mycroft

if the installation is in Mark1 or Picroft

sudo su mycroft

For all installations

git clone https://github.com/jcasoft/external-services.git

if the installation is in Mark1 or Picroft

exit

For all installations

sudo chmod -R a+rwx /opt/mycroft/external-services

Installation of USB bluetooth dongle on Mark1 or if you have problem with Picroft

Plug the USB bluetooth dongle

Mark1 command line

    hciconfig -a hci1

    sudo hciconfig hci1 up

    sudo reboot now

Configuration

Locate your configuration file and add the section detailed belove

Linux

nano ~/.mycroft/mycroft.conf

Mark1 or Picroft

nano /home/pi/.mycroft/mycroft.conf

and

sudo su mycroft
nano /home/mycroft/.mycroft/mycroft.conf
exit

Add this section to mycroft.conf

"Proximity": {
    "proximity_enabled": true, 
    "proximity_data": [
        {"bt_id": "00:00:00:00:00:1A","name": "Juan Carlos"},
        {"bt_id": "00:00:00:00:00:1B","name": "Adriana"},
        {"bt_id": "00:00:00:00:00:1C","name": "Daniella"},
        {"bt_id": "00:00:00:00:00:1D","name": "Enzo"},
        {"bt_id": "00:00:00:00:00:1E","name": "Gianluca"}
    ]
}

Fill the bt_id with bluetooth MAC address of your smartphone

Screenshot

How to start Presence service

Linux

cd /opt/mycroft/external-services
bash start-presence.sh linux

cd ~/mycroft-core
bash start-mycroft.sh debug

Mark1 or Picroft

cd /opt/mycroft/external-services
bash start-presence.sh mark1   
or
bash start-presence.sh picroft

How to stop Presence service

Linux, Mark1 and Picroft

cd /opt/mycroft/external-services
bash stop-presence.sh

How to start Webchat service

Linux

cd /opt/mycroft/external-services
bash start-webchat.sh linux

cd ~/mycroft-core
bash start-mycroft.sh debug

Mark1 or Picroft

cd /opt/mycroft/external-services
bash start-webchat.sh mark1
or
bash start-webchat.sh picroft

How to stop Webchat service

Linux, Mark1 and Picroft

cd /opt/mycroft/external-services
bash stop-webchat.sh

How to start both service

Linux

cd /opt/mycroft/external-services
bash start-all.sh linux

cd ~/mycroft-core
bash start-mycroft.sh debug

Mark1 or Picroft cd /opt/mycroft/external-services

bash start-all.sh mark1
or   
bash start-all.sh picroft

How to stop both services

Linux, Mark1 and Picroft

cd /opt/mycroft/external-services
bash stop-all.sh

How to access Web chat from your browser

http://localhost:9090
or
http://MYCROFT-IP-ADDRESS:9090

How to use Webcaht Client and Bluetooth presence service

Webcaht Client and Bluetooth presence service

Notes

Give me a Github star and follow me on YouTube !, to continue developing and improving skills and services in Mycroft

Credits

Author: jcasoft
        Juan Carlos Argueta

About

Mycroft Webchat Client and Mycroft bluetooth service getting the MAC address of a Bluetooth device for detect presence for Mycroft

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published