What’s the point in that?
Note a channel doesn’t necessarily provide all the information it takes to interpret the value (such as scale factor and unit for example) so you must manually provide that anyway, it wouldn’t be less work than to create an item and transformation, eventually.
If you just want to check some value, create a dummy item and delete it when you don’t need it any more. You don’t have to expose items to the GUI.
To me sounds like overengineering, and that’s just overcomplicating things.
Violates the KISS principle.
What’s wrong with deploying multiple rules? Safer and clearer than to have some conditional all-in-one cryptic timer code that handles all the cases.
And if you want a single widget to handle multiple weekday use cases, you can (and have to anyway) create it yourself.
Exactly what you point out, just the opposite. Not needing to create a dummy item just to delete it afterwards - only to see what kind of information that is provided.
Channels now provide item type (all bindings), unit hints (many), we have default unit formatting. That is plenty to show a value.
With Proposal to suggest file syntax for things and items to users · Issue #4509 · openhab/openhab-core · GitHub integrated, it would be great if one could generate the suggested item syntax directly from the thing channel view - already knowing that it has an interesting value.
“channels” don’t store states. The binding would send the state via the channel, to an item, who will then store the state.
So even if you can, and in JRuby creating an item on the fly and discarding it is extremely easy to do, you’d still need to then wait for the next time the binding updates the channel for that temporary item to receive the next state.
If channels were to store the state (just so you can query its value whenever you want to), then that would be duplicating state storage.
Right now, you can directly receive channel triggers in rules without dealing with items, but this may not be what you had in mind.
This is a great idea! You should mention this in that github issue.
I’m fully aware, but that doesn’t mean there couldn’t be a lastState
cached on each channel that is used to show the value. Of course no persistence etc. (I’m also aware of the Refresh command as well as the isLinked() concept that is there to avoid “costly” operations against a device, but for many devices this isn’t a problem in sense that a binding or hub type device caches latest values).
I know about workarounds, but if I wanted this just for myself, I would have solved it and not discussed it here. The only reason I’m posting here is that I think this feature would benefit many users, especially newcomers and less technical users.
BTW I’m using your JRuby thing/item templating scripts GitHub - jimtng/openhab-itemsgen: Generate .things and .items files for OpenHAB using pre-set templates. on my cottage installation, thanks! I recommend this to any user that has an installation with multiple, identical devices!
BRG
Maybe open a GitHub issue/request and see what the maintainers say about it? If there’s no protest then just open a PR
Cool, I’m glad it’s useful for you.
I have since moved on to directly creating my things, items and sitemaps in Jruby instead of generating .items/.things/.sitemap files.
I’m hoping one day I’ll clean it up and publish that too. It still uses the same .yaml source, more or less, but the template creation would need a bit of ruby knowledge as it is now. Maybe I can abstract it in a yaml structure too!
Please keep in mind, a Binding should not store any values internally!
I imagine it could be implemented in the ThingHandler so that bindings would need to store anything.
Many bindings do have some sort of (partial) data cache. Example problems that a developer needs to solve:
- Merging data from multiple remote calls/service invocations
- Caching data that spans multiple OH items coming from rate limited services
- Responding to Refresh commands to such services, if you have 20 channels you receive 20 refresh commands.
Done: Show raw channel value without linking channel to item · Issue #4560 · openhab/openhab-core · GitHub
I would like more badges in the location cards.
For example, I would like to see an icon when the robot vacuum cleaner or washing machine is running or when a smart socket is switched on.
At the moment, this only seems to be possible in a cumbersome way.
I don’t think so at all.
There’s no real benefit in (faster) seeing values that you don’t know yet if you need them at all.
It’s quite the opposite approach of reading posts and docs in the first place, come up with a plan what you actually want to accomplish, and then figure out how to accomplish it.
You can get along with reading a binding’s docs on what values it provides, no need to ‘see’ them. Doing it this way round is way more reliable, planful, rational, less prone to errors than to ‘lets see what’s there and spontaneously do something with it’.
We should not encourage people to handle their home automation development process like that more than we already do. That’s quite a toxic proposal.
Plus, not at all compatible with openHAB architecture as the other responders also told you.
Wow… just wow… I considered this thread to be some sort of brainstorm session. Brainstorms usually follow a set of rules like:
Don’t criticize other collaborators’ ideas
Brainstorming is impossible without mutual respect—teams need to be comfortable speaking their minds and taking risks. As we’ve noted in our article on psychological safety, just like trust, “psychological safety is fragile: it builds slowly, but breaks down very quickly.” Be sure to remind your brainstorming collaborators that there are no bad ideas.
I guess I was wrong.
- Android auto support for android app
- homekit support but with homekit as server. i mean for example i have bticino living now but there is no binding LNow support homekit i connect to openhab via homekit. (I what i doing now using homeassistant as homekit server and passing states via mqtt to openhab)
- Black list in persistence, very userfull for raspberry pi (orange pi etc) users that use sd a storage, actually i have to tell to persistence what i want to log… but is very boring when you have 1000 items…
- channel preview: ability to see the value of a channel also without create an item… very often is not clear if a channel is exactly what we want… see his value without create a item (and his persistence that remain also after item deletion)
- Remap icon ranges in sitemap. for example i have an icon that show the power consumption from 0 to 100 and i want to use this icon with the power consumption of my house but the house power go from 0 to 3300watt icons only from 0 to 100
Thanks for deveoloping Openhab
This has been added with openHAB 4.3:
You could/should voice your opinion here:
Where can I read more about specific examples of how to use this function in UI? I’m having trouble in finding examples on how to apply such an exclusion to a single item in UI.
I would love to see modular sitemaps where we can have fragments of sitemaps in separate files and some way of including those fragments in a sitemap…
This already has been discussed a couple of times: