Hi everyone!
Let me start by apologizing if I am posting in the wrong forum. I’m fairly new and this is my first post ever.
I’m new to Home Assistant but have been working in automation for quite a while. I’ve installed HA about a week ago and am currently working on automating my entire house.
One of the things I can’t seem to figure out and am not sure if it’s possible is the following:
I have created 2 different remote control cards, made with the custom:button-card and some other HACS additions. One is the full remote with 24 buttons, and one is a mini remote with just the basics.
What i would like to accomplish is the full remote card replacing the mini remote card by pressing a button on the mini remote. So on my “Remote” tab, the default should be a mini remote. But when i press the “full remote” button, i’d like another card to pop up.
Create an input boolean that stores the mini / full state. Set the ta action of one of the buttons on both cards to toggle the state of this input boolean.
Use the state switch card to display which card you want depending on the input boolean state.
Thanks Tom, like i said, i’m fairly new to home assistant and haven’t used the state switch yet… Reading through the docs it indeed does exactly what I need it to do, and besides that… it makes me want to reprogram all the cards i have previously made…
Follow up question:
I’ve followed the github instructions and got it working on a small demo card.
When i press the button on the remote, an entities card shows up with 3 lights. Pressing the button again shows 3 different lights. Glad i got that bit figured out…
Question is, when i check the state of the input_boolean, it is set to either “on” or “off”.
In the instructions example on github they are using states like “home” and “away”
How can i change the state of the input boolean to “full” and “mini” instead of “on” and “off”?
You can’t. The state of an input boolean is always on or off. Some domains like the binary sensor that also has the states on or off can be made to display these states differently in the front end by applying a device class. But the input boolean does not have device classes.
Ah, thanks… I guess one of the biggest challenges in properly programming HA is not only the skill of programming but also knowing the different options…
I’m completely stuckj though… I have made a small card that seems to work, basically copied it from the github tutorial, added my own values, and it worked… On my existing remote card however i’m using a different card type, and i cannot for the love of God figure out how to make this a state switching card…
So the plan is to display the small remote by default, and switch to the full remote by pressing the top right button.
I would like it if you could give me a hint or some more detailed explanation on how to proceed and what i seem to be doing wrong instead of giving me the code, as I am in a learning process. Figuring it out with a little help will help me get better instead of plainly just copying code which will not educate me at all…