Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cascade-examples
rigado-node-hello-world
Commits
260eb575
Commit
260eb575
authored
Apr 07, 2018
by
Mikhail Vataleu
Browse files
Cleanup plugs; Add network-control plug; Update README;
parent
5d602b88
Changes
2
Hide whitespace changes
Inline
Side-by-side
README.md
View file @
260eb575
...
...
@@ -42,15 +42,19 @@ This application is using [Nordic-Thingy52-Nodejs](https://github.com/NordicPlay
#### RPI3 Ubuntu Core 16.04 (armhf)
*
Setup
[
development tools
](
https://developer.ubuntu.com/core/get-started/developer-setup
)
(
snap
classic)
*
```sh
```
sh
snap
install
classic
--edge
--devmode
sudo
classic
sudo
apt update
sudo apt install snapcraft build-essential git```
sudo
apt
install
snapcraft build-essential git
```
*
Install
[
BlueZ
](
http://www.bluez.org/
)
*
```sh
snap install bluez
snap connect bluez:bluetooth-control```
```
sh
snap
install
bluez
snap connect bluez:bluetooth-control
snap connect bluez:network-control
snap connect bluez:home
```
*
Go to the project directory run:
```snapcraft```
*
Result file is
`./deviceops-hello-world_0.0.1_armhf.snap`
...
...
@@ -67,34 +71,35 @@ This application is using [Nordic-Thingy52-Nodejs](https://github.com/NordicPlay
*
Install
[
BlueZ
](
http://www.bluez.org/
)
```
sh
snap
install
bluez
snap connect bluez:bluetooth-control
snap connect bluez:network-control
snap connect bluez:home
```
*
Copy
`./deviceops-hello-world_0.0.1_armhf.snap`
in to the gateway home directory.
*
Run install command:
`sudo snap install ~/deviceops-hello-world_0.0.1_armhf.snap --devmode --dangerous`
*
Run install command:
`sudo snap install ~/deviceops-hello-world_0.0.1_armhf.snap --dangerous`
*
Connect plugs:
```
sh
snap stop
--disable
deviceops-hello-world
snap connect deviceops-hello-world:network :network
snap connect deviceops-hello-world:bluetooth-control :bluetooth-control
snap connect deviceops-hello-world:network-control :network-control
snap start
--enable
deviceops-hello-world
```
## Troubleshoot
#### HCI
D
evices list is empty
#### HCI
d
evices list is empty
*
`sudo bluez.hcitool dev`
show empty list of devices.
*
`dmesg | grep blue`
show:
```
[ 1447.938933] audit: type=1400 audit(1522961095.899:76): apparmor="DENIED" operation="create" profile="snap.bluez.hcicofig" pid=4254 family="bluetooth" sock_type="raw" protocol=1 requested_mask="create" denied_mask="create"
```
*
Reinstall
[
BlueZ
](
http://www.bluez.org/
)
with
`--devmode`
flag:
```
sh
snap
install
bluez
--devmode
snap connect bluez:bluetooth-control
```
*
Enable HCI devices:
```
sh
sudo
bluez.bluetoothctl
power on
scan on
```
####
ERR code
CERT_NOT_YET_VALID when snapcraft
#### CERT_NOT_YET_VALID when snap
is
craft
ing
*
Switch
in
to
`classic`
mode.
*
Switch to
`classic`
mode.
*
Execute following commands:
```
sh
sudo
update-ca-certificates
...
...
snapcraft.yaml
View file @
260eb575
...
...
@@ -23,6 +23,6 @@ apps:
daemon
:
simple
restart-condition
:
always
plugs
:
-
home
-
network
-
network-control
-
bluetooth-control
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment