Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[IHC / ELKO] Can’t add channel #9866

Closed
Githubuserjtb opened this issue Jan 18, 2021 · 5 comments · Fixed by #9956
Closed

[IHC / ELKO] Can’t add channel #9866

Githubuserjtb opened this issue Jan 18, 2021 · 5 comments · Fixed by #9956
Labels
bug An unexpected problem or unintended behavior of an add-on

Comments

@Githubuserjtb
Copy link

Expected Behavior

I was expecting that when clicking the "Add channel" button in the Channel tab on the IHC / ELKO Thing that the screen appearing would make it possible to add a channel to my IHC / ELKO Thing

Current Behavior

Instead I experience that the add channel window opens and keeps showing "Loading" for at least 8 hours (the longest I have had it wait)
Also one time the window displayed the following error message:
'Sorry

Requested content not found.
Debug information

Url: /settings/things/ihc:controller:IHCControllerBryggers/channels/new
Path: /settings/things/ihc:controller:IHCControllerBryggers/channels/new
Hash:
Params:
Query:
Route: (.*)

The error message appeared at the time where I had not enabled loading of project file and auto generation of channels

It can autogenerate channels from the file.

The log files does not provide any information on this

Steps to Reproduce (for Bugs)

  1. In the Openhab 3.0.0 GUI
  2. Having installed the IHC / ELKO Binding
  3. Having added the IHC / ELKO Thing making connection to the controller
  4. Enter the IHC / ELKO Thing page
  5. Go to the Channel tab
  6. Scroll to the bottom of the page and press the "Add Channel" button
  7. "Add Channel window opens and either displays the above message or keeps shoving "Loading"

Context

I am trying to add channels that will make me able to get or set values on IHC objects that are not in the auto generated channels

Your Environment

  • Version used: OpenHAB V. 3.0.0 and IHC / ELKO V. 3.0.0
  • Environment name and version Client: Browser: Safari on a Mac
  • Operating System and version (desktop or mobile, Windows 10, Raspbian Buster, ...): Openhabian 32bit V.1.6.2b on a Raspberry Pi 4 8 GB on a 16GB SD card
@Githubuserjtb Githubuserjtb added the bug An unexpected problem or unintended behavior of an add-on label Jan 18, 2021
@openhab-bot
Copy link
Collaborator

This issue has been mentioned on openHAB Community. There might be relevant details there:

https://community.openhab.org/t/cant-add-channel-to-ihc-elko-binding-on-oh-3-0-0/114485/3

@paulianttila
Copy link
Contributor

paulianttila commented Jan 23, 2021

When Main UI query channel types from rest interface, some of the channel types fails (html error 204 no content).

ihc:dimmer, ihc:pulse-output and ihc:rf-device-battery-level channels seems to fail, other types seems to work.

image

Failed channel types anyhow works fine via API explorer or via curl.

curl -X GET "http://localhost:8080/rest/channel-types/ihc:dimmer" -H "accept: application/json" -H "Authorization: Bearer xxxxxxxxxx

