Chuletero

Thing <binding_id>:<type_id>:<thing_id> "Label" @ "Location" [ <parameters> ]

Ejemplos:

Thing network:device:webcam "Webcam" @ "Living Room" [ hostname="192.168.0.2", timeout="5000", ... ]
Thing astro:moon:home [ geolocation="50.12345,10.98765", interval=300 ]
Thing ntp:ntp:local [ hostname="de.pool.ntp.org" ] 
Bridge mqtt:broker:mosquitto "Mosquitto" [ host="127.0.0.1", secure=false, clientID="openHAB2"]
{
  // My OBI switches with Tasmota
  Thing topic XXX "XXXWohnzimmer" @ "Wohnzimmer" {
   Channels:
     Type string : reachable "Reachable" [ stateTopic="Home/xxx/LivingRoom/tele/LWT" ]
     Type switch : power "Power" [ stateTopic="Home/xxx/LivingRoom/stat/POWER", commandTopic="Home/xxx/LivingRoom/cmnd/POWER" ]
     Type number : rssi "WiFi Signal Strength" [ stateTopic="Home/xxx/LivingRoom/tele/STATE", transformationPattern="JSONPATH:$.Wifi.RSSI"]
 }
}
Bridge mqtt:broker:MyMQTTBroker [ host="192.168.178.50", secure=false, username="MyUserName", password="MyPassword"] {
  Thing topic sonoff_Dual_Thing "Light_Dual" @ "Sonoff" {  
    Channels:
      Type switch : PowerSwitch1  [ stateTopic="stat/sonoff_dual/POWER1" , commandTopic="cmnd/sonoff_dual/POWER1", on="ON", off="OFF"]
      Type switch : PowerSwitch2  [ stateTopic="stat/sonoff_dual/POWER2" , commandTopic="cmnd/sonoff_dual/POWER2", on="ON", off="OFF"]
      Type string : Version [stateTopic="stat/sonoff_dual/STATUS2", transformationPattern="JSONPATH:$.StatusFWR.Version"]
      }     
  Thing topic sonoff_TH_Thing "Light_TH" @ "Sonoff" {
    Channels:
      Type switch : PowerSwitch  [ stateTopic="stat/sonoff_TH/POWER", commandTopic="cmnd/sonoff_TH/POWER", on="ON", off="OFF" ]
      Type string : Version [stateTopic="stat/sonoff_TH/STATUS2", transformationPattern="JSONPATH:$.StatusFWR.Version"]
      Type number : Temperature [stateTopic="tele/sonoff_TH/SENSOR", transformationPattern="JSONPATH:$.AM2301.Temperature"]
      Type number : Humidity [stateTopic="tele/sonoff_TH/SENSOR", transformationPattern="JSONPATH:$.AM2301.Humidity"]
   }
} 
itemtype itemname "labeltext [stateformat]" <iconname> (group1, group2, ...) ["tag1", "tag2", ...] {bindingconfig}

Ejemplos:

Switch Kitchen_Light "Kitchen Light" {mqtt="<[...], >[...]" }
String Bedroom_Sonos_CurrentTitle "Title [%s]" (gBedRoom) {channel="sonos:..."}
Number Bathroom_WashingMachine_Power "Power [%.0f W]" <energy> (gPower) {channel="homematic:..."}

Number Livingroom_Temperature "Temperature [%.1f °C]" <temperature> (gTemperature, gLivingroom) ["TargetTemperature"] {knx="1/0/15+0/0/15"}
Switch Kitchen_Light_Switch "Kitchen Light" (Indoor_Lights) { channel="zwave:device:1a2b3c4d:node2:switch_binary" }
sitemap <sitemapname> label="<title of the main screen>" {
    [all sitemap elements]
}

Ejemplos:

sitemap demo label="My home automation" {
    Frame label="Date" {
        Text item=Date
    }
    Frame label="Demo" {
        Switch item=Lights icon="light"
        Text item=LR_Temperature label="Livingroom [%.1f °C]"
        Group item=Heating
        Text item=LR_Multimedia_Summary label="Multimedia [%s]" icon="video" {
            Selection item=LR_TV_Channel mappings=[0="off", 1="DasErste", 2="BBC One", 3="Cartoon Network"]
            Slider item=LR_TV_Volume
        }
    }
}
rule "<RULE_NAME>"
when
    <TRIGGER_CONDITION> [or <TRIGGER_CONDITION2> [or ...]]
then
    <SCRIPT_BLOCK>
end

Ejemplos:

rule "Escena Persianas de noche"
when
    Item Persianas_Noche received update ON or
    Item Escena_Persianas received command 1 or 
    Item SalNNorte_RockerSwitchChannelA received update OFF 
    //or Channel 'astro:sun:local:astroDusk#event' triggered START
then
     sendCommand(Persiana_Kendra_pos, 27)
     sendCommand(Persiana_Salon_Norte_Porcentaje_Item,22)
     sendCommand(PersianaPequeAInvitadosPorcentageItem, 0)
     sendCommand(PersianaGrandeInvitadosPorcentage,0)
     sendCommand(Persiana_SS_pos, 22)
     sendCommand(Persianas_Noche, OFF)

     logInfo("Persianas", "En modo noche")
end
Lighting   
Switchable  
ContactSensor  
CurrentTemperature  
CurrentHumidity  
Thermostat  
CurrentTemperature 
homekit:TargetHeatingCoolingMode 
homekit:CurrentHeatingCoolingMode 
homekit:TargetTemperature
WindowCovering  

Ejemplos:

Switch KitchenLights "Kitchen Lights" <light> (gKitchen) [ "Lighting" ]
Dimmer BedroomLights "Bedroom Lights" <light> (gBedroom) [ "Lighting" ]
Number BedroomTemperature "Bedroom Temperature" (gBedroom) [ "CurrentTemperature" ]
Group gDownstairsThermostat "Downstairs Thermostat" (gFF) [ "Thermostat" ]
Number DownstairsThermostatCurrentTemp "Downstairs Thermostat Current Temperature" (gDownstairsThermostat) [ "CurrentTemperature" ]
Number DownstairsThermostatTargetTemperature "Downstairs Thermostat Target Temperature" (gDownstairsThermostat) [ "TargetTemperature" ]
String DownstairsThermostatHeatingCoolingMode "Downstairs Thermostat Heating/Cooling Mode" (gDownstairsThermostat) [ "homekit:TargetHeatingCoolingMode" ]
#Common Problems

Otras anotaciones:

Listar nombres puertos usb usados en raspbian:

ls -l /dev/serial/by-id