@huu I realized that conneting thru the other router is of no use (other than to show that the device can be added) since that router cannot talk to the HA instance. So I went back to the original TPlink Deco M5 and changed the password to be alphanumeric (no special chars). That didn’t help. Oh well…
@huu I tried following your other instructions…connected iPhone to Broadlink RM4 wifi, did the add device and universal remote and waited for it to discover device…no dice.It ends up as before saying that APP is searching for device AP named “Broadlink_WiFi_Device” and then times out
This gets weirder by the minute. I was about to throw in the towel and return the device when I went into integrations in HA and saw the RM4C-mini! This is quite mysterious to me since every time I tried to add the integration it asked for an IP address and any address I gave it failed. In any case, I was willing to accept magic and so I went to Developer tools and attempted to learn a command (simple power on/off for the TV). I got nowhere except that when I call the Learn Command service, the light on the RM4C mini goes on and when I point the remote and hit the power button it goes out. So SOMEHOW the HA is able to talk to the RM4C. How do I do a simple test to verify that HA can learn and send a command?
Glad you get somewhere, If its show up in HA integration then it definitely connected, Easiest way is use SmartIR custom component. Learning code in HA is complex and time consuming. Go have a look there and see if if your device brand is listed. They have all the common brand LG, Samsung TV, Daikin Aircon etc.
at this point you can try to get it in Broadlink app again. see if it can discover the device when your phone is in the same wifi. Wait at the last step when you choose RM4C but dont choose anything just wait few minutes.
Yes, definite progress. What is the easiest way for me to learn on IR command (Power on/off TV) just to satisfy myself that I can get HA to control a device via the RM4c?
I am able to add the device on the app now but of course that is of secondary importance to making it work with HA.
The intruction for RM4 to learn code is here
go here scroll down all the way to bottom look for your TV
“SmartIR/MEDIA_PLAYER.md at 5b1340b4bf7f475ecdf9d58651ee677620178845 · smartHomeHub/SmartIR · GitHub “
then put this in your configuration.yaml
switch:
- platform: broadlink
mac: MAC_ADDRESS
switches:
- name: Your TV
command_on: JgAcAB0dHB44HhweGx4cHR06HB0cHhwdHB8bHhwADQUAAAAAAAAAAAAAAAA=
command_off: JgAaABweOR4bHhwdHB4dHRw6HhsdHR0dOTocAA0FAAAAAAAAAAAAAAAAAAA=
restart HA and use the switch to turn on and off your TV
In case anyone experiences similar difficulties in getting their RM4C on the network and talking to HA, I think that the way I finally got it working was by using Rm-Configurator (GitHub - zchumager/RM-Configurator: Python CLI Tool to make RM Mini compatible with Home Assistant (HASSIO). Although, quite honestly I tried so many times with that code and the app, without apparent success, that it is now hard to say for sure what worked.
Once you have it in the HA integration then it will shown up as [remote.rm_name]… now you just need to create, script, switches, button etc to call on to it and blast IR signal out.
glad it worked. i got the bestcon rm4c and it was a nightmare. next time go for the original broadlink rm4. its alot easier.
What is the difference between them? Frankly, I got the RM4C on AliExpress because it was inexpensive enough that if it failed to work, I would not be upset. Is the RM4 you refer to on Ali as well?
Also, in your above post you had codes for command on and off but those differ for each TV, so I presume that was just for illustration?
They work exact same way, some seller sell both choose diff model when check out. The original broadlink maybe few dollars more, but with an advantage you can buy a special power cable (HTS-2 cable) with temp and humidity sensor to integrate into the RM4.
yes the code is just example
@huu I am wondering if it is possible to use an IR remote to control HA? I know I can lean IR and Send IR but can I react to IR (not for learning) to execute a script or action? If so, how is this setup?
I suspect not because the RM is built as a “IR transmitter” it can learn only when it put in a “learning mode” which it stay only for a short time and it will revert back to transmitter mode.
You would need a hardware IR reciever connected to the Pi, HA have a built in integration LIRC for that purpose.
@huu Thanks, I figured that might be the case but I thought perhaps someone had hacked the RM4c since it is obviously HW capable of receiving and transmitting. For example, I imagined putting HA into receive_command mode and wait for the IR but instead of storing it, passes it to HA as an event that can be used in some way. and then put it back in receive_mode.
@ihf1 i was thinking exactly the same as you. Have you progressed this? I’d rather purchase an off the shelf IR receiver than build one. I’m pretty new to HA and building my own electronics is a rabbit hole I’d rather not go down at the moment. Got too many other rabbit holes on the go
@HoundDog it works fine although I was a bit disappointed at the relatively short distance it operated as compared with an ordinary remote. I used rm-configurator to get it on the wifi network.
I keep trying and trying and trying to get my new RM4C Mini to be recognized by HA, but am having no such luck. What am I doing wrong? The Broadlink app recognizes the device and my router gives it an IP address. When I try to set up the Broadlink integration and enter the IP address of the RM4C Mini, HA keeps responding with Device Not Supported.
- Open Home Assistant and install “SSH & Web Terminal” add-on
- Disable Protection mode
- Click “Terminal” on the sidebar and install the patch: run the following commands, line by line
docker exec -it homeassistant /bin/bash
pip3 install git+https://github.com/mjg59/python-broadlink.git@new_product_ids --force-reinstall --no-deps
- Restart HA
Not taking credit for this, found it somewhere in these threads but can’t find the source. This will stop working after every update to HA until the fix is pushed into HA itself.
Seems that the HA-version you are running is quite outdated. I bought a couple of Broadlink Bestcon RM4C mini in back in May 2022 (HA core-2022.5.x at that time) and the RM4C minis were instantly fully integrated through the Broadlink Integration. See also your cross-posts here and here.
This is still a problem. Follow these instructions to solve it: