How to assign a hardware in my snap application?

XiaoGuo Liu xiaoguo.liu at
Thu Aug 25 02:33:53 UTC 2016


On Series 16, we need to use interface to make the connection between the
Ubuntu core and Snap apps in order to make use of the hardware. Previously,
on 15.04, I used the following command do get the hardware assignment:

(RaspberryPi2)ubuntu at localhost:~$ sudo snappy hw-assign piglow.sideload
'piglow.sideload' is now allowed to access '/dev/i2c-1'

Currently, I list all of the interfaces from raspberry pi snappy image, but
I do not find any interface which corresponds to my requirement.  Do I need
to wait for the interface? or I did it wrongly? What should be the right
interface to use in my case?

ubuntu at localhost:~/apps$ snap interfaces
Slot                    Plug
:bluetooth-control      -
:firewall-control       -
:fuse-support           -
:hardware-observe       -
:home                   -
:kernel-module-control  -
:locale-control         -
:log-observe            -
:mount-observe          -
:network                piglow-app,snapweb
:network-bind           piglow-app,snapweb,webcam-webui
:network-control        -
:network-observe        -
:opengl                 -
:ppp                    -
:process-control        -
:snapd-control          snapweb
:system-observe         -
:system-trace           -
:timeserver-control     -
:timezone-control       -
:tpm                    -
-                       webcam-webui:camera

Also, I find that the "camera" interface is missing in the current image.

Thanks & best regards,

XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Snapcraft mailing list