Default feedback sound

[static]

This section only contains one option, config_ver, which is used to track the config.ini file version. You are not supposed to change this value at any time.

A general update will work basing the old config.ini without any problem if there is no change required for adding new config options. But this also means that the config entities might be changed at some point. During the installation/updating, setup.sh will always check if the old config.ini file meets the latest requirement. If it doesn't, it will be overwrote by a new default config. The old config information will be dropped.

In this case, please do make sure that you have to re-modify the options' value after the installation/updating if needed.

Build Your Own Hardware

If you would like to have a customised setup, a APA102 IC based RGB LED strip will be needed. (ws2812 will be supported in the future)

Step 1

Create a file under hardware_specs folder, name it with the custom_ as prefix and end with .json:

cd hardware_specs
touch custom_<YOUR_HW_CONFIG_NAME>.json

Name this file in the correct way will prevent it being tracked by git tool, so that the update will not overwrite this specification file.

Step 2

Fill this file with a json formate specification. This json file should contain the following attributes:

Specification Json

Key

Type

Value

led_num

Integer

Number of LEDs

spi_bus

Integer

SPI bus number

spi_dev

Integer

SPI device number

power

Object

Optional - See below

button

Object

Optional - See below

Power Specs

If your LED strip has a power control, specify the GPIO that uses.

Key

Type

Value

gpio_pin

Integer

Number of the GPIO port

gpio_val

Integer

Output level, 1 for high and 0 for low

Button Specs

If you have a button connected, specify the GPIO that uses.

You may need an external pull-up/pull-down resistor connected to your button.

Key

Type

Value

gpio_pin

Integer

Number of the GPIO port

gpio_val

Integer

Active level, 1 for high and 0 for low

If you have a 24 LED strip with a power control on GPIO5, and you would also have a button connected to GPIO17, the following is an example that you need to put to the specification file:

Step 3

Change the config.ini, find the key model, give your hardware specification file name with out .json.

Step 4

Relaunch snips-skill-server

sudo systemctl restart snips-skill-server

Command Line Mode

If you would like to debug your hardware configuration, you can run the animation program with command line parameters. CMD input parameters will have higher priority than the parameters in the config.ini file, the missing parameters will be fetched from the config.ini file.