{"parameters":[{"description":"","label":"Resource Id","name":"resourceId","required":true,"type":"INTEGER","readOnly":false,"multiple":false,"advanced":false,"verify":false,"limitToOptions":true,"options":[],"filterCriteria":[]},{"defaultValue":"ReadWrite","description":"Direction of the channel. By default, channel is synchronized in both directions.","label":"Channel Direction","name":"direction","required":false,"type":"TEXT","readOnly":false,"multiple":false,"advanced":false,"verify":false,"limitToOptions":true,"options":[{"label":"Read Write","value":"ReadWrite"},{"label":"Write only","value":"WriteOnly"},{"label":"Read only","value":"ReadOnly"}],"filterCriteria":[]},{"description":"Command to react. If not defined, channel react to all commands.","label":"Command to React","name":"commandToReact","required":false,"type":"TEXT","readOnly":false,"multiple":false,"advanced":false,"verify":false,"limitToOptions":true,"options":[],"filterCriteria":[]},{"description":"If defined, binding send pulse rather than command value to IHC controller.","label":"Pulse Width","name":"pulseWidth","required":false,"type":"INTEGER","min":0,"max":4000,"stepsize":100,"readOnly":false,"multiple":false,"advanced":false,"verify":false,"limitToOptions":true,"unit":"ms","unitLabel":"milliseconds","options":[],"filterCriteria":[]},{"description":"If defined, binding use this level when ON command is received rather than resource maximum value. Level is anyhow limited to resource maximum value.","label":"ON Command Level","name":"onLevel","required":false,"type":"INTEGER","min":0,"max":100,"stepsize":1,"readOnly":false,"multiple":false,"advanced":false,"verify":false,"limitToOptions":true,"options":[],"filterCriteria":[]}],"parameterGroups":[],"description":"Generic dimmer channel","label":"Generic Dimmer","itemType":"Dimmer","kind":"STATE","stateDescription":{"readOnly":false,"options":[]},"tags":[],"UID":"ihc:dimmer","advanced":false}⏎

@paulianttila
Copy link
Contributor

I just recognised, that some of the channel-types are weird and doesn't match the binding channel descriptions.

https://github.com/openhab/openhab-addons/blob/main/bundles/org.openhab.binding.ihc/src/main/resources/OH-INF/thing/channels.xml

Example ihc-dimmer is ihc:dimmmer (additional m character). ihc:pulse-output doesn't exist at all.

Main UI query channel types and get correct ones from rest interface, but some reason ask those wrong types.

image

