This is a skill for picroft that will interact with the GPIO and 8 Swich Relay + LCD
This requires a Picroft install on the RPi you can find instructions on the home.mycroft.ai site. Be sure that mycroft user has the following the group for gpio An LCD1602
These are required for doc generation.
- graphviz
- sphinx
- python-rpi.gpio
- python3-rpi.gpio
GPIO Pins used to this project
Project has been made with GPIO Extension Board
Pins connected to the RelaySwitch (27,17,22,05,06,13,19,26)
The documentation is done by sphinx with some of it in the code. The following will generate the html docs.
make docs
You can then find the generated html in docs/build/html/index.html
. Open that file in your browser and you should be able to navigate the docs.
First method
msm install https://github.com/smolino/skill-gpio8s-lcd.git
Second method
Once you have a picroft image configure it for SSH access. Change the Makefile ip address for the RPi you installed the image onto. Also create the folder /opt/mycroft/skills/skill-gpio8s-lcd
on the RPi for the installer.
make install.pi
This will installl this source onto the RPi.
make test.pi
This will run a test to be sure you have access to the gpio be sure to test on the system in a simular manner as mycroft.
Once installed on a paired Picroft you should be able to issue commands:
Turn Switch On
Turn Switch Off
Turn Light on
Turn Light Off
Turn Fan On
Turn Fan Off
Turn Living On
Turn Living Off
Turn Bathroom On
Turn Bathroom Off
Turn Kitchen On
Turn Kitchen Off
Turn Lamp On
Turn Lamp Off
Turn Bedroom On
Turn Bedroom Off
And Picroft respond
Switch is On
Switch is Off
Light is on
Light is Off
Fan is On
Fan is Off
Living is On
Living is Off
Bathroom is On
Bathroom is Off
Kitchen is On
Kitchen is Off
Lamp is On
Lamp is Off
Bedroom is On
Bedroom is Off
LCD shows status
Remember to add mycroft user to gpio group:
sudo usermod -g gpio mycroft
sudo chown mycroft i2c-1
sudo apt-get install rpi.gpio
sudo pip install GPIO
sudo pip install smbus2
vocab - This captures entities used by the skill to understand the vocal command.
dialog - This is used for responces back to the users.