Paper UI / .item Files

hello

I am new to openhab and configured all with Paper UI. Now I try to use Google Home and I learned that the Item need a .item file for the tags to be present.

Can I now configure the Bindings and Things in Paper UI and the Item in the .item file?

If yes, I am not able to create an example for this:

squeezebox:squeezeboxplayer:0d3f82da:000420201034:power

what do I have to add to the Item file? or in the {}?

Item file:
Switch squeezeTransporterPower “TransporterPower” [“Switchable”] { squeeze=“squeezebox:squeezeboxplayer:0d3f82da:000420201034:power” }

https://docs.openhab.org/addons/bindings/squeezebox/readme.html
https://docs.openhab.org/addons/bindings/squeezebox1/readme.html

1 Like

thanks but my questions are not answered on the pages of your links…

hm. after some hours I get it to work…

Switch squeezeTransporterPower “Transporter” [“Switchable”] {channel=“squeezebox:squeezeboxplayer:0d3f82da:000420201034:power”}

maybe the error were spaces between { “…” } or the name channel - I still do not really understand what this name is for or related to…


This looks like you are using the 2.x Squeezebox Binding. So that means:

You may also link an Item with a Channel using the .items file located in the OPENHAB_CFBG/items/ folder. Information about available Channels and options can be found in the Binding readme or discovered via Paper UI.

In Paper UI select a Thing to learn about Channels it supports.

Linking an Item to a Channel is of the form {channel=“channel id”}.

When you browse to the Thing in PaperUI it lists all the Channels. You can find the channel id and even copy that ID to the clip board by clicking on the little squares icon.

thank you - it was not clear to use {channel=

I googled some examples and there it was different…

I guess I even can create two items with the same purpose like:
Switch squeezeTransporterPowerGoogleHome “Transporter” [“Switchable”] {channel="squeransportesqueezeboxplayer_0d3f82da_000420201034_power_}

Switch squeezeTransporterPower “Transporter Power” {channel=“squeezebox:squeezeboxplayer:0d3f82da:000420201034:power”}

because I don’t want to say: “hey google. power transporter power on” :wink:

and in the UI an name “Transporter Power” is better…

You can use one Item and override the label in the sitemap configuration or in the HABPanel widget.