http://localhost:8080/rest/channel-types?prefixes=system,ihc
[ { "parameters":[
  ],
  "parameterGroups":[
     
  ],
  "label":"Signal Strength",
  "category":"QualityOfService",
  "itemType":"Number",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":4,
     "step":1,
     "readOnly":true,
     "options":[
        {
           "value":"0",
           "label":"no signal"
        },
        {
           "value":"1",
           "label":"weak"
        },
        {
           "value":"2",
           "label":"average"
        },
        {
           "value":"3",
           "label":"good"
        },
        {
           "value":"4",
           "label":"excellent"
        }
     ]
  },
  "tags":[
     
  ],
  "UID":"system:signal-strength",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Low Battery",
  "category":"LowBattery",
  "itemType":"Switch",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:low-battery",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Battery Level",
  "category":"Battery",
  "itemType":"Number",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":100,
     "step":1,
     "pattern":"%.0f %%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:battery-level",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Trigger",
  "kind":"TRIGGER",
  "tags":[
     
  ],
  "UID":"system:trigger",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Raw button",
  "kind":"TRIGGER",
  "tags":[
     
  ],
  "UID":"system:rawbutton",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Button",
  "kind":"TRIGGER",
  "tags":[
     
  ],
  "UID":"system:button",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Raw rocker button",
  "kind":"TRIGGER",
  "tags":[
     
  ],
  "UID":"system:rawrocker",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Device is operable when channel has state ON",
  "label":"Power",
  "category":"Switch",
  "itemType":"Switch",
  "kind":"STATE",
  "tags":[
     
  ],
  "UID":"system:power",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Location in lat./lon./height coordinates",
  "label":"Location",
  "itemType":"Location",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%2$s°N %3$s°E %1$sm",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:location",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Motion detected by the device",
  "label":"Motion",
  "category":"Motion",
  "itemType":"Switch",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:motion",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Controls the brightness and switches the light on and off",
  "label":"Brightness",
  "category":"Light",
  "itemType":"Dimmer",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":100,
     "pattern":"%d %%",
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:brightness",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Controls the color of the light",
  "label":"Color",
  "category":"ColorLight",
  "itemType":"Color",
  "kind":"STATE",
  "tags":[
     
  ],
  "UID":"system:color",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Controls the color temperature of the light",
  "label":"Color Temperature",
  "category":"ColorLight",
  "itemType":"Dimmer",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":100,
     "pattern":"%d",
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:color-temperature",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Change the sound volume of a device",
  "label":"Volume",
  "category":"SoundVolume",
  "itemType":"Dimmer",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":100,
     "pattern":"%d %%",
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:volume",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Mute audio of the device",
  "label":"Mute",
  "category":"SoundVolume",
  "itemType":"Switch",
  "kind":"STATE",
  "tags":[
     
  ],
  "UID":"system:mute",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "label":"Media Control",
  "category":"MediaControl",
  "itemType":"Player",
  "kind":"STATE",
  "tags":[
     
  ],
  "UID":"system:media-control",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Title of a (played) media file",
  "label":"Media Title",
  "itemType":"String",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:media-title",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Artist of a (played) media file",
  "label":"Media Artist",
  "itemType":"String",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:media-artist",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Current wind direction expressed as an angle",
  "label":"Wind Direction",
  "category":"Wind",
  "itemType":"Number:Angle",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":360,
     "pattern":"%.0f %unit%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:wind-direction",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Current wind speed",
  "label":"Wind Speed",
  "category":"Wind",
  "itemType":"Number:Speed",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%.1f %unit%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:wind-speed",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Current outdoor temperature",
  "label":"Outdoor Temperature",
  "category":"Temperature",
  "itemType":"Number:Temperature",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%.1f %unit%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:outdoor-temperature",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Current atmospheric relative humidity",
  "label":"Atmospheric Humidity",
  "category":"Humidity",
  "itemType":"Number:Dimensionless",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%.0f %%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:atmospheric-humidity",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Current barometric pressure",
  "label":"Barometric Pressure",
  "category":"Pressure",
  "itemType":"Number:Pressure",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%.3f %unit%",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"system:barometric-pressure",
  "advanced":false

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Displays IHC / ELKO controller state",
  "label":"Controller State",
  "itemType":"String",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:controller-state",
  "advanced":true

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Displays IHC / ELKO controller uptime in seconds",
  "label":"Controller Uptime",
  "itemType":"Number",
  "kind":"STATE",
  "stateDescription":{
     "pattern":"%.3f sec",
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:controller-uptime",
  "advanced":true

},
{
"parameters":[

  ],
  "parameterGroups":[
     
  ],
  "description":"Displays IHC / ELKO controller date and time",
  "label":"Controller Date and Time",
  "itemType":"DateTime",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:controller-time",
  "advanced":true

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Pulse width in milliseconds. If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"openHAB state is inverted compared to IHC output/input signal",
        "label":"Inverted Signal",
        "name":"inverted",
        "required":false,
        "type":"BOOLEAN",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic switch channel",
  "label":"Generic Switch",
  "itemType":"Switch",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:switch",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"openHAB state is inverted compared to IHC output/input signal",
        "label":"Inverted Signal",
        "name":"inverted",
        "required":false,
        "type":"BOOLEAN",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic contact channel",
  "label":"Generic Contact",
  "itemType":"Contact",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:contact",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic number channel",
  "label":"Generic Number",
  "itemType":"Number",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:number",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding use this level when ON command is received rather than resource maximum value. Level is anyhow limited to resource maximum value.",
        "label":"ON Command Level",
        "name":"onLevel",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":100,
        "stepsize":1,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic dimmer channel",
  "label":"Generic Dimmer",
  "itemType":"Dimmer",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:dimmer",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic datetime channel",
  "label":"Generic Datetime",
  "itemType":"DateTime",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:datetime",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic string channel",
  "label":"Generic String",
  "itemType":"String",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:string",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"ReadWrite",
        "description":"Direction of the channel. By default, channel is synchronized in both directions.",
        "label":"Channel Direction",
        "name":"direction",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           {
              "label":"Read Write",
              "value":"ReadWrite"
           },
           {
              "label":"Write only",
              "value":"WriteOnly"
           },
           {
              "label":"Read only",
              "value":"ReadOnly"
           }
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"Command to react. If not defined, channel react to all commands.",
        "label":"Command to React",
        "name":"commandToReact",
        "required":false,
        "type":"TEXT",
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     },
     {
        "description":"If defined, binding send pulse rather than command value to IHC controller.",
        "label":"Pulse Width",
        "name":"pulseWidth",
        "required":false,
        "type":"INTEGER",
        "min":0,
        "max":4000,
        "stepsize":100,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"Generic roller shutter channel",
  "label":"Generic Roller Shutter",
  "itemType":"RollerShutter",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":false,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:rollershutter",
  "advanced":false

},
{
"parameters":[
{
"description":"Serial Number of RF device in decimal format.",
"label":"RF Device Serial Number",
"name":"serialNumber",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"RF device low battery warning.",
  "label":"RF Device Low Battery Warning",
  "category":"Battery",
  "itemType":"Switch",
  "kind":"STATE",
  "stateDescription":{
     "readOnly":true,
     "options":[
        
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:rf-device-low-battery",
  "advanced":false

},
{
"parameters":[
{
"description":"Serial number of RF device in decimal format.",
"label":"RF Device Serial Number",
"name":"serialNumber",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "description":"RF device signal strength.",
  "label":"RF Device Signal Strength",
  "category":"QualityOfService",
  "itemType":"String",
  "kind":"STATE",
  "stateDescription":{
     "minimum":0,
     "maximum":4,
     "readOnly":true,
     "options":[
        {
           "value":"0",
           "label":"No signal"
        },
        {
           "value":"1",
           "label":"Weak"
        },
        {
           "value":"2",
           "label":"Average"
        },
        {
           "value":"3",
           "label":"Good"
        },
        {
           "value":"4",
           "label":"Excellent"
        }
     ]
  },
  "tags":[
     
  ],
  "UID":"ihc:rf-device-signal-strength",
  "advanced":false

},
{
"parameters":[
{
"description":"",
"label":"Resource Id",
"name":"resourceId",
"required":true,
"type":"INTEGER",
"readOnly":false,
"multiple":false,
"advanced":false,
"verify":false,
"limitToOptions":true,
"options":[

        ],
        "filterCriteria":[
           
        ]
     },
     {
        "defaultValue":"1000",
        "description":"Long press time in milliseconds.",
        "label":"Long Press Time",
        "name":"longPressTime",
        "required":true,
        "type":"INTEGER",
        "min":0,
        "max":5000,
        "stepsize":1000,
        "readOnly":false,
        "multiple":false,
        "advanced":false,
        "verify":false,
        "limitToOptions":true,
        "unit":"ms",
        "unitLabel":"milliseconds",
        "options":[
           
        ],
        "filterCriteria":[
           
        ]
     }
  ],
  "parameterGroups":[
     
  ],
  "label":"Push Button Trigger Channel",
  "kind":"TRIGGER",
  "tags":[
     
  ],
  "UID":"ihc:push-button-trigger",
  "advanced":false

}
]

@ghys do you have any idea why Main UI query wrong channel types?

@ghys
Copy link
Member

ghys commented Jan 24, 2021

@paulianttila on this screen the UI loads the channel types marked as extensible in the thing type, they appear to be indeed wrong here:

extensible="switch, contact, number, dimmmer, datetime, string, rollershutter, pulse-output, rf-device-battery-level, rf-device-signal-strength, push-button-trigger">

@paulianttila
Copy link
Contributor

Damn, that's a really old bug. I was reading and reading the channel definitions and forget totally this extensible stuff. I was pretty sure, that the issue isn't in the binding side as channel definitions seemed to correct and it has been working fine with Paper UI 😊

Fix done. Thanks @ghys

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior of an add-on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants